Roundtripping deletion of elements from the code

You can manually delete elements in code and use roundtripping to update your Rhapsody® model. You can delete variables, functions, types (Struct, Union, Enum, typedef), members of types, attributes, operations, #define-s, #include-s, forward declarations, and associations. You cannot delete auto‑generated #include statements to the Rhapsody framework files.

About this task

Note: This feature applies to C and C++ in Respect mode and Java in Advanced mode.

Procedure

The roundtripping deletion of elements from the code feature involves the following properties:

  1. Depending on whether you have Rhapsody Developer for C, C++, or Java:
    • For Rhapsody Developer for C and Rhapsody Developer for C++: Set the <lang>_Roundtrip::General::RoundtripScheme property (for example, CPP_Roundtrip::General::) to Respect to turn on code preserving, which is required for this feature. See Activating the code structure preserving feature.
    • For Rhapsody Developer for Java: Set the Java_Roundtrip::General::RoundtripScheme property to Advanced.
  2. For C, C++, and Java: Because the <lang>_Roundtrip::Update::AcceptChanges property is, by default, set to Default, the feature to roundtrip hand-edited deletion of elements is available.
    Note: Be aware of the following conditions when the <lang>_Roundtrip::Update::AcceptChanges property is set to Default:
    • Deletion of the elements Classes, Actors, and Objects is disabled. In addition, deletion of elements is disabled when the product finds parser errors in the roundtripped code.
      Note: You can enable deletion of all elements (no exceptions) and even if there are parser errors during roundtripping. To do so, set the <lang>_Roundtrip::Update::AcceptChanges property to All. Consider the consequences of using the All value.
    • Deletion of an element that has a prolog or epilog or both are disabled. (You enter values for the prolog and epilog in the following properties: ImplementationProlog, SpecificationProlog, ImplementationEpilog, SpecificationEpilog.)