public abstract class MultiNodePattern<T>
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
protected static class |
MultiNodePattern.IntersectMultiNodePattern<T> |
protected static class |
MultiNodePattern.UnionMultiNodePattern<T> |
Constructor and Description |
---|
MultiNodePattern() |
Modifier and Type | Method and Description |
---|---|
int |
getMaxNodes() |
int |
getMinNodes() |
boolean |
isGreedyMatch() |
protected abstract java.util.Collection<Interval<java.lang.Integer>> |
match(java.util.List<? extends T> nodes,
int start)
Tries to match sequence of nodes starting of start
Returns intervals (token offsets) of when the nodes matches
|
void |
setGreedyMatch(boolean greedyMatch) |
void |
setMaxNodes(int maxNodes) |
void |
setMinNodes(int minNodes) |
protected abstract java.util.Collection<Interval<java.lang.Integer>> match(java.util.List<? extends T> nodes, int start)
nodes
- start
- public int getMinNodes()
public void setMinNodes(int minNodes)
public int getMaxNodes()
public void setMaxNodes(int maxNodes)
public boolean isGreedyMatch()
public void setGreedyMatch(boolean greedyMatch)