Example: external class-names and Java packages

The following example shows how external class-names are determined from entries in a REPOSITORY paragraph.


Environment division.
Configuration section.
Repository.
    Class Employee is "com.acme.Employee"
    Class JavaException is "java.lang.Exception"
    Class Orders.

The local class-names (the class-names as used within the class definition), the Java™ packages that contain the classes, and the associated external class-names are as shown in the table below.

Local class-name Java package External class-name
Employee com.acme com.acme.Employee
JavaException java.lang java.lang.Exception
Orders (unnamed) ORDERS

The external class-name (the name after the class-name and optional IS in the REPOSITORY paragraph entry) is composed of the fully qualified name of the package (if any) followed by a period, followed by the simple name of the class.

related references  
REPOSITORY paragraph (Enterprise COBOL for z/OS® Language Reference)