Modifier and Type | Field and Description |
---|---|
private int |
endIndex |
private boolean |
hasError |
private Matcher |
matcher |
private int |
startIndex |
private V |
value |
Constructor and Description |
---|
NodeImpl(Matcher matcher,
ImmutableLinkedList<Node<V>> children,
int startIndex,
int endIndex,
V value,
boolean hasError) |
Modifier and Type | Method and Description |
---|---|
int |
getEndIndex()
Returns the end index of this nodes text in the underlying input buffer, i.e.
|
java.lang.String |
getLabel()
Returns the label of this node which is equal to the name of the rule that created this node
|
Matcher |
getMatcher()
Returns the matcher that created this node.
|
int |
getStartIndex()
Returns the start index of this nodes text in the underlying input buffer.
|
V |
getValue()
Returns the value object attached to this node.
|
boolean |
hasError() |
java.lang.String |
toString() |
acquireChildren, getParent
getChildren
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getChildren
private final Matcher matcher
private final int startIndex
private final int endIndex
private final V value
private final boolean hasError
public NodeImpl(Matcher matcher, ImmutableLinkedList<Node<V>> children, int startIndex, int endIndex, V value, boolean hasError)
public Matcher getMatcher()
Node
getMatcher
in interface Node<V>
public java.lang.String getLabel()
Node
public int getStartIndex()
Node
getStartIndex
in interface Node<V>
public int getEndIndex()
Node
getEndIndex
in interface Node<V>
public V getValue()
Node
public boolean hasError()
public java.lang.String toString()
toString
in class java.lang.Object