Class: Coupler::Models::Transformer::Runner
- Inherits:
-
Object
- Object
- Coupler::Models::Transformer::Runner
show all
- Defined in:
- lib/coupler/models/transformer/runner.rb
Instance Method Summary
collapse
Constructor Details
#initialize(code, input) ⇒ Runner
Returns a new instance of Runner.
9
10
11
12
|
# File 'lib/coupler/models/transformer/runner.rb', line 9
def initialize(code, input)
@input = input
@code = code
end
|
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name) ⇒ Object
22
23
24
|
# File 'lib/coupler/models/transformer/runner.rb', line 22
def method_missing(name)
raise NoMethodError
end
|
Instance Method Details
#run ⇒ Object
14
15
16
|
# File 'lib/coupler/models/transformer/runner.rb', line 14
def run
instance_eval(@code, __FILE__, __LINE__)
end
|
#value ⇒ Object
18
19
20
|
# File 'lib/coupler/models/transformer/runner.rb', line 18
def value
@input
end
|