JFlex

Class LexicalStates


public class LexicalStates
extends java.lang.Object

Simple symbol table, mapping lexical state names to integers.

Constructor Summary

LexicalStates()
constructs a new lexical state symbol table

Method Summary

Enumeration
getInclusiveStates()
returns the code of all inclusive states
Integer
getNumber(String name)
returns the number (code) of a declared state, null if no such state has been declared.
void
insert(String name, boolean is_inclusive)
insert a new state declaration
Enumeration
names()
returns the names of all states
int
number()
returns the number of declared states

Constructor Details

LexicalStates

public LexicalStates()
constructs a new lexical state symbol table

Method Details

getInclusiveStates

public Enumeration getInclusiveStates()
returns the code of all inclusive states

getNumber

public Integer getNumber(String name)
returns the number (code) of a declared state, null if no such state has been declared.

insert

public void insert(String name,
                   boolean is_inclusive)
insert a new state declaration

names

public Enumeration names()
returns the names of all states

number

public int number()
returns the number of declared states