Inserting Handwritten Code
Code Generator’s modular code architecture enables you to integrate handwritten code (also known as “user-written code”) with Rational Statemate-generated code in two ways:
● The profile’s scope can include stubs for handwritten code. A stub is an empty module where you can insert user-written code into Rational Statemate-generated code.
●
●
Eliminates the need for special calls and services to integrate handwritten code.
●
Stores the code in the model’s database so it is common to both simulation and code generation.
●
Automatically includes the user-written code whenever you run simulation or code generation.
For information on these methods, refer to Required User-written Code.
Note: Rational Statemate supports the stub method for compatibility reasons, but it is recommended that you use the new method for supplementing code.