require 'vstudioide/core_ext/string' require 'vstudioide/sln_node' module VStudioIDE class SLNDocument attr_reader :global attr_reader :projects def initialize(io) @global = nil @projects = [] parse io end private def parse(io) while io.gets $_.strip! if $_ == "Global" @global = SLNGlobalNode.new(io) elsif $_.begin? "Project" @projects << SLNProjectNode.new($_, io) end end end end end