Package org.xhtmlrenderer.css.extend
Interface TreeResolver
-
- All Known Implementing Classes:
DOMTreeResolver
public interface TreeResolver- Author:
- scott Gives the css matcher access to the information it needs about the tree structure. Elements are the "things" in the tree structure that can be matched by the matcher.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringNO_NAMESPACE
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.StringgetElementName(java.lang.Object element)returns the name of the element so that it may match against the selectorsjava.lang.ObjectgetParentElement(java.lang.Object element)returns the parent element of an element, or null if this was the root elementjava.lang.ObjectgetPreviousSiblingElement(java.lang.Object node)The previous sibling element, or null if none existsbooleanisFirstChildElement(java.lang.Object element)returns true if this element is the first child element of its parentbooleanmatchesElement(java.lang.Object element, java.lang.String namespaceURI, java.lang.String name)Returnstrueifelementhas the local namenameand namespace URInamespaceURI.
-
-
-
Method Detail
-
getParentElement
java.lang.Object getParentElement(java.lang.Object element)
returns the parent element of an element, or null if this was the root element
-
getElementName
java.lang.String getElementName(java.lang.Object element)
returns the name of the element so that it may match against the selectors
-
getPreviousSiblingElement
java.lang.Object getPreviousSiblingElement(java.lang.Object node)
The previous sibling element, or null if none exists
-
isFirstChildElement
boolean isFirstChildElement(java.lang.Object element)
returns true if this element is the first child element of its parent
-
matchesElement
boolean matchesElement(java.lang.Object element, java.lang.String namespaceURI, java.lang.String name)Returnstrueifelementhas the local namenameand namespace URInamespaceURI.- Parameters:
element-namespaceURI- The namespace to match, may be null to signify any namespace. UseNO_NAMESPACEto signify thatnameshould only match when there is no namespace defined onelement.name- The name to match, may not be null
-
-