T - The type of the painted objectspublic final class MultiObjectPainter<T> extends java.lang.Object implements ObjectPainter<java.lang.Iterable<? extends T>>
ObjectPainter that paints multiple objects
using a delegate| Constructor and Description |
|---|
MultiObjectPainter(ObjectPainter<T> delegate)
Create a new painter that paints objects using the given delegate
|
| Modifier and Type | Method and Description |
|---|---|
void |
paint(java.awt.Graphics2D g,
java.awt.geom.AffineTransform worldToScreen,
double w,
double h,
java.lang.Iterable<? extends T> objects)
Perform the painting operations for the given object on the given
Graphics.
|
public MultiObjectPainter(ObjectPainter<T> delegate)
delegate - The delegate painterpublic void paint(java.awt.Graphics2D g,
java.awt.geom.AffineTransform worldToScreen,
double w,
double h,
java.lang.Iterable<? extends T> objects)
ObjectPainterPainter.paint(Graphics2D, AffineTransform, double, double)
for more information about how the Graphics object is handled among
painters.paint in interface ObjectPainter<java.lang.Iterable<? extends T>>g - The Graphics used for paintingworldToScreen - The world-to-screen transform. This transform
encapsulates the translation, rotation and scaling of the viewer
to which this painter belongs.w - The width of the area, in screen coordinates, in which
this painter operates. This is the screen size of the viewer to
which this painter belongs.h - The height of the area, in screen coordinates, in which
this painter operates. This is the screen size of the viewer to
which this painter belongs.objects - The object to paint. One has to assume that
this object may be null, in which case the
painting operation will usually be skipped.Copyright © 2019. All Rights Reserved.