Class: RedShift::Transition
- Extended by:
- AccessibleIndex
- Defined in:
- lib/redshift/component.rb
Overview
put this in meta?
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(spec) ⇒ Transition
constructor
A new instance of Transition.
Methods included from AccessibleIndex
index_accessor, index_reader, index_writer
Methods inherited from XArray
Methods inherited from Array
Constructor Details
#initialize(spec) ⇒ Transition
Returns a new instance of Transition.
70 71 72 73 74 75 76 77 78 79 80 81 |
# File 'lib/redshift/component.rb', line 70 def initialize spec if spec.kind_of? Hash spec = spec.dup def spec.method_missing(m, *); self[m]; end end @name = spec.name || "transition_#{object_id}".intern self.guard = spec.guards; self.sync = spec.syncs self.action = spec.actions; self.reset = spec.resets self.event = spec.events; self.post = spec.posts self.connect = spec.connects end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
61 62 63 |
# File 'lib/redshift/component.rb', line 61 def name @name end |