public class AstTextVisitor extends AbstractAstVisitor
| Modifier and Type | Field and Description |
|---|---|
protected ResourceProvider |
bundle |
protected java.util.Locale |
locale |
protected int |
newLineIndex |
protected java.lang.StringBuilder |
sb |
| Constructor and Description |
|---|
AstTextVisitor(java.lang.StringBuilder sb,
ResourceProvider bundle,
java.util.Locale locale) |
| Modifier and Type | Method and Description |
|---|---|
void |
afterChildBinary(BinaryMetadata metadata,
Metadata child,
boolean hasNext,
int depth) |
void |
afterChildMappingRule(Metadata metadata,
Metadata child,
boolean hasNext,
int depth) |
void |
endMappingRule(Metadata metadata,
int depth) |
void |
endRule(Metadata metadata,
int depth) |
void |
endTypeConverter(LeafMetadata<?> metadata,
int depth) |
void |
endUnary(UnaryMetadata metadata,
int depth) |
protected java.lang.String |
formatLeafMetadata(LeafMetadata<?> metadata) |
protected java.lang.String |
formatNewLine() |
protected java.lang.String |
formatOperator(Operator operator) |
protected java.lang.String |
formatRule() |
protected java.lang.String |
formatSpace() |
protected java.lang.String |
formatValidate() |
protected java.lang.String |
formatWhen() |
protected int |
getCurrentIndentSize() |
protected int |
getIndentSize() |
protected int |
getNewLineIndex() |
void |
startIterable(IterableMetadata metadata,
int depth) |
void |
startLeaf(LeafMetadata<?> metadata,
int depth) |
void |
startMappingRule(Metadata metadata,
int depth) |
void |
startNary(NaryMetadata metadata,
int depth) |
void |
startRule(Metadata metadata,
int depth) |
void |
startTypeConverter(LeafMetadata<?> metadata,
int depth) |
void |
startWhen(Metadata metadata,
int depth) |
afterChild, afterChildDefault, afterChildIterable, afterChildNary, afterChildRule, afterChildTypeConverter, afterChildUnary, afterChildWhen, beforeChild, beforeChildBinary, beforeChildDefault, beforeChildIterable, beforeChildMappingRule, beforeChildNary, beforeChildRule, beforeChildTypeConverter, beforeChildUnary, beforeChildWhen, end, endBinary, endDefault, endIterable, endLeaf, endNary, endWhen, formatCurrentIndent, parent, stackPeek, stackPeekType, stackSteam, start, startBinary, startDefault, startUnary, visitCondition, visitIterable, visitNaryclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitbrowseprotected final java.lang.StringBuilder sb
protected final ResourceProvider bundle
protected final java.util.Locale locale
protected int newLineIndex
public AstTextVisitor(java.lang.StringBuilder sb,
ResourceProvider bundle,
java.util.Locale locale)
protected int getNewLineIndex()
protected java.lang.String formatNewLine()
formatNewLine in class AbstractAstVisitorprotected java.lang.String formatSpace()
public void startLeaf(LeafMetadata<?> metadata, int depth)
startLeaf in class AbstractAstVisitorpublic void endUnary(UnaryMetadata metadata, int depth)
endUnary in class AbstractAstVisitorpublic void afterChildBinary(BinaryMetadata metadata, Metadata child, boolean hasNext, int depth)
afterChildBinary in class AbstractAstVisitorpublic void startNary(NaryMetadata metadata, int depth)
startNary in class AbstractAstVisitorpublic void startIterable(IterableMetadata metadata, int depth)
startIterable in class AbstractAstVisitorpublic void startRule(Metadata metadata, int depth)
startRule in class AbstractAstVisitorpublic void endRule(Metadata metadata, int depth)
endRule in class AbstractAstVisitorpublic void startWhen(Metadata metadata, int depth)
startWhen in class AbstractAstVisitorpublic void startTypeConverter(LeafMetadata<?> metadata, int depth)
startTypeConverter in class AbstractAstVisitorpublic void endTypeConverter(LeafMetadata<?> metadata, int depth)
endTypeConverter in class AbstractAstVisitorpublic void startMappingRule(Metadata metadata, int depth)
startMappingRule in class AbstractAstVisitorpublic void afterChildMappingRule(Metadata metadata, Metadata child, boolean hasNext, int depth)
afterChildMappingRule in class AbstractAstVisitorpublic void endMappingRule(Metadata metadata, int depth)
endMappingRule in class AbstractAstVisitorprotected int getIndentSize()
getIndentSize in class AbstractAstVisitorprotected int getCurrentIndentSize()
getCurrentIndentSize in class AbstractAstVisitorprotected java.lang.String formatLeafMetadata(LeafMetadata<?> metadata)
protected java.lang.String formatOperator(Operator operator)
protected java.lang.String formatRule()
protected java.lang.String formatValidate()
protected java.lang.String formatWhen()