For convenience, copybook javatypes.cpy defines a set of COBOL data types corresponding to Java data types - you can use these as a shorthand way of declaring data items for use with Java in your COBOL programs. You can find the copybook in your %ProgramFiles(x86)%\Micro Focus\Enterprise Developer\cpylib directory.
These typedefs all start with the prefix "j" and are shown in the following table:
Typedef | COBOL Type |
---|---|
jbyte | pic s99 comp-5 |
jshort | pic s9(4) comp-5 |
jint | pic s9(9) comp-5 |
jlong | pic s9(18) comp-5 |
jboolean
JNI-FALSE is false |
pic 99 comp-5 |
jchar | pic 9(4) comp-5 |
jfloat | comp-1 |
jdouble | comp-2 |
jobject | pointer |
jbigdecimal | pic s9(19)v9(19) comp-3
Programs that use this typedef must be compiled with the directive INTLEVEL 4 |
jbiginteger | pic s9(38) comp-3
Programs that use this typedef must be compiled with the directive INTLEVEL 4 |
mf-sql-date | 0x jyear pic 9(4).
0x filler pic x. |
mf-sql-time | 0x jhour pic 99.
0x jminute pic 99. |