Skip to main content

Product: OpenFusion RTOrb Java

Version: ALL

 

Description:

How to compile IDL into Java packages?

 

Resolution:

The -i2jpackage compiler option can be used to flexibly redirect generated java classes into packages. It is used as follows:

-i2jpackage X:a.b.c will redirect IDL definitions with scope X into java package a.b.c

Using -i2jpackagefile will allow you to specify a file that contains these mappings.

You can see how it works by doing the following:

Compile the CosNotification.idl without using the i2jpackage flag, you will find that the generated stubs are in a directory called CosNotification.

Compile the CosNotification.idl using the -i2jpackage CosNotification:org.omg.CosNotification flag. This basically tells it to put anything with CosNotification into the package org.omg.CosNotification. The generated stubs will be in a directory called org.omg.CosNotification.

For more information and further examples please see the ORBUtilities.pdf which can be found in the docs/ directory in the installation.


#KnowledgeDocs
#OpenFusion