Class: IronWorkerNG::Code::Creator
Class Method Summary
collapse
Instance Method Summary
collapse
#guess_name_for_path, #initialize_code
Constructor Details
#initialize(*args, &block) ⇒ Creator
Returns a new instance of Creator.
20
21
22
|
# File 'lib/iron_worker_ng/code/creator.rb', line 20
def initialize(*args, &block)
initialize_code(*args, &block)
end
|
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *args) ⇒ Object
59
60
|
# File 'lib/iron_worker_ng/code/creator.rb', line 59
def method_missing(name, *args)
end
|
Class Method Details
.create(*args, &block) ⇒ Object
14
15
16
17
18
|
# File 'lib/iron_worker_ng/code/creator.rb', line 14
def self.create(*args, &block)
runtime = IronWorkerNG::Code::Creator.new(*args, &block).runtime || 'ruby'
IronWorkerNG::Code::Base.registered_types.find { |r| r[:name] == runtime }[:klass].new(*args, &block)
end
|
Instance Method Details
#merge_exec(path, *args) ⇒ Object
Also known as:
exec, merge_worker
50
51
52
|
# File 'lib/iron_worker_ng/code/creator.rb', line 50
def merge_exec(path, *args)
@exec = OpenStruct.new(:path => path)
end
|
#name(name = nil) ⇒ Object
24
25
26
27
28
|
# File 'lib/iron_worker_ng/code/creator.rb', line 24
def name(name = nil)
@name = name if name
@name
end
|
#name=(name) ⇒ Object
30
31
32
|
# File 'lib/iron_worker_ng/code/creator.rb', line 30
def name=(name)
@name = name
end
|
#remote_build_command(remote_build_command = nil) ⇒ Object
34
35
|
# File 'lib/iron_worker_ng/code/creator.rb', line 34
def remote_build_command(remote_build_command = nil)
end
|
#remote_build_command=(remote_build_command) ⇒ Object
37
38
|
# File 'lib/iron_worker_ng/code/creator.rb', line 37
def remote_build_command=(remote_build_command)
end
|
#runtime(*args) ⇒ Object
40
41
42
43
44
|
# File 'lib/iron_worker_ng/code/creator.rb', line 40
def runtime(*args)
@runtime = args[0] if args.length == 1
@runtime
end
|
#runtime=(runtime) ⇒ Object
46
47
48
|
# File 'lib/iron_worker_ng/code/creator.rb', line 46
def runtime=(runtime)
@runtime = runtime
end
|