Macro macro_machines::def_machine_nodefault
[−]
[src]
macro_rules! def_machine_nodefault { ( machine $machine:ident $(<$( $type_var:ident $(: { $($type_constraint:path),+ })* ),+>)* { STATES [ $(state $state:ident ( $($data_name:ident : $data_type:ty $(= $data_default:expr)*),* ))+ ] EVENTS [ $(event $event:ident <$source:tt> $(=> <$target:ident>)* ($($param_name:ident : $param_type:ty $(= $param_default:expr)*),*) $({ $($state_data:ident),* } => $action:block)* )+ ] EXTENDED [ $($ext_name:ident : $ext_type:ty $(= $ext_default:expr)*),* ] $(self_reference: $self_reference:ident)* initial_state: $initial:ident $({ $(initial_action: $initial_action:block)* })* $(terminal_state: $terminal:ident $({ $(terminate_success: $terminate_success:block)* $(terminate_failure: $terminate_failure:block)* })*)* } ) => { ... }; ( $machine:ident $(<$( $type_var:ident $(: { $($type_constraint:path),+ })* ),+>)* $(($( $ext_name:ident : $ext_type:ty $(= $ext_default:expr)* ),*))* $(@ $self_reference:ident)* { STATES [ $(state $state:ident ( $($data_name:ident : $data_type:ty $(= $data_default:expr)*),* ))+ ] EVENTS [ $(event $event:ident <$source:tt> $(=> <$target:ident>)* ($($param_name:ident : $param_type:ty $(= $param_default:expr)*),*) $({ $($state_data:ident),* } => $action:block)* )+ ] initial_state: $initial:ident $({ $(initial_action: $initial_action:block)* })* $(terminal_state: $terminal:ident $({ $(terminate_success: $terminate_success:block)* $(terminate_failure: $terminate_failure:block)* })*)* } ) => { ... }; }
State machine that requires runtime initialization.