RADE |
C++ Interactive Dashboard |
Working with the RADE Dashboards - Part 2C++ Code generator features |
Technical Article |
AbstractThis article describes the use of Code Generator commands that can be found in IBM Rational Software Development Platform. The Code Generator is a suite of commands designed to assist you in developing your own code, integrated in the V5 development platform. To compile your code, you will need to use the mkmk tools explained in: "Principles of use - How to open and build a CAA V5 workspace". We advise you to read Customizing IBM Rational Software Development Platform [1] to set up your environment and to migrate a CAA V5 File Tree to a format which is recognized by IBM Rational Software Development Platform. Before using any of the commands available through the Code Generator, it is imperative that you have a clear understanding of the CAA V5 Workspace File Tree. You may also have a knowledge of V5 object modeler principles. |
Even if they appear in IRAD, Code Generator commands will not work until you open a CAA V5 workspace.
If you try to use them before opening a workspace you will get the following message: |
In order to remedy the situation, open or create a V5 workspace. Below is a short summary on how to open a V5 workspace. For more information, see "Principles of use - How to open and build a CAAV5 workspace".
[Top]
Navigator
view,
right-click a project and select Open V5
Workspace
. Create
with
combo box....
button to
open a directory browser. Default
should be
displayed in the combo box.
Once you have filled in the workspace information, click
OK
. A log window appears while your
environment is updated and the workspace opened and you are ready to work.
To find out more, see
Java Interactive
Dashboard.
[Top]
The commands available in the Code Generator are a set of wizards where you specify a series of parameters and that generate code for you. Before creating the code, a report window appears so that you can check that the code generated is as expected.
Some of the generated source files contain
commented out statements such as DO NOT EDIT :: THE CAA2 WIZARDS WILL
INSERT CODE HERE . Do not modify what you find between these
commented lines or the wizards will no longer insert code into the source
file. |
[Top]
Code Generator commands enable you to create the necessary V5 directory structure. The wizard will assist you in creating new frameworks and modules using the available tools. You can then start populating your directories by using the available wizards, or by creating new objects, or editing mode methodology
[Top]
New->Other
.CAA Elements
node
and select CAAV5 Framework
. Click
Next
. The New Framework dialog box
is displayed.
OK
.
The wizard creates the following directories structure (see below.)
Education type frameworks are suffixed .edu and Test frameworks are suffixed .tst. The wizard appends these suffixes to the name of the framework.
[Top]
An interface framework is a framework that contains (mainly) interfaces in both Java or IDL language. The structure of this interface is very specific. V5 naming conventions require that these interfaces be distinguishable through an Interfaces suffix. Therefore if you type in Bird in the framework name, the generated framework will be called BirdInterfaces. The generated structure is the following:
In the Java Interactive Dashboard, you will see the new framework in the Navigator view. Note that the framework is set as the currently active project.
[Top]
File
menu, select the
New->Other
command.CAA Elements
node
and select CAAV5 Module
. Click
Next>
. The New Java Module dialog
box is displayed.
OK
.
Click Generate
a directory in PublicInterfaces when the module contains
JAVA classes exposed in CAA. In this case, classes should be located in
PublicInterfaces . |
When you click OK
a report window
is displayed to show you the files and directories that will be created. If you
accept, the following file structure will be created:
Note that the newly created module is set as the currently active one.
[Top]
You may create interactively a new test case script inside a test-dedicated framework.
File
menu, select
New->Other
. CAA Elements
node
and select CAAV5 TestCase
. Click
Next>
. The Insert TestCase dialog
box is displayed.Switch test case
if you
want the test case to be considered as switch sensitive.
A new test case script is created in your framework. This test case can be
run using Replay Test-Cases
found in
the CAA Project
menu.
[Top]
[1] | Customizing IBM Rational Software Development Platform |
[2] | Working with the RADE Dashboards - Part 1 |
[3] | Workbench Commands Mapping |
[4] | JID Troubleshooting |
[Top] |
Version: 1 [Jan 2000] | Document created |
Version: 2 [May 2003] | Document updated |
Version: 2 [May 2006] | Document updated |
[Top] |
Copyright © 2006, Dassault Systèmes. All rights reserved.