class Nasl::Switch
Attributes
body[R]
switch_expr[R]
switch_op[R]
Public Class Methods
new(tree, *tokens)
click to toggle source
Calls superclass method
Nasl::Node::new
# File lib/nasl/parser/switch.rb, line 33 def initialize(tree, *tokens) super if @tokens.length == 5 @switch_op = nil @switch_expr = @tokens[2] @body = @tokens[4] else @switch_op = @tokens[2] @switch_expr = @tokens[5] @body = @tokens[7] end @children << :switch_op @children << :switch_expr @children << :body end