Save This Page
Home » dom4j-1.6.1 » org.dom4j.rule » [javadoc | source]
org.dom4j.rule
public interface: Pattern [javadoc | source]

All Implemented Interfaces:
    NodeFilter

All Known Implementing Classes:
    NodeTypePattern, DefaultPattern, XPathPattern

Pattern defines the behaviour for pattern in the XSLT processing model.

Field Summary
 short ANY_NODE    Matches any node 
 short NONE    Matches no nodes 
 short NUMBER_OF_TYPES    Count of the number of node types 
 double DEFAULT_PRIORITY    According to the spec we should return 0.5 if we cannot determine the priority 
Method from org.dom4j.rule.Pattern Summary:
getMatchType,   getMatchesNodeName,   getPriority,   getUnionPatterns,   matches
Method from org.dom4j.rule.Pattern Detail:
 public short getMatchType()
    DOCUMENT ME!
 public String getMatchesNodeName()
    For patterns which only match an ATTRIBUTE_NODE or an ELEMENT_NODE then this pattern may return the name of the element or attribute it matches. This allows a more efficient rule matching algorithm to be performed, rather than a brute force approach of evaluating every pattern for a given Node.
 public double getPriority()
 public Pattern[] getUnionPatterns()
    If this pattern is a union pattern then this method should return an array of patterns which describe the union pattern, which should contain more than one pattern. Otherwise this method should return null.
 public boolean matches(Node node)
    DOCUMENT ME!