Class: Syntax::CatchSection

Inherits:
Treetop::Runtime::SyntaxNode
  • Object
show all
Defined in:
lib/silicon/routing/syntax/catch_section.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#commandObject (readonly)

Returns the value of attribute command.



3
4
5
# File 'lib/silicon/routing/syntax/catch_section.rb', line 3

def command
  @command
end

Instance Method Details

#parseObject



5
6
7
8
9
10
11
12
13
# File 'lib/silicon/routing/syntax/catch_section.rb', line 5

def parse
  elements[0].elements.each do |element|
    if element.is_a? Command
      @command = element.parse
    end
  end

  self
end