Package org.geotools.swing
Class RenderingTask
- Object
-
- RenderingTask
-
- All Implemented Interfaces:
Callable<Boolean>
,RenderListener
public class RenderingTask extends Object implements Callable<Boolean>, RenderListener
A rendering task to be run by aRenderingExecutor
.- Since:
- 8.0
- Author:
- Michael Bedward
-
-
Constructor Summary
Constructors Constructor Description RenderingTask(MapContent mapContent, Graphics2D destinationGraphics, GTRenderer renderer)
Creates a new rendering task.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Boolean
call()
Called by the executor to run this rendering task.void
cancel()
void
errorOccurred(Exception e)
Called by the renderer on errorvoid
featureRenderer(SimpleFeature feature)
Called by the renderer when each feature is drawn.boolean
isCancelled()
boolean
isFailed()
boolean
isRunning()
-
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface RenderListener
labellingEnd, labellingStart, layerEnd, layerStart, renderingComplete
-
-
-
-
Constructor Detail
-
RenderingTask
public RenderingTask(MapContent mapContent, Graphics2D destinationGraphics, GTRenderer renderer)
Creates a new rendering task.
-
-
Method Detail
-
cancel
public void cancel()
-
featureRenderer
public void featureRenderer(SimpleFeature feature)
Called by the renderer when each feature is drawn. This implementation does nothing.- Specified by:
featureRenderer
in interfaceRenderListener
- Parameters:
feature
- the feature just drawn
-
errorOccurred
public void errorOccurred(Exception e)
Called by the renderer on error- Specified by:
errorOccurred
in interfaceRenderListener
- Parameters:
e
- cause of the error
-
isRunning
public boolean isRunning()
-
isFailed
public boolean isFailed()
-
isCancelled
public boolean isCancelled()
-
-