Package net.sf.jasperreports.engine.util
Class UniformPrintElementVisitor<T>
- java.lang.Object
-
- net.sf.jasperreports.engine.util.UniformPrintElementVisitor<T>
-
- All Implemented Interfaces:
PrintElementVisitor<T>
- Direct Known Subclasses:
DeepPrintElementCounter
,PartPropertiesDetector
public abstract class UniformPrintElementVisitor<T> extends Object implements PrintElementVisitor<T>
Print element visitor that delegates all visit calls to a single method.- Author:
- Lucian Chirita (lucianc@users.sourceforge.net)
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
UniformPrintElementVisitor()
Creates a uniform visitor.protected
UniformPrintElementVisitor(boolean deep)
Creates an optionally deep uniform visitor.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
visit(JRGenericPrintElement printElement, T arg)
Visits a generic print element.void
visit(JRPrintEllipse ellipse, T arg)
Visits a print ellipse.void
visit(JRPrintFrame frame, T arg)
Visits a print frame.void
visit(JRPrintImage image, T arg)
Visits a print image.void
visit(JRPrintLine line, T arg)
Visits a print line.void
visit(JRPrintRectangle rectangle, T arg)
Visits a print rectangle.void
visit(JRPrintText textElement, T arg)
Visits a text print element.protected abstract void
visitElement(JRPrintElement element, T arg)
protected void
visitFrameElements(List<JRPrintElement> elements, T arg)
-
-
-
Constructor Detail
-
UniformPrintElementVisitor
protected UniformPrintElementVisitor()
Creates a uniform visitor.
-
UniformPrintElementVisitor
protected UniformPrintElementVisitor(boolean deep)
Creates an optionally deep uniform visitor.- Parameters:
deep
- whether elements are to be deeply visited- See Also:
DeepPrintElementVisitor
-
-
Method Detail
-
visitElement
protected abstract void visitElement(JRPrintElement element, T arg)
-
visit
public void visit(JRPrintText textElement, T arg)
Description copied from interface:PrintElementVisitor
Visits a text print element.- Specified by:
visit
in interfacePrintElementVisitor<T>
- Parameters:
textElement
- the element to visitarg
- an argument passed for the visit
-
visit
public void visit(JRPrintImage image, T arg)
Description copied from interface:PrintElementVisitor
Visits a print image.- Specified by:
visit
in interfacePrintElementVisitor<T>
- Parameters:
image
- the image to visitarg
- an argument passed for the visit
-
visit
public void visit(JRPrintRectangle rectangle, T arg)
Description copied from interface:PrintElementVisitor
Visits a print rectangle.- Specified by:
visit
in interfacePrintElementVisitor<T>
- Parameters:
rectangle
- the rectangle to visitarg
- an argument passed for the visit
-
visit
public void visit(JRPrintLine line, T arg)
Description copied from interface:PrintElementVisitor
Visits a print line.- Specified by:
visit
in interfacePrintElementVisitor<T>
- Parameters:
line
- the line to visitarg
- an argument passed for the visit
-
visit
public void visit(JRPrintEllipse ellipse, T arg)
Description copied from interface:PrintElementVisitor
Visits a print ellipse.- Specified by:
visit
in interfacePrintElementVisitor<T>
- Parameters:
ellipse
- the ellipse to visitarg
- an argument passed for the visit
-
visit
public void visit(JRPrintFrame frame, T arg)
Description copied from interface:PrintElementVisitor
Visits a print frame.- Specified by:
visit
in interfacePrintElementVisitor<T>
- Parameters:
frame
- the frame to visitarg
- an argument passed for the visit
-
visitFrameElements
protected void visitFrameElements(List<JRPrintElement> elements, T arg)
-
visit
public void visit(JRGenericPrintElement printElement, T arg)
Description copied from interface:PrintElementVisitor
Visits a generic print element.- Specified by:
visit
in interfacePrintElementVisitor<T>
- Parameters:
printElement
- the element to visitarg
- an argument passed for the visit
-
-