Class: LcpRuby::Workflow::TransitionResult
- Inherits:
-
Object
- Object
- LcpRuby::Workflow::TransitionResult
- Defined in:
- lib/lcp_ruby/workflow/transition_result.rb
Instance Attribute Summary collapse
-
#deferred_events ⇒ Object
readonly
Returns the value of attribute deferred_events.
-
#from_state ⇒ Object
readonly
Returns the value of attribute from_state.
-
#record ⇒ Object
readonly
Returns the value of attribute record.
-
#to_state ⇒ Object
readonly
Returns the value of attribute to_state.
-
#transition_name ⇒ Object
readonly
Returns the value of attribute transition_name.
Instance Method Summary collapse
-
#initialize(success:, transition_name:, from_state:, to_state:, record:, deferred_events: []) ⇒ TransitionResult
constructor
A new instance of TransitionResult.
- #success? ⇒ Boolean
Constructor Details
#initialize(success:, transition_name:, from_state:, to_state:, record:, deferred_events: []) ⇒ TransitionResult
Returns a new instance of TransitionResult.
6 7 8 9 10 11 12 13 |
# File 'lib/lcp_ruby/workflow/transition_result.rb', line 6 def initialize(success:, transition_name:, from_state:, to_state:, record:, deferred_events: []) @success = success @transition_name = transition_name @from_state = from_state @to_state = to_state @record = record @deferred_events = deferred_events end |
Instance Attribute Details
#deferred_events ⇒ Object (readonly)
Returns the value of attribute deferred_events.
4 5 6 |
# File 'lib/lcp_ruby/workflow/transition_result.rb', line 4 def deferred_events @deferred_events end |
#from_state ⇒ Object (readonly)
Returns the value of attribute from_state.
4 5 6 |
# File 'lib/lcp_ruby/workflow/transition_result.rb', line 4 def from_state @from_state end |
#record ⇒ Object (readonly)
Returns the value of attribute record.
4 5 6 |
# File 'lib/lcp_ruby/workflow/transition_result.rb', line 4 def record @record end |
#to_state ⇒ Object (readonly)
Returns the value of attribute to_state.
4 5 6 |
# File 'lib/lcp_ruby/workflow/transition_result.rb', line 4 def to_state @to_state end |
#transition_name ⇒ Object (readonly)
Returns the value of attribute transition_name.
4 5 6 |
# File 'lib/lcp_ruby/workflow/transition_result.rb', line 4 def transition_name @transition_name end |
Instance Method Details
#success? ⇒ Boolean
15 16 17 |
# File 'lib/lcp_ruby/workflow/transition_result.rb', line 15 def success? @success == true end |