activate
The operation is used to activate a default context (i.e., an altstep). It returns a reference to the activated
default.
- Default context is a set of branches (cf. altstep) that is implicitly appended at the end of all alt statements (except if the alt has an else branch) and after all stand-alone receive/timeout/done … statements. When no
branch of the alt matches the received message, the previously activated default(s) are examined.
- The default reference can be used to deactivate a given default.
- The special value null is available to indicate an undefined default reference, e.g. for the initialization of
variables to handle default references.
- It is possible to have several defaults activated at same time and deactivate them one by one. The last activated default will be placed first in the list of the activated defaults.
Related keywords:
Example 1:
var default vd_DefaultVar := null;
DefaultVar := activate(as_MyDefAltstep());
The variable DefaultVar will hold the reference to the altstep activated as default (as_MyDelAltstep).
BNF definition of activate