public class ForestNode
extends java.lang.Object
When walking the graph, for example to extract parses, these nodes represent what's available in the graph.
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
AMBIGUOUS_ATTRIBUTE |
int |
id
This node's unique identifier.
|
int |
leftExtent
The first position in the input covered by this node.
|
static java.lang.String |
logcategory |
static java.lang.String |
PRIORITY_ATTRIBUTE
The internal name of the attribute that holds priority.
|
int |
rightExtent
The last position in the input covered by this node.
|
State |
state |
Symbol |
symbol |
Modifier and Type | Method and Description |
---|---|
void |
addFamily(ForestNode w,
ForestNode v,
State state) |
void |
addFamily(ForestNode v,
State state) |
boolean |
equals(java.lang.Object obj) |
java.util.List<Family> |
getFamilies() |
int |
getPriority() |
State |
getState()
What state does this node represent?
|
Symbol |
getSymbol()
What symbol does this node represent?
|
int |
hashCode() |
java.lang.String |
toString() |
public static final java.lang.String logcategory
public static final java.lang.String PRIORITY_ATTRIBUTE
public static final java.lang.String AMBIGUOUS_ATTRIBUTE
public final Symbol symbol
public final State state
public final int rightExtent
public final int leftExtent
public final int id
public Symbol getSymbol()
There are nodes for terminal and nonterminal symbols as well as intermediate nodes representing partial parses of a rule.
public State getState()
There are nodes for terminal and nonterminal symbols as well as intermediate nodes representing partial parses of a rule. In order to expose as much information as possible, the states associated with nonterminal symbols are included in the graph.
public java.util.List<Family> getFamilies()
public void addFamily(ForestNode v, State state)
public void addFamily(ForestNode w, ForestNode v, State state)
public int getPriority()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object