123456789_123456789_123456789_123456789_123456789_

Class: REXML::XPathNode Private

Do not use. This class is for internal use only.
Relationships & Source Files
Inherits: Object
Defined in: lib/rexml/xpath_parser.rb

Class Method Summary

Instance Attribute Summary

Instance Method Summary

Constructor Details

.new(node, context = nil) ⇒ XPathNode

[ GitHub ]

  
# File 'lib/rexml/xpath_parser.rb', line 961

def initialize(node, context=nil)
  if node.is_a?(XPathNode)
    @raw_node = node.raw_node
  else
    @raw_node = node
  end
  @context = context || {}
end

Instance Attribute Details

#context (readonly)

[ GitHub ]

  
# File 'lib/rexml/xpath_parser.rb', line 960

attr_reader :raw_node, :context

#raw_node (readonly)

[ GitHub ]

  
# File 'lib/rexml/xpath_parser.rb', line 960

attr_reader :raw_node, :context

Instance Method Details

#position

[ GitHub ]

  
# File 'lib/rexml/xpath_parser.rb', line 970

def position
  @context[:position]
end