@FunctionalInterface public interface MapViewPaintable
You might want to extend AbstractMapViewPaintable
to ease implementation of this.
That class allows you to listen to paintable change events. Those methods may be moved here some time in the future.
Modifier and Type | Interface and Description |
---|---|
static interface |
MapViewPaintable.LayerPainter
Gets a new LayerPainter that paints this
MapViewPaintable to the given map view. |
static class |
MapViewPaintable.MapViewEvent
A event that is fired whenever the map view is attached or detached from any layer.
|
static class |
MapViewPaintable.PaintableInvalidationEvent
This event is fired whenever the paintable got invalidated and needs repainting some time in the future.
|
static interface |
MapViewPaintable.PaintableInvalidationListener
This is a listener that listens to
MapViewPaintable.PaintableInvalidationEvent s |
Modifier and Type | Method and Description |
---|---|
default void |
addInvalidationListener(MapViewPaintable.PaintableInvalidationListener l)
Adds a new paintable invalidation listener.
|
void |
paint(java.awt.Graphics2D g,
MapView mv,
Bounds bbox)
Paint the dataset using the engine set.
|
default void |
removeInvalidationListener(MapViewPaintable.PaintableInvalidationListener l)
Removes an added paintable invalidation listener.
|
void paint(java.awt.Graphics2D g, MapView mv, Bounds bbox)
g
- Graphicsmv
- The object that can translate GeoPoints to screen coordinates.bbox
- Bounding boxdefault void addInvalidationListener(MapViewPaintable.PaintableInvalidationListener l)
l
- The listener to add.default void removeInvalidationListener(MapViewPaintable.PaintableInvalidationListener l)
l
- The listener to remove.