Sha256: c9eea8cb852b9976d531c01abeb60b44c13d7706442d327c44b943f9a658beb7

Contents?: true

Size: 744 Bytes

Versions: 8

Compression:

Stored size: 744 Bytes

Contents

module Xcode
  class Project
    class Config
      class ObjectNode < Hash
        include Decomment

        def initialize(io)
          ios = IOScanner.new(io)
          key = nil
          value = nil

          while token = ios.tokenize
            case token
            when ?}
              return
            when ?=
              key = decomment(ios.term)
              value = nil
            when ?{
              value = ObjectNode.new(io)
            when ?(
              value = ArrayNode.new(io)
            when ?;
              value = decomment(ios.term) if value.nil?
              self[key] = value
            end
          end
        end

        def isa
          self['isa']
        end
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
xcode-0.1.6 lib/xcode/project/config/object_node.rb
xcode-0.1.5 lib/xcode/project/config/object_node.rb
xcode-0.1.4 lib/xcode/project/config/object_node.rb
xcode-0.1.3 lib/xcode/project/config/object_node.rb
xcode-0.1.2 lib/xcode/project/config/object_node.rb
xcode-0.1.1 lib/xcode/project/config/object_node.rb
xcode-0.1.0 lib/xcode/project/config/object_node.rb
xcode-0.0.1 lib/xcode/project/config/object_node.rb