Class: RuntimeMethodLiteral
- Defined in:
- lib/core/literal/RuntimeMethodLiteral.rb
Overview
TODO Perhaps RuntimeMethodDeclaration might have worked better
Instance Method Summary collapse
-
#copy ⇒ Object
TODO This copy isn’t accurate.
-
#initialize(usage, return_variable) ⇒ RuntimeMethodLiteral
constructor
A new instance of RuntimeMethodLiteral.
- #write ⇒ Object
Constructor Details
#initialize(usage, return_variable) ⇒ RuntimeMethodLiteral
Returns a new instance of RuntimeMethodLiteral.
5 6 7 8 9 |
# File 'lib/core/literal/RuntimeMethodLiteral.rb', line 5 def initialize(usage,return_variable) raise StandardError.new('Where is this used') @usage = usage @return_variable = return_variable end |
Instance Method Details
#copy ⇒ Object
TODO This copy isn’t accurate
17 18 19 |
# File 'lib/core/literal/RuntimeMethodLiteral.rb', line 17 def copy return RuntimeMethodLiteral.new(@usage.copy, @return_variable.copy) end |
#write ⇒ Object
11 12 13 14 |
# File 'lib/core/literal/RuntimeMethodLiteral.rb', line 11 def write # TODO This shouldn't just make up values return 'RuntimeMethod.new('+@usage.to_declaration.write+','+@return_variable.to_declaration.write+')' end |