Class: Hospodar::Builder::Strategies::Execute
- Inherits:
-
Object
- Object
- Hospodar::Builder::Strategies::Execute
- Defined in:
- lib/hospodar/builder/strategies/execute.rb
Overview
Runs building process
Direct Known Subclasses
Instance Attribute Summary collapse
-
#factory ⇒ Object
readonly
Returns the value of attribute factory.
-
#strategy ⇒ Object
readonly
Returns the value of attribute strategy.
-
#target ⇒ Object
readonly
Returns the value of attribute target.
Instance Method Summary collapse
- #call(type = nil, &block) ⇒ Object
-
#initialize(strategy, target, factory) ⇒ Execute
constructor
A new instance of Execute.
Constructor Details
#initialize(strategy, target, factory) ⇒ Execute
10 11 12 13 14 |
# File 'lib/hospodar/builder/strategies/execute.rb', line 10 def initialize(strategy, target, factory) @strategy = strategy @target = target @factory = factory end |
Instance Attribute Details
#factory ⇒ Object (readonly)
Returns the value of attribute factory.
8 9 10 |
# File 'lib/hospodar/builder/strategies/execute.rb', line 8 def factory @factory end |
#strategy ⇒ Object (readonly)
Returns the value of attribute strategy.
8 9 10 |
# File 'lib/hospodar/builder/strategies/execute.rb', line 8 def strategy @strategy end |
#target ⇒ Object (readonly)
Returns the value of attribute target.
8 9 10 |
# File 'lib/hospodar/builder/strategies/execute.rb', line 8 def target @target end |
Instance Method Details
#call(type = nil, &block) ⇒ Object
16 17 18 19 |
# File 'lib/hospodar/builder/strategies/execute.rb', line 16 def call(type = nil, &block) run_with_error_handling { process(type, &block) } prepare_top end |