Flow charts Code generation You specify whether to generate code for a flow chart by setting the C_CG::Operation::ImplementFlowchart property to Checked (which is the default). Flow chart limitations and specified behavior Note the following restrictions and behavior: Љ You cannot animate or reverse engineer flow charts. Љ Code generation from flow charts is not supported in Rational Rhapsody in Java and Rational Rhapsody in Ada. Љ Flow chart code generation will never write the same action twice. Љ This feature supports only a subclass of diagrams that do not contain events (including timeout events) or triggered operations. Љ Rational Rhapsody makes the following checks:
– If a function already has a body. – On guards that will be ignored because they are not part of an If/Then/Else or Loop. – That the flow chart and all its blocks have one and only one reachable final activity. If there are no reachable states or more than one, a message will display. – That there are no elements with more than one flow between them in the same direction. If there are more than one, a message will display. – That all the elements in the flow chart are supported. If unsupported elements are found, a message will display. Љ If code generated will contain GoTos, Rational Rhapsody will display a warning message with an indication as to which flows are causing the warning.
Note the following information: – Flow charts will normally generate structured code using If, If/Then/Else, Do, and While blocks. Rational Rhapsody in C provides you with a Flowchart model located in the installation>\Samples\CSamples\ Flowchart folder. The Flowchart model contains a number of sample flow charts patterns that show you which ones are recognized in order to generate structured code. For example, the Flowchart model includes flow charts that show the DoWhileLoop, IfThenElse, and the WhileLoop. 666 User Guide