DFA

A set of DFA states

Constructors

this
this(DecisionState atnStartState)
Undocumented in source.
this
this(DecisionState atnStartState, int decision)
Undocumented in source.

Members

Functions

getPrecedenceStartState
DFAState getPrecedenceStartState(int precedence)

Get the start state for a specific precedence value.

getStates
DFAState[] getStates()
Undocumented in source. Be warned that the author may not have intended to support it.
isPrecedenceDfa
bool isPrecedenceDfa()

Gets whether this DFA is a precedence DFA. Precedence DFAs use a special start state {@link #s0} which is not stored in {@link #states}. The {@link DFAState#edges} array for this start state contains outgoing edges supplying individual start states corresponding to specific precedence values.

setPrecedenceDfa
void setPrecedenceDfa(bool precedenceDfa)

Sets whether this is a precedence DFA.

setPrecedenceStartState
void setPrecedenceStartState(int precedence, DFAState startState)

Set the start state for a specific precedence value.

toLexerString
string toLexerString()
Undocumented in source. Be warned that the author may not have intended to support it.
toString
string toString(string[] tokenNames)
Undocumented in source. Be warned that the author may not have intended to support it.
toString
string toString()

@uml @override

toString
string toString(Vocabulary vocabulary)
Undocumented in source. Be warned that the author may not have intended to support it.

Variables

atnStartState
DecisionState atnStartState;

From which ATN state did we create this DFA?

decision
int decision;
Undocumented in source.
precedenceDfa
bool precedenceDfa;

{@code true} if this DFA is for a precedence decision; otherwise, {@code false}. This is the backing field for {@link #isPrecedenceDfa}.

s0
DFAState s0;
Undocumented in source.
states
DFAState[DFAState] states;

A set of all DFA states. Use {@link Map} so we can get old state back ({@link Set} only allows you to see if it's there).

Meta