Preserving code structure during generation

IBM® Rational® Rhapsody® can preserve the order of elements in the original code structure during code generation. Using this feature allows you to change the order of class members and globals, and Rational Rhapsody "respects" those changes.

Code respect has these additional features:

When code is generated in Rational Rhapsody, it resembles the original. This feature gives you complete flexibility for using manually written code or auto-generated code while receiving all the benefits of modeling. You can reverse engineer C++ and C code into a model in a manner that the model respects the order, location, and dependencies of the global elements in the original code.

Note: The code respect feature applies to IBM Rational Rhapsody Developer for C and IBM Rational Rhapsody Developer for C++ and the reverse engineering and roundtripping features in these products. As of version 7.2 of the product, any new project you create has the code respect feature activated by default. To activate code respect for an old project, see Activating the code structure preserving feature.

In addition, you can set up Rational Rhapsody Developer for C and Rational Rhapsody Developer for C++ so that you can roundtrip code into the Rational Rhapsody model that respects the structure of the code and preserves this structure when code is roundtripped in the Rational Rhapsody model.

When you have changed the order of elements in C++ and C, roundtripping in respect mode preserves the order of the following elements for the next code generation:


Feedback