Class

REXML::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
ALL = [ :attribute, :element, :text, :processing_instruction, :comment ] Expr takes a stack of path elements and a set of nodes (either a Parent or an Array and returns an Array of matching nodes
ELEMENTS = [ :element ]
LITERAL = /^'([^']*)'|^"([^"]*)"/u

Methods

Class

Visibility Signature
public new ( )

Instance

Visibility Signature
public []= ( variable_name, value )
public first ( path_stack, node )
public get_first (path, nodeset)
public match ( path_stack, nodeset )
public namespaces= ( namespaces={} )
public parse (path, nodeset)
public predicate (path, nodeset)
public variables= ( vars={} )

Class Method Detail

new( )

Instance Method Detail

[]=( variable_name, value )

first( path_stack, node )

Performs a depth-first (document order) XPath search, and returns the first match. This is the fastest, lightest way to return a single result.

FIXME: This method is incomplete!

get_first(path, nodeset)

match( path_stack, nodeset )

namespaces=( namespaces={} )

parse(path, nodeset)

predicate(path, nodeset)

variables=( vars={} )