public class PointFeatureOverlay<T extends PointFeatureSymbol> extends PolygonOverlay
PointFeatureOverlay
class annotes a data view with
symbols using data from a PointFeatureSource
.drawingShadow
alpha, lastTrans, prepared
Constructor and Description |
---|
PointFeatureOverlay(int layer,
java.awt.Stroke stroke,
PointFeatureSource source,
T symbol)
Constructs a new overlay.
|
PointFeatureOverlay(T symbol,
PointFeatureSource source)
Constructs a new overlay.
|
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
clone() |
protected void |
draw(java.awt.Graphics2D g,
EarthDataView view)
Draws the overlay graphics.
|
SelectionRuleFilter |
getFilter()
Gets the feature filter being used in this overlay.
|
java.util.List<Feature> |
getMatchingFeatures(EarthArea area)
Gets the matching point features in this overlay for the specified area.
|
java.util.Map<java.lang.String,java.lang.Object> |
getMetadataAtPoint(java.awt.Point point)
Gets the metadata at the specified point.
|
PointFeatureSource |
getSource()
Gets the feature source for this overlay.
|
T |
getSymbol()
Gets the point symbol.
|
boolean |
hasMetadata()
Gets the metadata flag, true if the overlay has metadata associated
with its rendered graphics, false if not.
|
protected void |
prepare(java.awt.Graphics2D g,
EarthDataView view)
Prepares the overlay graphics prior to drawing.
|
void |
setFilter(SelectionRuleFilter filter)
Sets the feature filter to use in this overlay.
|
void |
setSymbol(T symbol)
Sets the point symbol.
|
java.lang.String |
toString() |
getColors, getFillColor, getFillColorWithAlpha, setFillColor
clip, drawShadow, getDropShadow, getShadowColor, getStroke, render, setDropShadow, setStroke
compareTo, getAlphaVersion, getColor, getColorWithAlpha, getLayer, getName, getTransparency, getVisible, invalidate, isPrepared, needsPrepare, setColor, setLayer, setName, setTransparency, setVisible
public PointFeatureOverlay(int layer, java.awt.Stroke stroke, PointFeatureSource source, T symbol)
layer
- the overlay layer number.stroke
- the stroke to use for vector paths.source
- the source for polygon data.symbol
- the symbol to use for each point feature.public PointFeatureOverlay(T symbol, PointFeatureSource source)
BasicStroke
. The
overlay drawing and fill color are determined from the symbol.source
- the source for polygon data.symbol
- the symbol to use for each point feature.public java.lang.Object clone()
clone
in class EarthDataOverlay
public SelectionRuleFilter getFilter()
public void setFilter(SelectionRuleFilter filter)
filter
- the feature filter or null for no filtering.public T getSymbol()
public void setSymbol(T symbol)
public PointFeatureSource getSource()
public java.util.List<Feature> getMatchingFeatures(EarthArea area)
area
- the earth area to use for features.protected void prepare(java.awt.Graphics2D g, EarthDataView view)
EarthDataOverlay
prepare
in class EarthDataOverlay
g
- the graphics object for drawing.view
- the earth data view.protected void draw(java.awt.Graphics2D g, EarthDataView view)
EarthDataOverlay
draw
in class EarthDataOverlay
g
- the graphics object for drawing.view
- the earth data view.public boolean hasMetadata()
EarthDataOverlay
EarthDataOverlay.getMetadataAtPoint(java.awt.Point)
may be used. By default this method returns
false unless overridden by the child class.hasMetadata
in class EarthDataOverlay
EarthDataOverlay.getMetadataAtPoint(java.awt.Point)
public java.util.Map<java.lang.String,java.lang.Object> getMetadataAtPoint(java.awt.Point point)
EarthDataOverlay
getMetadataAtPoint
in class EarthDataOverlay
point
- the point to get metadata for.public java.lang.String toString()
toString
in class java.lang.Object