Class: StateFlow::Event
- Includes:
- ActionClient, ExceptionHandlerClient, GuardClient
- Defined in:
- lib/state_flow/event.rb
Direct Known Subclasses
Instance Attribute Summary
Attributes inherited from Element
Instance Method Summary collapse
Methods included from ExceptionHandlerClient
#exception_handlers, #exception_handling
Methods included from ActionClient
Methods included from GuardClient
#guard, #guard_else, #guard_for, #guards
Methods inherited from Element
#flow, #initialize, #inspect, #retry_in_recovering, #state, #to, uninspected_var, uninspected_vars, #update_to_destination
Methods included from ElementVisitable
Constructor Details
This class inherits a constructor from StateFlow::Element
Instance Method Details
#process(context) ⇒ Object
10 11 12 13 14 15 16 17 18 |
# File 'lib/state_flow/event.rb', line 10 def process(context) context.trace(self) if guard = guard_for(context) guard.process(context) else action.process(context) if action end update_to_destination(context) end |