|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.parser4j.parser.service.ParsingToStringUtil
public final class ParsingToStringUtil
parse node, parse tree, to string utilities
Constructor Summary | |
---|---|
ParsingToStringUtil(java.util.Map<java.lang.Integer,NonTerminal> nonTerminalByIdentifierMap)
|
Method Summary | |
---|---|
void |
beginAlternativeVisit(IParseNode node,
int alternativeNumber)
|
void |
beginAlternativeVisit(SyntaxNode syntaxNode,
int alternativeNumber)
|
boolean |
beginVisit(IParseNode parseNode)
begin node visit |
boolean |
beginVisit(SyntaxNode syntaxNode)
|
void |
endAlternativeVisit(IParseNode node,
int alternativeNumber)
|
void |
endAlternativeVisit(SyntaxNode syntaxNode,
int alternativeNumber)
|
void |
endVisit(IParseNode parseNode)
end node visit, not invoke if IParseNodeVisitor.beginVisit(IParseNode) returned
false |
void |
endVisit(SyntaxNode syntaxNode)
|
java.lang.String |
grammarSymbolIdentifierToString(int grammarSymbolIdentifier)
grammar symbol identifier to string |
java.lang.String |
parseNodesToString(IParseNode[] parseNodes,
boolean addParseTree)
parse nodes to string |
java.lang.String |
parseNodeToString(IParseNode parseNode)
parse node to string |
java.lang.String |
parseStacksToString(ParseStack[] parseStacks,
boolean[] tokenRecognition,
boolean[] stringTokenRecognition,
boolean addParseTree)
|
java.lang.String |
parseStackToString(ParseStack parseStack,
boolean[] tokenRecognition,
boolean[] stringTokenRecognition,
boolean addParseTree)
parse stack to string |
java.lang.String |
parseStateToString(IParseState parseState,
boolean[] tokenRecognition,
boolean[] stringTokenRecognition,
boolean addParseTree)
parse state to string |
java.lang.String |
parseTreeToString(IParseNode rootParseNode,
boolean visitAgainEnabled)
parse tree to string |
java.lang.String |
syntaxTreeToString(SyntaxNode rootSyntaxNode,
boolean visitAgainEnabled)
syntax tree to string |
java.lang.String |
terminalIdentifierToString(int terminalIdentifier)
terminal identifier to string : the character for ascii, or the utf code point \\uXXXX |
boolean |
visitFirstAlternativeOnly()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ParsingToStringUtil(java.util.Map<java.lang.Integer,NonTerminal> nonTerminalByIdentifierMap)
Method Detail |
---|
public java.lang.String parseStateToString(IParseState parseState, boolean[] tokenRecognition, boolean[] stringTokenRecognition, boolean addParseTree)
parseState
- tokenRecognition
- addParseTree
- true if add parse tree for each node of parse nodes array
public java.lang.String parseStacksToString(ParseStack[] parseStacks, boolean[] tokenRecognition, boolean[] stringTokenRecognition, boolean addParseTree)
public java.lang.String parseStackToString(ParseStack parseStack, boolean[] tokenRecognition, boolean[] stringTokenRecognition, boolean addParseTree)
parseStack
- tokenRecognition
- stringTokenRecognition
- addParseTree
- true if add parse tree for each node of parse nodes array
public java.lang.String parseNodesToString(IParseNode[] parseNodes, boolean addParseTree)
parseNodes
- addParseTree
- true if add parse tree for each node of parse nodes array
public java.lang.String parseNodeToString(IParseNode parseNode)
parseNode
-
public java.lang.String parseTreeToString(IParseNode rootParseNode, boolean visitAgainEnabled)
rootParseNode
-
public boolean beginVisit(IParseNode parseNode)
IParseNodeVisitor
beginVisit
in interface IParseNodeVisitor
public boolean visitFirstAlternativeOnly()
visitFirstAlternativeOnly
in interface IParseNodeVisitor
visitFirstAlternativeOnly
in interface ISyntaxNodeVisitor
public void beginAlternativeVisit(IParseNode node, int alternativeNumber)
beginAlternativeVisit
in interface IParseNodeVisitor
public void endAlternativeVisit(IParseNode node, int alternativeNumber)
endAlternativeVisit
in interface IParseNodeVisitor
public void endVisit(IParseNode parseNode)
IParseNodeVisitor
IParseNodeVisitor.beginVisit(IParseNode)
returned
false
endVisit
in interface IParseNodeVisitor
public java.lang.String grammarSymbolIdentifierToString(int grammarSymbolIdentifier)
grammarSymbolIdentifier
-
public java.lang.String terminalIdentifierToString(int terminalIdentifier)
terminalIdentifier
-
public java.lang.String syntaxTreeToString(SyntaxNode rootSyntaxNode, boolean visitAgainEnabled)
rootParseNode
-
public boolean beginVisit(SyntaxNode syntaxNode)
beginVisit
in interface ISyntaxNodeVisitor
public void beginAlternativeVisit(SyntaxNode syntaxNode, int alternativeNumber)
beginAlternativeVisit
in interface ISyntaxNodeVisitor
public void endAlternativeVisit(SyntaxNode syntaxNode, int alternativeNumber)
endAlternativeVisit
in interface ISyntaxNodeVisitor
public void endVisit(SyntaxNode syntaxNode)
endVisit
in interface ISyntaxNodeVisitor
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |