Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Difference between revisions of "EDT:EGL Language"
Line 4: | Line 4: | ||
*"N/S" means Not Supported. | *"N/S" means Not Supported. | ||
− | *Anything that exists in RBD but isn't mentioned here is not included in EDT. Or maybe we forgot about it. | + | *Anything that exists in RBD but isn't mentioned here is not included in EDT. Or maybe we forgot about it. Nobody's perfect.<br> |
− | *The work in the Core category includes the parser, model, and validation.<br> | + | *The work in the Core category includes the parser, model, and validation.<br> |
− | *The work in the JavaScript, Java, and Debug categories includes both the generator and runtime.<br> | + | *The work in the JavaScript, Java, and Debug categories includes both the generator and runtime.<br> |
− | *'''Developers:''' include a link to Bugzilla for features not done yet, and mark items "Done" when you're finished. | + | * Text <span style="background:#FFA500">with an orange background</span> shows differences in features supported by both EDT and RBD. |
− | *[[EDT:Discussion topics from the language meetings]] | + | *'''Developers:''' include a link to Bugzilla for features not done yet, and mark items "Done" when you're finished. |
+ | *[[EDT:Discussion topics from the language meetings]] | ||
== Table 1: Part Types == | == Table 1: Part Types == | ||
Line 51: | Line 52: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Structured Record''<br> | | bgcolor="#cccccc" | ''Structured Record''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 111: | Line 112: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''DataTable''<br> | | bgcolor="#cccccc" | ''DataTable''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 117: | Line 118: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Form''<br> | | bgcolor="#cccccc" | ''Form''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 125: | Line 126: | ||
'''Notes on Table 1'''<br> | '''Notes on Table 1'''<br> | ||
− | #In RBD a DataItem can only be used for primitive types. | + | # <span style="background:#FFA500">In RBD a DataItem can only be used for primitive types. In EDT it can be used for any type.</span> |
− | #See also Table 2: Function Parameters. | + | # See also Table 2: Function Parameters. |
− | #Interfaces can be implemented by services and handlers (every kind of "logic part" which can be instantiated) | + | # Interfaces can be implemented by services <span style="background:#FFA500">and handlers (every kind of "logic part" which can be instantiated)</span>. |
− | #There are no called programs. Use libraries for "local calls" and services for "remote calls".< | + | # <span style="background:#FFA500">There are no called programs in EDT. Use libraries for "local calls" and services for "remote calls".</span> |
− | #We intend to support function overloading in all implementations, even JavaScript.< | + | # <span style="background:#FFA500">We intend to support function overloading in all implementations, even JavaScript.</span> |
== Table 2: Function Parameters == | == Table 2: Function Parameters == | ||
Line 172: | Line 173: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Field''<br> | | bgcolor="#cccccc" | ''Field''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 178: | Line 179: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''SqlNullable''<br> | | bgcolor="#cccccc" | ''SqlNullable''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 186: | Line 187: | ||
'''Notes on Table 2'''<br> | '''Notes on Table 2'''<br> | ||
− | #The default parameter modifier is In for references and Inout for values.<br> | + | #The default parameter modifier is <span style="background:#FFA500">In for references</span> and Inout for values.<br> |
== Table 3: Primitive Types == | == Table 3: Primitive Types == | ||
Line 313: | Line 314: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Arraydictionary''<br> | | bgcolor="#cccccc" | ''Arraydictionary''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 319: | Line 320: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Char''<br> | | bgcolor="#cccccc" | ''Char''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 325: | Line 326: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Dbchar''<br> | | bgcolor="#cccccc" | ''Dbchar''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 331: | Line 332: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Mbchar''<br> | | bgcolor="#cccccc" | ''Mbchar''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 337: | Line 338: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Unicode''<br> | | bgcolor="#cccccc" | ''Unicode''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 343: | Line 344: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Hex<sup>6</sup>''<br> | | bgcolor="#cccccc" | ''Hex<sup>6</sup>''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 349: | Line 350: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Date<sup>3</sup>''<br> | | bgcolor="#cccccc" | ''Date<sup>3</sup>''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 355: | Line 356: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Time<sup>3</sup>''<br> | | bgcolor="#cccccc" | ''Time<sup>3</sup>''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 361: | Line 362: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Interval<sup>3</sup>''<br> | | bgcolor="#cccccc" | ''Interval<sup>3</sup>''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 367: | Line 368: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Bin''<br> | | bgcolor="#cccccc" | ''Bin''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 373: | Line 374: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Num''<br> | | bgcolor="#cccccc" | ''Num''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 379: | Line 380: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Numc''<br> | | bgcolor="#cccccc" | ''Numc''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 385: | Line 386: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Pacf''<br> | | bgcolor="#cccccc" | ''Pacf''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 391: | Line 392: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Money''<br> | | bgcolor="#cccccc" | ''Money''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 399: | Line 400: | ||
'''Notes on Table 3'''<br> | '''Notes on Table 3'''<br> | ||
− | #String(N) is a reference type in EDT.< | + | # <span style="background:#FFA500">String(N) is a reference type in EDT.</span> |
− | #String is a reference type in EDT.< | + | # <span style="background:#FFA500">String is a reference type in EDT.</span> |
− | #Timestamp is the only supported date/time type. Use it in place of RBD's date, time, and interval. Date/time math produces timestamps or numbers.< | + | # Timestamp is the only supported date/time type. Use it in place of RBD's date, time, and interval. <span style="background:#FFA500">Date/time math produces timestamps or numbers.</span> |
− | #Decimal with no length or decimals is a reference type with an immutable value.< | + | # <span style="background:#FFA500">Decimal with no length or decimals is a reference type with an immutable value.</span> |
− | #Number is a reference type with an immutable value. Unlike in RBD, number variables can be declared anywhere a variable declaration is allowed.< | + | # <span style="background:#FFA500">Number is a reference type with an immutable value. Unlike in RBD, number variables can be declared anywhere a variable declaration is allowed.</span> |
− | #Bytes(N) is a value type similar to RBD's hex. N indicates the number of bytes in the value. (In RBD, the length of a hex is the number of nibbles not the nubmer of bytes.) | + | # Bytes(N) is a value type similar to RBD's hex. N indicates the number of bytes in the value. (In RBD, the length of a hex is the number of nibbles not the nubmer of bytes.) |
− | #Bytes with no length is a reference type with an immutable value of any length. | + | # Bytes with no length is a reference type with an immutable value of any length. |
== Table 4: Statements == | == Table 4: Statements == | ||
Line 438: | Line 439: | ||
| <br> | | <br> | ||
| <br> | | <br> | ||
− | |||
| <br> | | <br> | ||
+ | | <br> | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Return'' | | bgcolor="#cccccc" | ''Return'' | ||
Line 586: | Line 587: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Goto''<br> | | bgcolor="#cccccc" | ''Goto''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 592: | Line 593: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Set''<br> | | bgcolor="#cccccc" | ''Set''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 598: | Line 599: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Converse''<br> | | bgcolor="#cccccc" | ''Converse''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 604: | Line 605: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Display''<br> | | bgcolor="#cccccc" | ''Display''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 610: | Line 611: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Print''<br> | | bgcolor="#cccccc" | ''Print''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 616: | Line 617: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Forward''<br> | | bgcolor="#cccccc" | ''Forward''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 622: | Line 623: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''Show''<br> | | bgcolor="#cccccc" | ''Show''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 628: | Line 629: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''OpenUI''<br> | | bgcolor="#cccccc" | ''OpenUI''<br> | ||
− | | <br> | + | | <br> |
| N/S | | N/S | ||
| N/S | | N/S | ||
Line 636: | Line 637: | ||
'''Notes on Table 4'''<br> | '''Notes on Table 4'''<br> | ||
− | #EDT won't support every variation of RBD's move statement. There will be support for '''move byName''', '''move for''', and '''move for all'''. A move statement without one of the additional keywords is only allowed between two references, and it results in the target being assigned a copy of the source's value. If/when we support structured records, we might not support '''move byName''' on them because of the complex (unclean) design. | + | # EDT won't support every variation of RBD's move statement. There will be support for '''move byName''', '''move for''', and '''move for all'''. A move statement without one of the additional keywords is only allowed between two references, and it results in the target being assigned a copy of the source's value. If/when we support structured records, we might not support '''move byName''' on them because of the complex (unclean) design. |
− | #EDT doesn't have called programs, but services and native programs can be called. | + | # EDT doesn't have called programs, but services and native programs can be called. |
− | #EDT's foreach statement will support iterating over an array. | + | # <span style="background:#FFA500">EDT's foreach statement will support iterating over an array.</span> |
− | #Support for these statements is tentative, pending the design for JPA in EDT. | + | # Support for these statements is tentative, pending the design for JPA in EDT. |
== Table 5: Literals == | == Table 5: Literals == | ||
Line 652: | Line 653: | ||
|- | |- | ||
| bgcolor="#cccccc" | ''null'' | | bgcolor="#cccccc" | ''null'' | ||
− | | | + | | |
− | | | + | | |
− | | | + | | |
− | | | + | | |
|- | |- | ||
| bgcolor="#cccccc" | ''boolean<sup>1</sup>'' | | bgcolor="#cccccc" | ''boolean<sup>1</sup>'' | ||
− | | | + | | |
− | | | + | | |
− | | | + | | |
− | | | + | | |
|- | |- | ||
| bgcolor="#cccccc" | ''integer<sup>2</sup>'' | | bgcolor="#cccccc" | ''integer<sup>2</sup>'' | ||
− | | | + | | |
− | | | + | | |
− | | | + | | |
− | | | + | | |
|- | |- | ||
| bgcolor="#cccccc" | ''fixed-decimal<sup>3</sup>'' | | bgcolor="#cccccc" | ''fixed-decimal<sup>3</sup>'' | ||
− | | | + | | |
− | | | + | | |
− | | | + | | |
− | | | + | | |
|- | |- | ||
| bgcolor="#cccccc" | ''floating point'' | | bgcolor="#cccccc" | ''floating point'' | ||
− | | | + | | |
− | | | + | | |
− | | | + | | |
− | | | + | | |
|- | |- | ||
| bgcolor="#cccccc" | ''string<sup>4</sup>'' | | bgcolor="#cccccc" | ''string<sup>4</sup>'' | ||
− | | | + | | |
− | | | + | | |
− | | | + | | |
− | | | + | | |
|- | |- | ||
| bgcolor="#cccccc" | ''bytes<sup>5</sup>'' | | bgcolor="#cccccc" | ''bytes<sup>5</sup>'' | ||
− | | | + | | |
− | | | + | | |
− | | | + | | |
− | | | + | | |
|- | |- | ||
| bgcolor="#cccccc" | ''array'' | | bgcolor="#cccccc" | ''array'' | ||
− | | | + | | |
− | | | + | | |
− | | | + | | |
− | | | + | | |
|- | |- | ||
− | | bgcolor="#cccccc" | ''char'' | + | | bgcolor="#cccccc" | ''char'' |
| | | | ||
| N/S | | N/S | ||
Line 705: | Line 706: | ||
| N/S | | N/S | ||
|- | |- | ||
− | | bgcolor="#cccccc" | ''mbchar'' | + | | bgcolor="#cccccc" | ''mbchar'' |
| | | | ||
| N/S | | N/S | ||
Line 711: | Line 712: | ||
| N/S | | N/S | ||
|- | |- | ||
− | | bgcolor="#cccccc" | ''dbchar'' | + | | bgcolor="#cccccc" | ''dbchar'' |
| | | | ||
| N/S | | N/S | ||
Line 717: | Line 718: | ||
| N/S | | N/S | ||
|- | |- | ||
− | | bgcolor="#cccccc" | ''hex'' | + | | bgcolor="#cccccc" | ''hex'' |
| | | | ||
| N/S | | N/S | ||
Line 726: | Line 727: | ||
'''Notes on Table 5'''<br> | '''Notes on Table 5'''<br> | ||
− | # As in RBD, there are four boolean literals: true false yes no | + | # As in RBD, there are four boolean literals: true false yes no |
− | # Integer literals have 1-32 digits, an optional leading sign, and no decimal point. | + | # Integer literals have 1-32 digits, an optional leading sign, and no decimal point. The type of the literal depends on the value. If the value fits in a smallint, then the type is smallint. If the value doesn't fit in a smallint but it does fit in an int, then the type is int. Similarly for bigint. If the value is too large for a bigint, then the type is decimal(X), where X is the number of digits in the value. |
− | # Fixed-decimal literals have 1-32 digits, an optional leading sign, and a decimal point. | + | # Fixed-decimal literals have 1-32 digits, an optional leading sign, and a decimal point. At least one digit must follow the decimal point, but it's permissible to have no digits before the decimal point. The type of a fixed-decimal literal is decimal(X,Y), where X is the total number of digits and Y is the number of digits to the right of the decimal point. |
− | # String literals are enclosed in double quotes. | + | # String literals are enclosed in double quotes. An optional ux prefix may appear before the opening double quote. The ux prefix means the string is defined as Unicode codepoints in hexadecimal. For example "012" and ux"003000310032" have the same value. The letters u and x may be in any case. |
− | # A bytes literal is written as 0x or 0X followed by an even number of hexadecimal digits. | + | # A bytes literal is written as 0x or 0X followed by an even number of hexadecimal digits. For example 0x03AB is a literal whose type is bytes(2). |
− | == What's left... == | + | == What's left... == |
*Operators and expressions | *Operators and expressions | ||
− | **result of errors in each case? | + | **result of errors in each case? |
− | **. (member access) | + | **. (member access) |
− | **= | + | **= |
− | **function invocation | + | **function invocation |
− | **new | + | **new |
− | **{ } (set-values block) | + | **{ } (set-values block) |
− | **@ | + | **@ |
− | **[ ] (array access) | + | **[ ] (array access) |
− | **[ ] (dynamic access) | + | **[ ] (dynamic access) |
− | **[ ] (substring), as L-value and R-value | + | **[ ] (substring), as L-value and R-value |
− | **as | + | **as |
− | **isa | + | **isa |
− | **% * ** / %= *= **= /= | + | **% * ** / %= *= **= /= |
− | **+ - (both binary and unary) += -= | + | **+ - (both binary and unary) += -= |
− | ** :: ::= | + | ** :: ::= |
− | **?: ?:= | + | **?: ?:= |
− | **&& || And Or ! | + | **&& || And Or ! |
− | ** | + | **< > <= >= == != |
− | **& | Xor &= |= Xor= | + | **& | Xor &= |= Xor= |
− | **is/not systemType | + | **is/not systemType |
− | **is/not blanks, numeric | + | **is/not blanks, numeric |
− | **is/not trunc, cursor, data, modified | + | **is/not trunc, cursor, data, modified |
− | **is/not IO error states | + | **is/not IO error states |
− | **like | + | **like |
− | **matches | + | **matches |
− | **in | + | **in |
− | *Conversions | + | *Conversions |
− | **result of conversion errors? | + | **result of conversion errors? |
− | **defaultNumericFormat, defaultMoneyFormat, defaultTimestampFormat, defaultDateFormat, defaultTimeFormat | + | **defaultNumericFormat, defaultMoneyFormat, defaultTimestampFormat, defaultDateFormat, defaultTimeFormat |
− | **numeric to/from numeric | + | **numeric to/from numeric |
− | **string to/from numeric | + | **string to/from numeric |
− | **string to/from boolean | + | **string to/from boolean |
− | **string to/from byte | + | **string to/from byte |
− | **string to/from timestamp | + | **string to/from timestamp |
− | **numeric to/from boolean | + | **numeric to/from boolean |
− | **numeric to/from byte | + | **numeric to/from byte |
− | **numeric to/from timestamp | + | **numeric to/from timestamp |
− | **byte to/from boolean | + | **byte to/from boolean |
− | **byte to/from timestamp | + | **byte to/from timestamp |
− | **boolean to/from timestamp | + | **boolean to/from timestamp |
*Stereotypes | *Stereotypes | ||
− | **program stereotypes | + | **program stereotypes |
− | ***BasicProgram | + | ***BasicProgram |
− | ***UIProgram | + | ***UIProgram |
− | ***TextUIProgram | + | ***TextUIProgram |
− | ***VGWebTransaction | + | ***VGWebTransaction |
− | **library stereotypes | + | **library stereotypes |
− | ***BasicLibrary | + | ***BasicLibrary |
− | ***NativeLibrary | + | ***NativeLibrary |
− | ***RUIPropertiesLibrary | + | ***RUIPropertiesLibrary |
− | **record stereotypes | + | **record stereotypes |
− | ***BasicRecord | + | ***BasicRecord |
− | ***Exception | + | ***Exception |
− | ***SQLRecord | + | ***SQLRecord |
− | ***CSVRecord | + | ***CSVRecord |
− | ***DLISegment | + | ***DLISegment |
− | ***PSBRecord | + | ***PSBRecord |
− | ***IndexedRecord | + | ***IndexedRecord |
− | ***RelativeRecord | + | ***RelativeRecord |
− | ***SerialRecord | + | ***SerialRecord |
− | ***MQRecord | + | ***MQRecord |
− | ***ConsoleForm | + | ***ConsoleForm |
− | ***VGUIRecord | + | ***VGUIRecord |
− | **handler stereotypes | + | **handler stereotypes |
− | ***BasicHandler | + | ***BasicHandler |
− | ***RUIHandler | + | ***RUIHandler |
− | ***RUIWidget | + | ***RUIWidget |
− | ***BirtHandler | + | ***BirtHandler |
− | ***JasperReport | + | ***JasperReport |
− | ***JSFHandler | + | ***JSFHandler |
− | **externaltype stereotypes | + | **externaltype stereotypes |
− | ***NativeType | + | ***NativeType |
− | ***JavaObject | + | ***JavaObject |
− | ***JavaScriptObject | + | ***JavaScriptObject |
− | ***HostProgram | + | ***HostProgram |
− | **datatable stereotypes...form stereotypes... | + | **datatable stereotypes...form stereotypes... |
− | *Annotations (details TBD) | + | *Annotations (details TBD) |
*Language compliance test (details TBD) | *Language compliance test (details TBD) | ||
<br> | <br> |
Revision as of 16:50, 5 July 2011
Contents
General Notes
- This document is not finished yet!
- "N/S" means Not Supported.
- Anything that exists in RBD but isn't mentioned here is not included in EDT. Or maybe we forgot about it. Nobody's perfect.
- The work in the Core category includes the parser, model, and validation.
- The work in the JavaScript, Java, and Debug categories includes both the generator and runtime.
- Text with an orange background shows differences in features supported by both EDT and RBD.
- Developers: include a link to Bugzilla for features not done yet, and mark items "Done" when you're finished.
- EDT:Discussion topics from the language meetings
Table 1: Part Types
Part Types | Core | JavaScript | Java | Debug |
DataItem1 | |
|
|
|
Function2, 5 | |
|
|
|
Top-level function2, 5 | |
|
|
|
Delegate2 | |
|
|
|
Record |
|
|
|
|
Structured Record |
|
N/S | N/S | N/S |
ExternalType |
|
|
|
|
Handler |
|
|
|
|
Library |
|
|
|
|
Service |
|
|
|
|
Interface3 |
|
|
|
|
Enumeration |
|
|
|
|
Program4 |
|
N/S |
|
|
Array |
|
|
|
|
Nullability |
|
|
|
|
DataTable |
|
N/S | N/S | N/S |
Form |
|
N/S | N/S | N/S |
Notes on Table 1
- In RBD a DataItem can only be used for primitive types. In EDT it can be used for any type.
- See also Table 2: Function Parameters.
- Interfaces can be implemented by services and handlers (every kind of "logic part" which can be instantiated).
- There are no called programs in EDT. Use libraries for "local calls" and services for "remote calls".
- We intend to support function overloading in all implementations, even JavaScript.
Table 2: Function Parameters
Function Parameters | Core | JavaScript | Java | Debug |
In1 | |
|
|
|
Out | |
|
|
|
Inout1 | |
|
|
|
Ellipsis | |
|
|
|
Const | |
|
|
|
Field |
|
N/S | N/S | N/S |
SqlNullable |
|
N/S | N/S | N/S |
Notes on Table 2
- The default parameter modifier is In for references and Inout for values.
Table 3: Primitive Types
Primitive Types | Core | JavaScript | Java | Debug |
Any | |
|
|
|
Boolean | |
|
|
|
Dictionary | |
|
|
|
String(N)1 | |
|
|
|
String2 | |
|
|
|
Timestamp3 | |
|
|
|
Blob | |
N/S |
|
|
Clob | |
N/S |
|
|
Smallint | |
|
|
|
Int | |
|
|
|
Bigint | |
|
|
|
Decimal(N,M) | |
|
|
|
Decimal(N) | |
|
|
|
Decimal4 | |
|
|
|
Float | |
|
|
|
Smallfloat | |
|
|
|
Number5 | |
|
|
|
Bytes(N)6 | |
|
|
|
Bytes7 | |
|
|
|
Arraydictionary |
|
N/S | N/S | N/S |
Char |
|
N/S | N/S | N/S |
Dbchar |
|
N/S | N/S | N/S |
Mbchar |
|
N/S | N/S | N/S |
Unicode |
|
N/S | N/S | N/S |
Hex6 |
|
N/S | N/S | N/S |
Date3 |
|
N/S | N/S | N/S |
Time3 |
|
N/S | N/S | N/S |
Interval3 |
|
N/S | N/S | N/S |
Bin |
|
N/S | N/S | N/S |
Num |
|
N/S | N/S | N/S |
Numc |
|
N/S | N/S | N/S |
Pacf |
|
N/S | N/S | N/S |
Money |
|
N/S | N/S | N/S |
Notes on Table 3
- String(N) is a reference type in EDT.
- String is a reference type in EDT.
- Timestamp is the only supported date/time type. Use it in place of RBD's date, time, and interval. Date/time math produces timestamps or numbers.
- Decimal with no length or decimals is a reference type with an immutable value.
- Number is a reference type with an immutable value. Unlike in RBD, number variables can be declared anywhere a variable declaration is allowed.
- Bytes(N) is a value type similar to RBD's hex. N indicates the number of bytes in the value. (In RBD, the length of a hex is the number of nibbles not the nubmer of bytes.)
- Bytes with no length is a reference type with an immutable value of any length.
Table 4: Statements
Statements | Core | JavaScript | Java | Debug |
Variable declaration | |
|
|
|
Const declaration | |
|
|
|
Assignment | |
|
|
|
Move1 | |
|
|
|
Return | |
|
|
|
Function invocation | |
|
|
|
Call2 | |
|
|
|
Label | |
|
|
|
Transfer | |
N/S |
|
|
Throw | |
|
|
|
Try | |
|
|
|
Case | |
|
|
|
If | |
|
|
|
While | |
|
|
|
For | |
|
|
|
Foreach3 | |
|
|
|
Exit | |
|
|
|
Continue | |
|
|
|
Empty statement (a semicolon) | |
|
|
|
Add | |
N/S |
|
|
Close | |
N/S |
|
|
Delete | |
N/S |
|
|
Get | |
N/S |
|
|
Replace | |
N/S |
|
|
Execute4 | |
N/S |
|
|
Prepare4 | |
N/S |
|
|
Open4 | |
N/S |
|
|
FreeSQL4 | |
N/S |
|
|
Goto |
|
N/S | N/S | N/S |
Set |
|
N/S | N/S | N/S |
Converse |
|
N/S | N/S | N/S |
Display |
|
N/S | N/S | N/S |
Print |
|
N/S | N/S | N/S |
Forward |
|
N/S | N/S | N/S |
Show |
|
N/S | N/S | N/S |
OpenUI |
|
N/S | N/S | N/S |
Notes on Table 4
- EDT won't support every variation of RBD's move statement. There will be support for move byName, move for, and move for all. A move statement without one of the additional keywords is only allowed between two references, and it results in the target being assigned a copy of the source's value. If/when we support structured records, we might not support move byName on them because of the complex (unclean) design.
- EDT doesn't have called programs, but services and native programs can be called.
- EDT's foreach statement will support iterating over an array.
- Support for these statements is tentative, pending the design for JPA in EDT.
Table 5: Literals
Literals | Core | JavaScript | Java | Debug |
null | ||||
boolean1 | ||||
integer2 | ||||
fixed-decimal3 | ||||
floating point | ||||
string4 | ||||
bytes5 | ||||
array | ||||
char | N/S | N/S | N/S | |
mbchar | N/S | N/S | N/S | |
dbchar | N/S | N/S | N/S | |
hex | N/S | N/S | N/S |
Notes on Table 5
- As in RBD, there are four boolean literals: true false yes no
- Integer literals have 1-32 digits, an optional leading sign, and no decimal point. The type of the literal depends on the value. If the value fits in a smallint, then the type is smallint. If the value doesn't fit in a smallint but it does fit in an int, then the type is int. Similarly for bigint. If the value is too large for a bigint, then the type is decimal(X), where X is the number of digits in the value.
- Fixed-decimal literals have 1-32 digits, an optional leading sign, and a decimal point. At least one digit must follow the decimal point, but it's permissible to have no digits before the decimal point. The type of a fixed-decimal literal is decimal(X,Y), where X is the total number of digits and Y is the number of digits to the right of the decimal point.
- String literals are enclosed in double quotes. An optional ux prefix may appear before the opening double quote. The ux prefix means the string is defined as Unicode codepoints in hexadecimal. For example "012" and ux"003000310032" have the same value. The letters u and x may be in any case.
- A bytes literal is written as 0x or 0X followed by an even number of hexadecimal digits. For example 0x03AB is a literal whose type is bytes(2).
What's left...
- Operators and expressions
- result of errors in each case?
- . (member access)
- =
- function invocation
- new
- { } (set-values block)
- @
- [ ] (array access)
- [ ] (dynamic access)
- [ ] (substring), as L-value and R-value
- as
- isa
- % * ** / %= *= **= /=
- + - (both binary and unary) += -=
- :: ::=
- ?: ?:=
- && || And Or !
- < > <= >= == !=
- & | Xor &= |= Xor=
- is/not systemType
- is/not blanks, numeric
- is/not trunc, cursor, data, modified
- is/not IO error states
- like
- matches
- in
- Conversions
- result of conversion errors?
- defaultNumericFormat, defaultMoneyFormat, defaultTimestampFormat, defaultDateFormat, defaultTimeFormat
- numeric to/from numeric
- string to/from numeric
- string to/from boolean
- string to/from byte
- string to/from timestamp
- numeric to/from boolean
- numeric to/from byte
- numeric to/from timestamp
- byte to/from boolean
- byte to/from timestamp
- boolean to/from timestamp
- Stereotypes
- program stereotypes
- BasicProgram
- UIProgram
- TextUIProgram
- VGWebTransaction
- library stereotypes
- BasicLibrary
- NativeLibrary
- RUIPropertiesLibrary
- record stereotypes
- BasicRecord
- Exception
- SQLRecord
- CSVRecord
- DLISegment
- PSBRecord
- IndexedRecord
- RelativeRecord
- SerialRecord
- MQRecord
- ConsoleForm
- VGUIRecord
- handler stereotypes
- BasicHandler
- RUIHandler
- RUIWidget
- BirtHandler
- JasperReport
- JSFHandler
- externaltype stereotypes
- NativeType
- JavaObject
- JavaScriptObject
- HostProgram
- datatable stereotypes...form stereotypes...
- program stereotypes
- Annotations (details TBD)
- Language compliance test (details TBD)