Class: WIP::Runner::Workflow::Builder::Component
- Inherits:
-
Object
- Object
- WIP::Runner::Workflow::Builder::Component
show all
- Defined in:
- lib/wip/runner/workflow/builder/component.rb
Instance Method Summary
collapse
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method_name, *args, &block) ⇒ Object
20
21
22
23
24
25
26
|
# File 'lib/wip/runner/workflow/builder/component.rb', line 20
def method_missing(method_name, *args, &block)
if @command.respond_to?(method_name)
@command.send(method_name, *args, &block)
else
super
end
end
|
Instance Method Details
#prologue(value = nil) ⇒ Object
5
6
7
8
|
# File 'lib/wip/runner/workflow/builder/component.rb', line 5
def prologue(value = nil)
@prologue = clean(value) unless value.nil?
@prologue
end
|
#respond_to_missing?(method_name, include_private = false) ⇒ Boolean
28
29
30
|
# File 'lib/wip/runner/workflow/builder/component.rb', line 28
def respond_to_missing?(method_name, include_private = false)
@command.respond_to?(method_name) || super
end
|
#shell(*args) ⇒ Object
10
11
12
13
14
|
# File 'lib/wip/runner/workflow/builder/component.rb', line 10
def shell(*args)
unless args.empty?
shells << [args[0], clean(args[1])]
end
end
|
#shells ⇒ Object
16
17
18
|
# File 'lib/wip/runner/workflow/builder/component.rb', line 16
def shells
@shells ||= []
end
|