Group items and data items
Group items in a COBOL copybook map to Java™ classes. Data items map to different Java structures, depending on the level of the data item and the level at which they are defined.
For example, top-level COBOL data items are handled differently from lower-level data items, and Level 88 data items are handled differently, depending on the level at which they are defined in the copybook.
Group items
Each group item in the COBOL copybook maps to a Java class in the XOM. If the group item has a parent in the COBOL copybook, an attribute is added into the parent XOM class. For example, you might have these group items:
01 Parent.
05 Child.
These group items map to the following Java XOM entries:
Two classes are generated: Parent and Child
The Parent class has one attribute that is named Child, of type Child.
Data items
Data items that have a parent in a COBOL copybook are mapped to an attribute in the parent Java class in the XOM. For example, you might have a data item named Child:
01 Parent.
05 Child PIC X(20).
This data item maps to the following Java XOM entries:
One class is created for the group item: Parent.
The data item maps to the Child attribute, which is added to the Parent class with an attribute type of java.lang.String.