Extensions.StateMachineProcedure.StateMachineProcedureRealisation

From emotive
Jump to navigation Jump to search

Classification

Name StateMachineProcedureRealisation
Short Description Specifies the procedure implementation parts.
Class Procedure
Extension OTX StateMachineProcedure extension
Group StateMachineProcedure related procedures
Exceptions -
Checker Rules Core_Chk058 - unique OtxIds

StateMachineProcedure_Chk006 – Initial and completed state will be distinguished
StateMachineProcedure_Chk007 – Correct nesting of initial state
StateMachineProcedure_Chk008 – Correct nesting of completed state

Standard Compliant Yes

Description

Exclamation.png Important: The added key constraints for unique OtxIds related to state machines cannot cover OtxIds of an other state machine procedure inside the same document.

Parameters

Name Data Type Class Default Cardinality Description
InitialState OtxName - - [1] Defines the initial state of the state machine. The value will exist and will be distinguished from the value of attribute CompletedState.

The initial state is the first state after starting the procedure execution.

CompletedState OtxName - - [0..1] Defines the completed state of the state-machine. The value is optional and will be distinguished from the value of attribute InitialState.

After finishing the completed state the procedure is finished and will return to the caller.

Comments Comments - - [1..1] This is a container for an arbitrary-length list comments. They will be used for commenting parts of the procedure flow implementation for the human reader. For more information please refer to ISO 13209-2.
Exclamation.png Important: Entities to which a comment's <link> may point to are described in ISO 13209-2 (e.g. to flow nodes, branch case conditions, loop conditions). In addition, state machine comments can refer to states, transitions, transition conditions, triggers as well as state machine comments themselves.
Parameters Parameters - - [0..1] Parameters of the procedure. For more information please refer to ISO 13209-2.
Declarations LocalDeclarations - - [0..1] SLocal variables and constants of the procedure. For more information please refer to ISO 13209-2.
Throws Throw - - [0..1] Exceptions of the procedure. For more information please refer to ISO 13209-2.
States States - - [1] States of a state machine. A state machine consists of at least one state. There are two special states, the initial state and the (optional) completed state. The mandatory initial state is the first state and the optional completed state is the last state of the state machine.

OTL Examples

public stateMachine StateMachine1() initialState InitialState completedState CompletedState
{
	/// Local Declarations

	/// States

	state : InitialState
	{
		triggers()
		{
			trigger : Trigger1
			{
				EventHandling.TimerExpiredEventSource(1000)
			}
		}
		transitions
		{
			transition({Trigger1}) : Transition1 target CompletedState
			{
			}
		}
	}
		
	state : CompletedState
	{
	}
}