Question & Answer
How do you make IBM Rational Rhapsody not generate annotations in model source file.
By default, Rhapsody would include annotations like "ignore", "auto-generated" in generated source files during code generation.
With these annotations, Rhapsody could understand the code structure and further correctly perform other code related operations like roundtrip, incremental code generation and etc.
If you don't have plan to use roundtrip, probably you prefer to not having auto-generated annotations in your source file.
Remove auto-generated annotations from source files would likely cause parser error and other potential issues hence it's not a recommended practise.
- Possible Solutions
1. Set property [Lang]_CG::ModelElement::SimplifyAnnotations to "None" to remove annotations of model elements from source file.
2. Remove keyword $annotation from corresponding property located under [Lang]_CG::WriterTemplates category.
Example: To remove annotations generated inside of operation body, use property C_CG::WriterTemplates::GlobalOperationImp for RiC model and CPP_CG::WriterTemplates::OperationImp property when working with RiC++ model.
3. Most of auto-generated annotations would be removed from source file after applying above solutions. You could consider utilizing Rhapsody Post Processor feature to completely remove the rest annotations if needed.
Internal Use Only
This technote was generated by Technote Kickstart 184.108.40.206 based on Rational Customer Support PMR 14661,999,672.
View the associated PMR's text via Wellspring at: http://eclient.lenexa.ibm.com:9082/DocFetcher/source/PMR/14661.999.672%20O15/03/18
17 June 2018