1. The content of IDL. bat in the bin directory is as follows:
@ Echo off
Rem @ java_cmd @-classpath "@ jacorb_home @/lib/IDL. jar; @ jacorb_home @/lib/logkit-1.2.jar; % classpath %" org. jacorb. IDL. parser % *
Set jacorb_home = D:/jacorb
Set java_home = C:/j2sdk1.4.2 _ 13
Set Path = % java_home %/bin; % PATH %
Set classpath = % java_home %/lib/RT. Jar
Set classpath = % jacorb_home %/lib/antlr-2.7.2.jar; % jacorb_home %/lib/avalon-framework-4.1.5.jar; % jacorb_home %/lib/concurrent-1.3.2.jar; % jacorb_home %/lib/IDL. jar; % jacorb_home %/lib/jacorb. jar; % jacorb_home %/lib/logkit-1.2.jar; % jacorb_home %/lib/picocontainer-1.2-021105.jar; % jacorb_home %/lib/wrapper-3.1.0.jar; % jacorb_home %/classes; % classpath %
% Java_home %/bin/Java-CP % classpath % org. jacorb. IDL. parser % *
2. Run D:/jacorb/bin> IDL-h to view the help information.
3. Common commands are as follows:
D:/jacorb/bin> IDL-d c:/-i2jpackage: COM. navyu D:/jacorb/demo/Hello/server. IDL
-D indicates the directory of the generated Java code.
-The prefix of the package in Java code is added to the i2jpackage. That is, the module prefix in IDL.
-I2jpackage X: A. B. C replace IDL package name X by A. B. C in generate
D Java code (e.g. CORBA: org. Omg. CORBA)
Compile the entire directory:
D:/jacorb/bin> IDL-all-d c:/-i2jpackage: COM. navyu-in D:/jacorb/IDL /*.*
More powerful functions:
IDL-d c:/CT-ID:/jacorb/IDL/OMG-i2jpackagefile C:/format.txt-all-in D:/jacorb/IDL /*.*
-Idir set include path for IDL files
Because the OMG-defined System IDL is sometimes required, all of them need this parameter.
-I2jpackagefile <FILENAME> replace IDL package names using list fr
Om <FILENAME>. format as above.
Supports replacement of more complex IDL package names.