Each Java class you want to use in a COBOL program must be declared in the Repository paragraph. You need to provide the full name of the package the Java class is in, prefixed by $java$. The prefix tells the COBOL run-time system to load the class from the Java domain.
Declare the Java class as follows:
repository. class COBOL-classname as "$java$class-name" .
where the names are:
For example:
repository. class jRectangle as "$java$java.awt.Rectangle" .
This declares jRectangle as a COBOL proxy object for the Rectangle class in the java.awt package. The package must be available on your Java classpath or your program will fail at run time.