Class: VStudioIDE::SLNGlobalNode

Inherits:
SLNNode
  • Object
show all
Defined in:
lib/vstudioide/sln_node.rb

Instance Method Summary collapse

Constructor Details

#initialize(io) ⇒ SLNGlobalNode

Returns a new instance of SLNGlobalNode.



11
12
13
14
# File 'lib/vstudioide/sln_node.rb', line 11

def initialize(io)
  @sections = []
  parse io
end

Instance Method Details

#[](arg) ⇒ Object



16
17
18
19
20
# File 'lib/vstudioide/sln_node.rb', line 16

def [](arg)
  return @sections[arg] if arg.is_a? Fixnum
  @sections.each { |s| return s if s.type == arg }
  nil
end