When the properties are set to generate the relevant code, the following public virtual member functions are generated for reactive classes:
int <class name>_getStatechartSize(<class name>* me) for C
Returns the number of variables that the statechart uses. Use this function to allocate the state vector that is passed to the function getStatechartStates.
void <class name>_getStatechartStates(const <class name>* const me, int stateVector[], unsigned long* oxfReactiveState) for C
Fills stateVector with the current statechart state, and sets oxfReactiveState based on the OMReactive internal state.
The type of oxfReactiveState is taken from the [C][CPP]_CG::Framework::ReactiveStateType property.
The type of stateVector is taken from the CG::Statechart::FlatStateType (default value is int) property.
In WithoutReactive mode, the last argument is eliminated and the function prototypes become:
void <class name>_setStatechartStates(<class name>* const me, int stateVector[], unsigned long* oxfReactiveState) for C
Set the reactive instance states as well as the OMReactive internal state.
The type of oxfReactiveState is taken from the [C][CPP]_CG::Framework::ReactiveStateType property.
The type of stateVector is taken from the CG::Statechart::FlatStateType (default value is int) property.