Class: ActionConductor::Definition
- Inherits:
-
Object
- Object
- ActionConductor::Definition
- Defined in:
- lib/action_conductor/definition.rb
Instance Attribute Summary collapse
-
#class_name ⇒ Object
readonly
Returns the value of attribute class_name.
-
#handle ⇒ Object
readonly
Returns the value of attribute handle.
Instance Method Summary collapse
- #actions ⇒ Object
-
#initialize(configs = {}) ⇒ Definition
constructor
A new instance of Definition.
- #klass ⇒ Object
Constructor Details
#initialize(configs = {}) ⇒ Definition
Returns a new instance of Definition.
5 6 7 8 9 |
# File 'lib/action_conductor/definition.rb', line 5 def initialize(configs={}) @handle = configs.fetch(:handle) @actions = configs.fetch(:actions, []) @class_name = configs.fetch(:class_name, @handle) end |
Instance Attribute Details
#class_name ⇒ Object (readonly)
Returns the value of attribute class_name.
3 4 5 |
# File 'lib/action_conductor/definition.rb', line 3 def class_name @class_name end |
#handle ⇒ Object (readonly)
Returns the value of attribute handle.
3 4 5 |
# File 'lib/action_conductor/definition.rb', line 3 def handle @handle end |
Instance Method Details
#actions ⇒ Object
15 16 17 |
# File 'lib/action_conductor/definition.rb', line 15 def actions @actions ||= Set.new(@actions) end |
#klass ⇒ Object
11 12 13 |
# File 'lib/action_conductor/definition.rb', line 11 def klass @conductor_klass ||= conductor_klass end |