public abstract class AbstractPattern extends Object implements Pattern
Pattern implementation.
Adds support for pattern for node identifiers.
| Constructor and Description |
|---|
AbstractPattern() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
int |
hashCode() |
LeafPattern<?,?> |
idPattern()
Returns the pattern on the node identifier.
|
boolean |
matches(Node node)
Indicates whether a node matches a pattern.
|
void |
prune(Node node)
Prunes a node of all the descendants that are not required to match the pattern.
|
void |
setIdPattern(LeafPattern<?,?> idp)
Set a predicate on the node identifier.
|
public void setIdPattern(LeafPattern<?,?> idp)
idp - the pattern.public LeafPattern<?,?> idPattern()
public boolean matches(Node node)
Patternpublic void prune(Node node) throws Exception
PatternCopyright © 2018. All Rights Reserved.