|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.parser4j.parser.entity.data.ParserData
public class ParserData
Constructor Summary | |
---|---|
ParserData(int numberOfState,
int numberOfNonterminal)
number of state and number of non terminal are knew at construction |
Method Summary | |
---|---|
void |
addGotoByNonTerminal(boolean token,
boolean stringToken,
int fromStateIdentifier,
int nonTerminalIdentifier,
ToStateAndWhiteSpaceFlag toStateAndWhiteSpaceFlag)
add a goto from state to state by non terminal |
void |
addGotoByTerminal(boolean token,
int fromStateIdentifier,
TerminalCharRange terminalCharRange,
int toStateIdentifier)
add a goto from state to state by terminal |
void |
addMatch(int fromStateIdentifier,
int nonTerminalIdentifier,
boolean intermediate,
int length,
int nodeType,
boolean token)
add non terminal match to a state for non token |
void |
addTokenMatch(int fromStateIdentifier,
int nonTerminalIdentifier,
boolean intermediate,
int length,
int nodeType,
boolean token)
add non terminal match to a state for token |
void |
fixState()
|
StateRecognitionPointList[] |
getByStateRecognitionPointList()
|
int[][] |
getExpectedStringToken()
|
GotoByNonTerminalEntry[] |
getGotoByNonTerminalTable()
|
GotoByTerminalEntry[] |
getGotoByTerminalTable()
|
GotoByTerminalEntry[] |
getLexerGotoByTerminalTable()
|
int[][] |
getLexerMatchedNonTerminalIdentifier()
|
java.lang.String[] |
getMatchClassNameTable()
|
MatchEntrySet[] |
getMatchTable()
|
java.util.Map<java.lang.Integer,NonTerminal> |
getNonTerminalByIdentifierMap()
|
int |
getNumberOfNonterminal()
|
int |
getNumberOfState()
|
java.util.List<ParserDataRecognitionPoint> |
getRecognitionPoint(int stateIdentifier)
|
int |
getRootNonTerminalIdentifier()
|
boolean[] |
getStringTokenRecognition()
|
GotoByNonTerminalEntry[] |
getTokenGotoByNonTerminalTable()
|
GotoByTerminalEntry[] |
getTokenGotoByTerminalTable()
|
MatchEntrySet[] |
getTokenMatchTable()
|
boolean[] |
getTokenRecognition()
|
boolean |
isUseMatchClass()
|
boolean |
match(int stateIdentifier)
|
void |
setLexerData(LexerData lexerData)
|
void |
setNonTerminalByIdentifierMap(java.util.Map<java.lang.Integer,NonTerminal> nonTerminalByIdentifierMap)
set the non terminal name by non terminal identifier |
void |
setNonTerminalMatchClassName(int nonTerminalIdentifier,
java.lang.String matchClassName)
|
void |
setRecognitionPoint(int stateIdentifier,
java.util.List<ParserDataRecognitionPoint> list)
|
void |
setRootNonTerminalIdentifier(int rootNonTerminalIdentifier)
|
void |
setStringTokenRecognition(int stateIdentifier)
|
void |
setTokenRecognition(int stateIdentifier)
|
void |
setUseMatchClass(boolean useMatchClass)
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ParserData(int numberOfState, int numberOfNonterminal)
numberOfState
- Method Detail |
---|
public void fixState()
public int getNumberOfNonterminal()
public int getNumberOfState()
public void addGotoByTerminal(boolean token, int fromStateIdentifier, TerminalCharRange terminalCharRange, int toStateIdentifier)
token
- fromStateIdentifier
- terminalCharRange
- toStateIdentifier
- public void addGotoByNonTerminal(boolean token, boolean stringToken, int fromStateIdentifier, int nonTerminalIdentifier, ToStateAndWhiteSpaceFlag toStateAndWhiteSpaceFlag)
token
- stringToken
- fromStateIdentifier
- nonTerminalIdentifier
- toStateAndWhiteSpaceFlag
- public void addMatch(int fromStateIdentifier, int nonTerminalIdentifier, boolean intermediate, int length, int nodeType, boolean token)
fromStateIdentifier
- nonTerminalIdentifier
- length
- nodeType
- token
- public void addTokenMatch(int fromStateIdentifier, int nonTerminalIdentifier, boolean intermediate, int length, int nodeType, boolean token)
fromStateIdentifier
- nonTerminalIdentifier
- intermediate
- length
- nodeType
- token
- public void setTokenRecognition(int stateIdentifier)
stateIdentifier
- public boolean[] getTokenRecognition()
public void setStringTokenRecognition(int stateIdentifier)
stateIdentifier
- public boolean[] getStringTokenRecognition()
public void setLexerData(LexerData lexerData)
public void setUseMatchClass(boolean useMatchClass)
public boolean isUseMatchClass()
public void setNonTerminalMatchClassName(int nonTerminalIdentifier, java.lang.String matchClassName)
nonTerminalIdentifier
- matchClassName
- can be nullpublic boolean match(int stateIdentifier)
public GotoByTerminalEntry[] getGotoByTerminalTable()
public GotoByTerminalEntry[] getTokenGotoByTerminalTable()
public GotoByNonTerminalEntry[] getGotoByNonTerminalTable()
public GotoByNonTerminalEntry[] getTokenGotoByNonTerminalTable()
public int[][] getExpectedStringToken()
public int[][] getLexerMatchedNonTerminalIdentifier()
public GotoByTerminalEntry[] getLexerGotoByTerminalTable()
public java.lang.String[] getMatchClassNameTable()
public MatchEntrySet[] getMatchTable()
public MatchEntrySet[] getTokenMatchTable()
public int getRootNonTerminalIdentifier()
public void setRootNonTerminalIdentifier(int rootNonTerminalIdentifier)
public void setNonTerminalByIdentifierMap(java.util.Map<java.lang.Integer,NonTerminal> nonTerminalByIdentifierMap)
nonTerminalByIdentifierMap
- public java.util.Map<java.lang.Integer,NonTerminal> getNonTerminalByIdentifierMap()
public void setRecognitionPoint(int stateIdentifier, java.util.List<ParserDataRecognitionPoint> list)
public java.util.List<ParserDataRecognitionPoint> getRecognitionPoint(int stateIdentifier)
public StateRecognitionPointList[] getByStateRecognitionPointList()
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |