Class: ActionNode

Inherits:
Node
  • Object
show all
Defined in:
lib/code_generator.rb

Instance Method Summary collapse

Methods inherited from Node

#column

Constructor Details

#initialize(action, consequence) ⇒ ActionNode

Returns a new instance of ActionNode.



253
254
255
256
# File 'lib/code_generator.rb', line 253

def initialize action, consequence
  @action = action
  @consequence = consequence
end

Instance Method Details

#genObject



258
259
260
# File 'lib/code_generator.rb', line 258

def gen
  "ON #{@action} #{@consequence}"
end