Generating from the workbench batch interface
The workbench batch interface is a feature that lets you generate and deploy EGL output from a batch environment that can access the workbench.
Use the batch command EGLCMD to invoke the interface when the workbench is not running. The generation of EGL code can access only projects and EGL parts that were previously loaded into a workspace. For more information, see EGLCMD.
To generate and deploy from the workbench batch interface, do as
follows:
- Make sure that your Java™ classpath
provides access to the following jar files:
- org.eclipse.equinox.launcher_version.jar,
which is in the following directory:
installationDir\sdp70\plugins- installationDir
- The product installation directory, such as C:\Program Files\IBM.
Please note that the directory is not the shared one.
- com.ibm.etools.edt.core.ide.version, which is in the following
directory:
installationDir\sdp70shared\plugins- installationDir
- The product installation directory, such as C:\Program Files\IBM.
- org.eclipse.equinox.launcher_version.jar,
which is in the following directory:
- Make sure that a workspace contains the projects and EGL parts that are required for generation.
- Develop an EGL command file. This command file must be in the workspace. You can either import the file into the workspace or create it directly in the workspace.
- If you are preparing one or more COBOL programs, ensure that the Security Manager is running. For details, see Security Manager.
- Invoke the command EGLCMD, possibly in a larger batch job that
generates, runs, and tests the code.When you specify the command file in the invocation, specify the workspace of interest, as well as the location relative to the workspace root. For example, a command file might be in the MyProject project, in folder MyCommands, and might be named Command1.xml. Here is the specification of the command file:
/MyProject/MyCommands/Command1.xmlNote:Eclipse path names are case sensitive. - Follow these guidelines:
- Close all instances of the workbench before executing EGLCMD from a command prompt.
- Place the command file in the workspace that holds the parts being used to generate code.
- Use the -data option to specify the workspace for EGLCMD. Otherwise EGL will use the default workspace, which may not be the one you want.
- Note the following limitations:
- When you generate a JSF handler with EGLCMD, you must update the faces-config.xml file manually with managed-bean and navigation-rule entries in order for the handler to run correctly.
- If you use EGLCMD and the genDirectory build
descriptor option for a project that contains no web components, EGL
will compile the programs outside the workbench. These rules apply:
- The Java™ compiler (javac.exe) must be in the system path
- The EGL Java™ generation code (eglbatchgen.jar) must be in the system classpath. That code in the installation directory, bin subdirectory.
An alternative way to use the workbench in a batch mode
Aside from using EGLCMD, you might invoke an Ant script to clean a workspace and cause an automatic build and generation. For further details, see "Generating with an Ant Script."