org.jaxen.saxpath
Class Axis
public class Axis
extends java.lang.Object
Internal SAXPath class that contains constants representing
XPath operators to avoid a lot of string comparisons.
static int | lookup(String axisName)-
Returns the code for an axis given its name.
|
static String | lookup(int axisNum)-
Returns the name of the axis.
|
ANCESTOR
public static final int ANCESTOR
The ancestor axis
ANCESTOR_OR_SELF
public static final int ANCESTOR_OR_SELF
The ancestor-or-self axis
ATTRIBUTE
public static final int ATTRIBUTE
The attribute axis
CHILD
public static final int CHILD
The child axis
DESCENDANT
public static final int DESCENDANT
The descendant axis
DESCENDANT_OR_SELF
public static final int DESCENDANT_OR_SELF
The descendant-or-self axis
FOLLOWING
public static final int FOLLOWING
The following axis
FOLLOWING_SIBLING
public static final int FOLLOWING_SIBLING
The following-sibling axis
INVALID_AXIS
public static final int INVALID_AXIS
Marker for an invalid axis
NAMESPACE
public static final int NAMESPACE
The namespace axis
PARENT
public static final int PARENT
The parent axis
PRECEDING
public static final int PRECEDING
The preceding axis
PRECEDING_SIBLING
public static final int PRECEDING_SIBLING
The preceding-sibling axis
SELF
public static final int SELF
The self axis
lookup
public static int lookup(String axisName)
Returns the code for an axis given its name.
axisName - the name of the axis: child, parent, descendant, descendant-or-self, etc.
lookup
public static String lookup(int axisNum)
Returns the name of the axis.
- the name of the axis such as might be used in an XPath expression