Class: ActiveRecordImporter::TransitionProcessor
- Inherits:
-
Object
- Object
- ActiveRecordImporter::TransitionProcessor
- Defined in:
- lib/active_record_importer/transition_processor.rb
Instance Attribute Summary collapse
-
#column ⇒ Object
readonly
Returns the value of attribute column.
-
#new_state ⇒ Object
readonly
Returns the value of attribute new_state.
-
#object ⇒ Object
readonly
Returns the value of attribute object.
Instance Method Summary collapse
-
#initialize(object, new_state, column = :state) ⇒ TransitionProcessor
constructor
A new instance of TransitionProcessor.
- #transit ⇒ Object
Constructor Details
#initialize(object, new_state, column = :state) ⇒ TransitionProcessor
Returns a new instance of TransitionProcessor.
6 7 8 9 10 |
# File 'lib/active_record_importer/transition_processor.rb', line 6 def initialize(object, new_state, column = :state) @object = object @new_state = new_state @column = column end |
Instance Attribute Details
#column ⇒ Object (readonly)
Returns the value of attribute column.
4 5 6 |
# File 'lib/active_record_importer/transition_processor.rb', line 4 def column @column end |
#new_state ⇒ Object (readonly)
Returns the value of attribute new_state.
4 5 6 |
# File 'lib/active_record_importer/transition_processor.rb', line 4 def new_state @new_state end |
#object ⇒ Object (readonly)
Returns the value of attribute object.
4 5 6 |
# File 'lib/active_record_importer/transition_processor.rb', line 4 def object @object end |
Instance Method Details
#transit ⇒ Object
12 13 14 15 |
# File 'lib/active_record_importer/transition_processor.rb', line 12 def transit fire_event!(transit_event) true end |