com.metsci.glimpse.charts.vector.display
Class PolygonHandler<V extends GeoObject>

java.lang.Object
  extended by com.metsci.glimpse.charts.vector.display.PolygonHandler<V>
All Implemented Interfaces:
ContentHandler<V>

public class PolygonHandler<V extends GeoObject>
extends java.lang.Object
implements ContentHandler<V>

This content handler renders GeoObjects by drawing polygons. It delegates the painting of the geo objects to the com.metsci.glimpse.painter.shape.PolygonPainter. The drawing characteristics of the rendered polygons are determined by the feature type of the geoobject being rendered and the PolygonPainterSpec passed to this class in the constructor. The values in the PolygonPainterSpec are determined by the skin xml config file. In a nutshell, this class gets a GeoObject to render, looks up the drawing specs from the PolygonPainterSpec, configures the PolygonPainter to those specs, and invokes the PolygonPainter to render the geoobject.

Author:
Cunningham

Constructor Summary
PolygonHandler()
           
PolygonHandler(PolygonPainterSpec spec)
           
 
Method Summary
 java.lang.Integer getScaleMin(V object)
           
 void paintEnc(GeoContext encContext, V object)
           
 void reset()
           
 void setFill(boolean show)
           
 void setFillColor(float[] rgba)
           
 void setFillColor(float r, float g, float b, float a)
           
 void setLineColor(float[] rgba)
           
 void setLineColor(float r, float g, float b, float a)
           
 void setLineDotted(boolean dotted)
           
 void setLineDotted(int stippleFactor, short stipplePattern)
           
 void setLineWidth(int width)
           
 void setPolyDotted(boolean dotted)
           
 void setPolyDotted(byte[] stipple)
           
 void setShowLines(boolean show)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PolygonHandler

public PolygonHandler()

PolygonHandler

public PolygonHandler(PolygonPainterSpec spec)
Method Detail

paintEnc

public void paintEnc(GeoContext encContext,
                     V object)
Specified by:
paintEnc in interface ContentHandler<V extends GeoObject>

getScaleMin

public java.lang.Integer getScaleMin(V object)
Specified by:
getScaleMin in interface ContentHandler<V extends GeoObject>

reset

public void reset()
Specified by:
reset in interface ContentHandler<V extends GeoObject>

setShowLines

public void setShowLines(boolean show)

setLineColor

public void setLineColor(float r,
                         float g,
                         float b,
                         float a)

setLineColor

public void setLineColor(float[] rgba)

setLineWidth

public void setLineWidth(int width)

setPolyDotted

public void setPolyDotted(byte[] stipple)

setPolyDotted

public void setPolyDotted(boolean dotted)

setLineDotted

public void setLineDotted(boolean dotted)

setLineDotted

public void setLineDotted(int stippleFactor,
                          short stipplePattern)

setFill

public void setFill(boolean show)

setFillColor

public void setFillColor(float r,
                         float g,
                         float b,
                         float a)

setFillColor

public void setFillColor(float[] rgba)


Copyright © 2012 Metron, Inc.. All Rights Reserved.