static class TextOptimizer.TextCatVisitor extends Node.Visitor
| Modifier and Type | Field and Description |
|---|---|
private java.lang.String |
emptyText |
private Node.TemplateText |
firstTextNode |
private boolean |
prePass |
private java.lang.StringBuilder |
textBuffer |
private int |
textNodeCount |
private boolean |
trim |
| Constructor and Description |
|---|
TextCatVisitor(boolean prePass,
boolean trim) |
| Modifier and Type | Method and Description |
|---|---|
private void |
collectText()
This method breaks concatenation mode.
|
void |
doVisit(Node n)
This method provides a place to put actions that are common to
all nodes.
|
void |
visit(Node.AttributeDirective n) |
void |
visit(Node.PageDirective n) |
void |
visit(Node.TagDirective n) |
void |
visit(Node.TaglibDirective n) |
void |
visit(Node.TemplateText n) |
void |
visit(Node.VariableDirective n) |
void |
visitBody(Node n)
Visit the body of a node, using the current visitor
|
private int textNodeCount
private Node.TemplateText firstTextNode
private java.lang.StringBuilder textBuffer
private final java.lang.String emptyText
private boolean prePass
private boolean trim
public void doVisit(Node n) throws JasperException
Node.VisitordoVisit in class Node.VisitorJasperExceptionpublic void visit(Node.PageDirective n) throws JasperException
visit in class Node.VisitorJasperExceptionpublic void visit(Node.TagDirective n) throws JasperException
visit in class Node.VisitorJasperExceptionpublic void visit(Node.TaglibDirective n) throws JasperException
visit in class Node.VisitorJasperExceptionpublic void visit(Node.AttributeDirective n) throws JasperException
visit in class Node.VisitorJasperExceptionpublic void visit(Node.VariableDirective n) throws JasperException
visit in class Node.VisitorJasperExceptionpublic void visitBody(Node n) throws JasperException
Node.VisitorvisitBody in class Node.VisitorJasperExceptionpublic void visit(Node.TemplateText n) throws JasperException
visit in class Node.VisitorJasperExceptionprivate void collectText()