Prev Class | Next Class | Frames | No Frames |
Summary: Nested | Field | Method | Constr | Detail: Nested | Field | Method | Constr |
java.lang.Object
org.jaxen.DefaultNavigator
Navigator
.
This implementation is an abstract class, since
some required operations cannot be implemented without
additional knowledge of the object model.
When possible, default method implementations build
upon each other, to reduce the number of methods required
to be implemented for each object model. All methods,
of course, may be overridden, to provide more-efficient
implementations.
Method Summary | |
Iterator |
|
Iterator |
|
Iterator |
|
Iterator |
|
Iterator |
|
Iterator |
|
Object |
|
Object |
|
Object |
|
Iterator |
|
Iterator |
|
Iterator |
|
short |
|
Iterator |
|
Object |
|
Iterator |
|
Iterator |
|
String |
|
String |
|
Iterator |
|
String |
|
public Iterator getAncestorAxisIterator(Object contextNode) throws UnsupportedAxisException
- Specified by:
- getAncestorAxisIterator in interface Navigator
public Iterator getAncestorOrSelfAxisIterator(Object contextNode) throws UnsupportedAxisException
- Specified by:
- getAncestorOrSelfAxisIterator in interface Navigator
public Iterator getAttributeAxisIterator(Object contextNode) throws UnsupportedAxisException
ThrowsUnsupportedAxisException
. Subclasses that support the attribute axis must override this method.
- Specified by:
- getAttributeAxisIterator in interface Navigator
- Parameters:
contextNode
-
- Returns:
- never returns
- Throws:
UnsupportedAxisException
-
public Iterator getChildAxisIterator(Object contextNode) throws UnsupportedAxisException
ThrowsUnsupportedAxisException
- Specified by:
- getChildAxisIterator in interface Navigator
- Parameters:
contextNode
-
- Returns:
- never returns
- Throws:
UnsupportedAxisException
- always
public Iterator getDescendantAxisIterator(Object contextNode) throws UnsupportedAxisException
- Specified by:
- getDescendantAxisIterator in interface Navigator
public Iterator getDescendantOrSelfAxisIterator(Object contextNode) throws UnsupportedAxisException
- Specified by:
- getDescendantOrSelfAxisIterator in interface Navigator
public Object getDocument(String url) throws FunctionCallException
Default implementation that always returns null. Override in subclass if the subclass can load documents.
- Specified by:
- getDocument in interface Navigator
- Parameters:
url
- the URL of the document to load
- Returns:
- null
- Throws:
FunctionCallException
- if an error occurs while loading the URL; e.g. an I/O error or the document is malformed
public Object getDocumentNode(Object contextNode)
- Specified by:
- getDocumentNode in interface Navigator
public Object getElementById(Object contextNode, String elementId)
Default implementation that cannot find elements. Override in subclass if subclass does know about attribute types.
- Specified by:
- getElementById in interface Navigator
- Parameters:
contextNode
- a node from the document in which to look for the idelementId
- id to look for
- Returns:
- null
public Iterator getFollowingAxisIterator(Object contextNode) throws UnsupportedAxisException
- Specified by:
- getFollowingAxisIterator in interface Navigator
public Iterator getFollowingSiblingAxisIterator(Object contextNode) throws UnsupportedAxisException
- Specified by:
- getFollowingSiblingAxisIterator in interface Navigator
public Iterator getNamespaceAxisIterator(Object contextNode) throws UnsupportedAxisException
ThrowsUnsupportedAxisException
. Subclasses that support the namespace axis must override this method.
- Specified by:
- getNamespaceAxisIterator in interface Navigator
- Parameters:
contextNode
-
- Returns:
- never returns
- Throws:
UnsupportedAxisException
-
public Iterator getParentAxisIterator(Object contextNode) throws UnsupportedAxisException
ThrowsUnsupportedAxisException
- Specified by:
- getParentAxisIterator in interface Navigator
- Parameters:
contextNode
-
- Returns:
- never returns
- Throws:
UnsupportedAxisException
-
public Object getParentNode(Object contextNode) throws UnsupportedAxisException
Default inefficient implementation. Subclasses should override this method.
- Specified by:
- getParentNode in interface Navigator
- Parameters:
contextNode
- the node whose parent to return
- Returns:
- the parent node
- Throws:
UnsupportedAxisException
- if the parent axis is not supported
public Iterator getPrecedingAxisIterator(Object contextNode) throws UnsupportedAxisException
- Specified by:
- getPrecedingAxisIterator in interface Navigator
public Iterator getPrecedingSiblingAxisIterator(Object contextNode) throws UnsupportedAxisException
- Specified by:
- getPrecedingSiblingAxisIterator in interface Navigator
public String getProcessingInstructionData(Object obj)
- Specified by:
- getProcessingInstructionData in interface Navigator
public String getProcessingInstructionTarget(Object obj)
- Specified by:
- getProcessingInstructionTarget in interface Navigator
public Iterator getSelfAxisIterator(Object contextNode) throws UnsupportedAxisException
- Specified by:
- getSelfAxisIterator in interface Navigator
public String translateNamespacePrefixToUri(String prefix, Object element)
- Specified by:
- translateNamespacePrefixToUri in interface Navigator