In order to call JVM COBOL from Java, you need to add the JVM COBOL project to the build path of the Java project and to import any COBOL classes you want to use into your Java sources.
This is an outline of the steps to enable calling JVM COBOL from Java:
This ensures proper interoperation of Java code with COBOL types which are not directly mapped to JVM types such as COBOL group items or COBOL numeric types which are longer than four bytes.
import com.microfocus.cobol.MyClass
or
import com.microfocus.cobol.*
To call JVM COBOL from Java, add any locations that include the JVM COBOL classes or packages being called to the CLASSPATH environment variable.
Also in the Java source code, add an import statement to import just the COBOL class you want to use, or add an import statement to import the entire package into your Java source file:
For a single class:
import com.microfocus.cobol.MyClass
For the entire package:
import com.microfocus.cobol.*