Also, the AS400ToolboxJarMaker class can unzip a JAR file for you to gain access to the individual content files for basic use.
All of the AS400ToolboxJarMaker functions are performed with the AS400ToolboxJarMaker class and the AS400ToolboxJarMaker subclass:
According to your needs, you can invoke the AS400ToolboxJarMaker methods from within your own Java program or as a standalone program (java utilities.JarMaker [options]). For a complete set of options available to run at a command line prompt, see the following:
For example, with the following code, you are extracting AS400.class and all of its dependent classes from jt400.jar:
java utilities.AS400ToolboxJarMaker -source jt400.jar -extract outputDir -requiredFile com/ibm/as400/access/AS400.class
Suppose you wanted to split up a large JAR file into smaller JAR files, according to your preference for maximum JAR file size. AS400ToolboxJarMaker, accordingly, provides you with the split(jarFile, splitSize) function.
In the following code, jt400.jar is split into a set of smaller JAR files, none larger than 300K:
java utilities.AS400ToolboxJarMaker -split 300
In the following command, for example, a JAR file is created containing only those Toolbox classes needed to make the Command Call and Program Call components of the Toolbox work:
java utilities.AS400ToolboxJarMaker -component CommandCall,ProgramCall
Additionally, if it is unnecessary to convert text strings between Unicode and the double byte character set (DBCS) conversion tables, you can create a 400K byte smaller JAR file by omitting the unneeded conversion tables with the -ccsid option:
java utilities.AS400ToolboxJarMaker -component CommandCAll,ProgramCall -ccsid 61952
Notes:
|
[ Information Center Home Page | Feedback ] | [ Legal | AS/400 Glossary ] |