SQL/MX Programming Manual for Java

Program and Module Management
HP NonStop SQL/MX Programming Manual for Java523726-003
6-5
Packaging the Program in a JAR File
Packaging the Program in a JAR File
To use one program file for easier deployment and maintenance, consider packaging
the SQLJ application in a JAR file. A JAR file of the SQLJ application must contain all
the files necessary for execution, including all class files (.class) and profiles (.ser),
as shown in Figure 6-1.
Figure 6-1. Packaging an SQLJ Application in a JAR File
VST008.vsd
JAR Tool
Class files and profiles from
other SQLJ source files
Class files and profiles from
one SQLJ source file
Keys File
MyProg1_SJProfile
Keys.class
Iterator Class
MyProg1$Iter.
class
Connection
Context Class
SQLMXCtx.class
Java Class File
of the SQLJ Program
MyProg1.class
Extended Profile with
Embedded Module
Definition
MyProg1_SJProfile0.ser
JAR File of the
SQLJ Application
MyApp.jar
Java Class File
of the SQLJ Program
MyProg2.class