com.werken.saxpath
Class XPathReader

java.lang.Object
  |
  +--com.werken.saxpath.XPathReader
All Implemented Interfaces:
SAXPathEventSource, com.werken.saxpath.TokenTypes, XPathReader

public class XPathReader
extends Object
implements XPathReader, com.werken.saxpath.TokenTypes

Implementation of SAXPath's XPathReader which generates callbacks to an XPathHandler.

Author:
bob mcwhirter (bob@werken.com)

Field Summary
static int AND
           
static int AT
           
static int COLON
           
static int COMMA
           
static int DIV
           
static int DOLLAR
           
static int DOT
           
static int DOT_DOT
           
static int DOUBLE
           
static int DOUBLE_COLON
           
static int DOUBLE_SLASH
           
static int EOF
           
static int EQUALS
           
static int GREATER_THAN
           
static int GREATER_THAN_EQUALS
           
static int IDENTIFIER
           
static int INTEGER
           
static int LEFT_BRACKET
           
static int LEFT_PAREN
           
static int LESS_THAN
           
static int LESS_THAN_EQUALS
           
static int LITERAL
           
static int MINUS
           
static int MOD
           
static int NOT
           
static int NOT_EQUALS
           
static int OR
           
static int PIPE
           
static int PLUS
           
static int RIGHT_BRACKET
           
static int RIGHT_PAREN
           
static int SKIP
           
static int SLASH
           
static int STAR
           
 
Constructor Summary
XPathReader()
           
 
Method Summary
 XPathHandler getXPathHandler()
          Retrieve the current XPathHandler which receives the event callbacks.
 void parse(String xpath)
          Perform parsing of the textual XPath expression, and produce event callbacks to an XPathHandler.
 void setXPathHandler(XPathHandler handler)
          Set the XPathHandler to receive event callbacks during the parse.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LEFT_PAREN

public static final int LEFT_PAREN

RIGHT_PAREN

public static final int RIGHT_PAREN

LEFT_BRACKET

public static final int LEFT_BRACKET

RIGHT_BRACKET

public static final int RIGHT_BRACKET

PLUS

public static final int PLUS

MINUS

public static final int MINUS

LESS_THAN

public static final int LESS_THAN

LESS_THAN_EQUALS

public static final int LESS_THAN_EQUALS

GREATER_THAN

public static final int GREATER_THAN

GREATER_THAN_EQUALS

public static final int GREATER_THAN_EQUALS

SLASH

public static final int SLASH

DOUBLE_SLASH

public static final int DOUBLE_SLASH

DOT

public static final int DOT

DOT_DOT

public static final int DOT_DOT

IDENTIFIER

public static final int IDENTIFIER

AT

public static final int AT

PIPE

public static final int PIPE

COLON

public static final int COLON

DOUBLE_COLON

public static final int DOUBLE_COLON

STAR

public static final int STAR

EQUALS

public static final int EQUALS

NOT_EQUALS

public static final int NOT_EQUALS

NOT

public static final int NOT

DIV

public static final int DIV

MOD

public static final int MOD

DOLLAR

public static final int DOLLAR

LITERAL

public static final int LITERAL

AND

public static final int AND

OR

public static final int OR

INTEGER

public static final int INTEGER

DOUBLE

public static final int DOUBLE

COMMA

public static final int COMMA

SKIP

public static final int SKIP

EOF

public static final int EOF
Constructor Detail

XPathReader

public XPathReader()
Method Detail

setXPathHandler

public void setXPathHandler(XPathHandler handler)
Description copied from interface: SAXPathEventSource
Set the XPathHandler to receive event callbacks during the parse.
Specified by:
setXPathHandler in interface SAXPathEventSource
Following copied from interface: org.saxpath.SAXPathEventSource
Parameters:
handler - The handler to receive callbacks.

getXPathHandler

public XPathHandler getXPathHandler()
Description copied from interface: SAXPathEventSource
Retrieve the current XPathHandler which receives the event callbacks.
Specified by:
getXPathHandler in interface SAXPathEventSource
Following copied from interface: org.saxpath.SAXPathEventSource
Returns:
The currently installed XPathHandler.

parse

public void parse(String xpath)
           throws SAXPathException
Description copied from interface: XPathReader
Perform parsing of the textual XPath expression, and produce event callbacks to an XPathHandler.
Specified by:
parse in interface XPathReader
Following copied from interface: org.saxpath.XPathReader
Parameters:
xpath - The textual XPath expression to parse.
Throws:
SAXPathException - In the event an error occurs.


Copyright © 2001 bob mcwhirter & James Strachan. All Rights Reserved. Hosted by

SourceForge Logo