Generate Code
Now it's time to generate the code.
If no valid IDE project is set inside the property
"RXF::Deployer::IDEProject" on the active configuration, a deployer
window will pop-up to request the specification of a valid IDE
project.
The relative path from the chosen IDE project to the Rhapsody model
project folder will be saved in the property
"RXF::Deployer::IDEProject" of your active component. So make sure that
your component have write access. Again, this will only be done, if the
path changes.
Optionally you can also use absolute paths in the property.
Make
The next step is to deploy the generated code into the IDE project.
By clicking on this button following things happen:
- The generated files from Rhapsody will be copied
to the folder "GeneratedModel" next to the IDE project. If the folder
"GeneratedModel" does not exist, it will be generated automatically.
The folder name can be adapted by the property
RXF::Deployer::ModelCodeFolder on the active configuration.
- The copied source files are added to the IDE
project. This also means, that no longer existing files are removed
from the IDE. Therefore, when you remove elements from your model or
change the scope, that some model elements are no longer in the scope:
Please perform a "Clean Redundant Source Files" command in Rhapsody.

This ensures, that all unneeded files are removed from the IDE project to perform a clean build inside the IDE.
- If the IDE is currently closed it will
automatically be started by the deployer and opens the project which is
set in the property "RXF::Deployer::IDEProject". This behavior can be
changed by the property "RXF::Deployer::OpenIDEProject" on
the active configuration.
One useful option is to set the generated source code
folder from the active configuration in Rhapsody to the same folder
where you want to deploy.
This has following advantages:
- You can keep your model and your IDE project
synchronized by roundtripping changes from the IDE back to your model
and directly see changes inside your IDE after code generation from
your model.
- The Deployer does not need to copy the generated files to the IDE project.
Run
The run button will have no effect, because the
execution of the final build will be triggered inside the IDE. So feel
free to use the property CPP_CG::RXF::InvokeExecutable on the active
configuration for your own purposes.
Please continue to the next Part 5