Package jflex.core
Class EOFActions
- java.lang.Object
-
- jflex.core.EOFActions
-
public class EOFActions extends java.lang.Object
A simple table to store EOF actions for each lexical state.- Version:
- JFlex 1.9.1
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.Map<java.lang.Integer,Action>
actions
maps lexical states to actionsprivate Action
defaultAction
private int
numLexStates
-
Constructor Summary
Constructors Constructor Description EOFActions()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(java.lang.Integer state, Action action)
Add.void
add(java.util.List<java.lang.Integer> stateList, Action action)
Add.Action
getAction(int state)
getAction.Action
getDefault()
Returns the default action.boolean
isEOFAction(java.lang.Object a)
int
numActions()
Returns thenumber ofAction
s.void
setNumLexStates(int num)
Sets the number of lexical states.
-
-
-
Method Detail
-
setNumLexStates
public void setNumLexStates(int num)
Sets the number of lexical states.- Parameters:
num
- number of states.
-
add
public void add(java.util.List<java.lang.Integer> stateList, Action action)
Add.- Parameters:
stateList
- aList
object.action
- aAction
object.
-
add
public void add(java.lang.Integer state, Action action)
Add.- Parameters:
state
- aInteger
object.action
- aAction
object.
-
isEOFAction
public boolean isEOFAction(java.lang.Object a)
-
getAction
public Action getAction(int state)
getAction.- Parameters:
state
- a int.- Returns:
- a
Action
object.
-
numActions
public int numActions()
Returns thenumber ofAction
s.- Returns:
- number of actions.
-
-