Class

REXML::Parsers::XPathParser

Inheritance
< Object
Included Modules
XMLTokens

You don‘t want to use this class. Really. Use XPath, which is a wrapper for this class. Believe me. You don‘t want to poke around in here. There is strange, dark magic at work in this code. Beware. Go back! Go back while you still can!

Constants

Name   Description
AXIS = /^(ancestor|ancestor-or-self|attribute|child|descendant|descendant-or-self|following|following-sibling|namespace|parent|preceding|preceding-sibling|self)::/ RelativeLocationPath
  |                                                    Step
    | (AXIS_NAME '::' | '@' | '')                     AxisSpecifier
      NodeTest
        Predicate
    | '.' | '..'                                      AbbreviatedStep
  |  RelativeLocationPath '/' Step
  | RelativeLocationPath '//' Step
LITERAL = /^'([^']*)'|^"([^"]*)"/u
NCNAMETEST = /^(#{NCNAME_STR}):\*/u
 Returns a 1-1 map of the nodeset
 The contents of the resulting array are either:
   true/false, if a positive match
   String, if a name match
NodeTest
  | ('*' | NCNAME ':' '*' | QNAME)                NameTest
  | NODE_TYPE '(' ')'                              NodeType
  | PI '(' LITERAL ')'                            PI
    | '[' expr ']'                                Predicate
NODE_TYPE = /^(comment|text|node)\(\s*\)/m
NT = /^comment|text|processing-instruction|node$/
NUMBER = /^(\d*\.?\d+)/
PI = /^processing-instruction\(/
QNAME = Namespace::NAMESPLIT
VARIABLE_REFERENCE = /^\$(#{NAME_STR})/u | VARIABLE_REFERENCE | ’(’ expr ’)’ | LITERAL | NUMBER | FunctionCall

Methods

Instance

Visibility Signature
public abbreviate ( path )
public expand ( path )
public namespaces= ( namespaces )
public parse (path)
public predicate (path)
public predicate_to_string ( path ) {|path| ...}

Instance Method Detail

abbreviate( path )

expand( path )

namespaces=( namespaces )

parse(path)

predicate(path)

predicate_to_string( path ) {|path| ...}