Generating business object definitions

This section describes how to use the CORBA ODA in Business Object Designer to generate business object definitions. For information on launching and using Business Object Designer, see IBM WebSphere Business Integration Adapters Business Object Development Guide.

Starting the ODA

The ODA can be run from any machine that can mount the file system on which the meta-data repository (that is, the IDL files) resides, using the start_CORBAODA.bat (NT/Windows 2000) or start_CORBAODA.sh (Unix) start file. This file contains start parameters, including the paths to certain required CORBA and connector .jar files. These .jar files must also be accessible from the machine on which you are running the ODA.

The ODA for CORBA has a default name of CORBAODA. The name can be changed by changing the value of the AGENTNAME variable in the start script.

To start the ODA, run this command:

start_CORBAODA

Running the Business Object Designer

Business Object Designer provides a wizard that guides you through the steps to generate a business object definition using the ODA. The steps are as follows:

Select the agent

  1. Start Business Object Designer.
  2. Click File > New Using ODA. The Business Object Wizard - Step 1 of 6 - Select Agent screen appears.
  3. Select the ODA/AGENTNAME (from the start_CORBAODA script) in the Located agents list and click Next. (You may have to click Find Agents if the desired agent is not listed.)

    Figure 15. Select Agent screen

Configure the agent

After you click Next on the Select Agent screen, the Business Object Wizard - Step 2 of 6 - Configure Agent screen appears. Figure 16 illustrates this screen with sample values.



Figure 16. Configure Agent screen

The properties you set on this screen are described in Table 17. You can save all the values you enter on this screen to a profile. Instead of retyping the property data next time you run the ODA, you simply select a profile from the drop-down menu and re-use the saved values. You can save multiple profiles, each with a different set of specified values.


Table 17. Configure Agent properties

Property name Default value Type Description
IDLFileDirectory None String (required) The directory where the IDL files are located. All the IDL files that define the CORBA interface must be placed in this directory.
GenerateProxies True Boolean (required) When set to true, generates the required proxy object classes. If you are creating server-side objects for a connector that runs as a server, this property is ignored and the ODA generates server implementation classes. This allows you to use the proxy class definitions provided in a .jar file of a CORBA application vendor, instead of generating your own.
JarFileName None String The name of the .jar file in which the classes generated by the ODA will be stored. You can also specify the absolute path (directory and .jar file name). This property is required when the GenerateProxies property is set to true.
BOPrefix None String The prefix that the ODA will add to the names of the business objects it generates. In Figure 16, all business objects that the ODA generates, will have names that start with myBO_.
CORBAServerImpl False Boolean (required) When set to true, the ODA generates server-side business objects and implementation class definitions for server-side processing (to be used when the connector runs as a server). If you also want to generate client-side business objects for the same CORBA IDL objects, run the ODA again with this property set to false.
IDLToJavaTool None String The absolute path of the IDL2Java IDL compiler tool.
CORBAClassPath None String (optional) The semicolon delimited (NT/2000) or colon-delimited (Unix) string that contains the pathname of the external CORBA infrastructure class files. These .jar files are required to successfully compile the proxy class definitions. The value of this property is temporarily appended to the system class path whenever you run the ODA.
OutputFileDir None String (required) Directory in which to store all output files generated by the ODA.
JDKHomeDir None String (required) The directory in which the JDK is installed on this machine.
TraceFileName None String The name of the trace message file; for example, CORBAODAtrace.txt.
TraceLevel 5 Integer (required) The tracing level (from 0 to 5) for the Agent. For details about tracing levels, see Tracing.
MessageFile None String (required) The name of the message file that contains all the messages displayed by the ODA. For CORBA, the name of this file is BIA_CORBAODAAgent.txt. If you do not correctly specify the name of the message file, the ODA will run without messages.

  1. Use the New and Save buttons in the Profiles group box any time you want the ODA to create a new profile. When you use the ODA again, you can select an existing profile.
  2. Type the value of each property, as defined in Table 17.
    Note:
    If you use a profile, the property values are filled in for you, though you can modify the values as needed. You can also save new values.

Select a business object

The Business Object Wizard - Step 3 of 6 - Select Source screen appears, as illustrated in Figure 17. The screen lists the interfaces and structs that have been defined in the CORBA IDL file. Use this screen to select any number of CORBA constructs for which the ODA will generate business object definitions. A high level parent construct is always an interface or a struct. A sub object of the high-level parent can be an interface, struct, union, enum, or sequence. A descendent union, enum, or sequence is automatically generated as a business object when you select any of its interface or struct ancestors (parent or higher level).

Note:
A descendent interface or struct is only generated if you explicitly select it. In other words, it is not automatically generated simply because an ancestor has been selected.

To determine which CORBA objects listed on this screen are child objects of a high-level object, refer to the original IDL file. You can also simply select all the CORBA objects listed on this screen and generate their corresponding business objects. The resulting business objects will reflect the parent-child relationships.

For details about the CORBA structures for which you can create business objects, see Table 9.

Figure 17. Select Source screen

  1. If necessary, expand a CORBA module to see a list of sub objects.
  2. Select the CORBA object(s) you want to use. In Figure 17, the Hello object is selected
  3. Click Next.

Confirm the object selection

The Business Object Wizard - Step 4 of 6 - Confirm source nodes for business object definitions screen appears. It shows the object(s) you selected.



Figure 18. Confirm source node screen

Click Back to make changes or Next to confirm that the list is correct.

The Business Object Wizard - Step 5 of 6 - Generating business objects... screen appears with a message stating that the wizard is generating the business objects.

Copyright IBM Corp. 1997, 2003