Package jflex.core

Class EOFActions

java.lang.Object
jflex.core.EOFActions

public class EOFActions extends Object
A simple table to store EOF actions for each lexical state.
Version:
JFlex 1.8.2
  • Field Details

    • actions

      private final Map<Integer,Action> actions
      maps lexical states to actions
    • defaultAction

      private Action defaultAction
    • numLexStates

      private int numLexStates
  • Constructor Details

    • EOFActions

      public EOFActions()
  • Method Details

    • setNumLexStates

      public void setNumLexStates(int num)
      Sets the number of lexical states.
      Parameters:
      num - number of states.
    • add

      public void add(List<Integer> stateList, Action action)
      Add.
      Parameters:
      stateList - a List object.
      action - a Action object.
    • add

      public void add(Integer state, Action action)
      Add.
      Parameters:
      state - a Integer object.
      action - a Action object.
    • isEOFAction

      public boolean isEOFAction(Object a)
    • getAction

      public Action getAction(int state)
      getAction.
      Parameters:
      state - a int.
      Returns:
      a Action object.
    • getDefault

      public Action getDefault()
      Returns the default action.
      Returns:
      a default Action.
    • numActions

      public int numActions()
      Returns thenumber of Actions.
      Returns:
      number of actions.