IBM® Rational® Rhapsody® provides
several predefined action statements that you can use in addition
to native statements in the programming language anywhere you write
code in the product.
You can use predefined action statements in actions
on transitions or in bodies of triggered operations in statecharts.
The action statements are defined in the real‑time framework (in RiCReactive.h)
as macros to minimize their impact on the generated source code.
When generating events, note the following:
- If you are generating an event in the action part
of a transition, the event name must include parentheses. For example,
if you are generating an event ev1, use ev1() instead
of ev1 as the name of the event to be generated.
- If the name of the instance that is
the target of the event is not a pointer, use the address operator & with
the instance name as an argument to the event generation statement.
For example, when sending an event to itsRoom, where itsRoom is
defined as an instance of Room, use the address operator &itsRoom rather
than itsRoom (pointer) as an argument.