Class IDIndexer
java.lang.Object
org.exolab.adaptx.xml.IDIndexer
A utility class which helps overcome some DOM 1.0 deficiencies.
- Version:
- $Revision: 3633 $ $Date: 2003-03-01 08:38:44 +0100 (Sat, 01 Mar 2003) $
- Author:
- Keith Visco
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddIdAttribute(String attrName, String appliesTo) Adds the given attribute name as an ID attribute.voidaddIdReference(String id, XPathNode node) Associates the given Id with the given ElementgetElementById(XPathNode root, String id) Determines the document order of a given node.
-
Constructor Details
-
IDIndexer
public IDIndexer()Creates a new DOMHelper
-
-
Method Details
-
addIdAttribute
-
addIdReference
-
getElementById
Determines the document order of a given node. Document Order is defined by the document order of the parent of the given node and the childNumber of the given Node. The document order for a Document node is 0.- Parameters:
root- the "root" XPathNode to search withinid- the Id of the element to return- Returns:
- the element XPathNode that is associated with the given Id, or null if no XPathNode was found
- See Also:
-