Class: TwoWaySQL::BeginNode

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

Instance Method Summary collapse

Constructor Details

#initialize(tree) ⇒ BeginNode

Returns a new instance of BeginNode.



122
123
124
# File 'lib/twowaysql/node.rb', line 122

def initialize(tree)
  @tree = tree
end

Instance Method Details

#accept(ctx) ⇒ Object



125
126
127
128
129
130
131
# File 'lib/twowaysql/node.rb', line 125

def accept(ctx)
  child_ctx = ctx.fork_child
  exec_list(@tree, child_ctx)
  if child_ctx.enabled?
    ctx.join_child(child_ctx)
  end
end