Interface IVectorLegend
- All Superinterfaces:
Cloneable,org.gvsig.tools.lang.Cloneable,DrawingObservable,ILegend,Legend,org.gvsig.tools.persistence.Persistent
- All Known Subinterfaces:
IClassifiedVectorLegend,ISingleSymbolLegend,IVectorialIntervalLegend,IVectorialUniqueValueLegend
Interface of a vectorial legend.
-
Method Summary
Modifier and TypeMethodDescriptionvoiddraw(BufferedImage image, Graphics2D graphics2D, ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore) Draws theFeatureStoredata using this legend simbology.voiddraw(BufferedImage image, Graphics2D graphics2D, ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.fmap.dal.feature.FeatureQuery featureQuery) Draws theFeatureStoredata using this legend simbology.Obtains the default symbol of the legend.intReturns the type of the shape.getSymbolByFeature(org.gvsig.fmap.dal.feature.Feature feat) Returns a symbol starting from an IFeature.booleanisSuitableForShapeType(int shapeType) booleanReturns true or false depending on if the rest of values are used.voidprint(Graphics2D g, ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.compat.print.PrintAttributes properties) voidprint(Graphics2D g, ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.fmap.dal.feature.FeatureQuery featureQuery, org.gvsig.compat.print.PrintAttributes properties) voidEstablishes the default symbol of a legend.voidsetShapeType(int shapeType) Defines the type of the shape.voiduseDefaultSymbol(boolean b) Methods inherited from interface org.gvsig.tools.lang.Cloneable
cloneMethods inherited from interface org.gvsig.fmap.mapcontext.rendering.legend.DrawingObservable
addDrawingObserver, deleteDrawingObserver, deleteDrawingObserversMethods inherited from interface org.gvsig.fmap.mapcontext.rendering.legend.ILegend
addLegendListener, cloneLegend, fireDefaultSymbolChangedEvent, getListeners, removeLegendListenerMethods inherited from interface org.gvsig.tools.persistence.Persistent
loadFromState, saveToState
-
Method Details
-
getDefaultSymbol
ISymbol getDefaultSymbol()Obtains the default symbol of the legend.- Specified by:
getDefaultSymbolin interfaceILegend- Returns:
- default symbol.
-
getSymbolByFeature
Returns a symbol starting from an IFeature.- Parameters:
feat- IFeature.- Returns:
- SÃmbolo.
- Throws:
MapContextException
-
getShapeType
int getShapeType()Returns the type of the shape.- Returns:
- Returns the type of the shapes that the legend is ready to use.
-
setShapeType
void setShapeType(int shapeType) Defines the type of the shape.- Parameters:
shapeType- type of the shape.
-
setDefaultSymbol
Establishes the default symbol of a legend. In a SingleSymbolLegend the symbol is established by calling this method.- Parameters:
s- default symbol.
-
isUseDefaultSymbol
boolean isUseDefaultSymbol()Returns true or false depending on if the rest of values are used.- Returns:
- True if the rest of values are used.
-
useDefaultSymbol
void useDefaultSymbol(boolean b) -
isSuitableForShapeType
boolean isSuitableForShapeType(int shapeType) -
draw
void draw(BufferedImage image, Graphics2D graphics2D, ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore) throws LegendException Draws theFeatureStoredata using this legend simbology.- Parameters:
image- the base image to draw overgraphics2D- theGraphics2Dto draw toviewPort- the ViewPort to usecancel- theCancellabledelegate objectscale- the scale of the viewqueryParameters- the query parameterscoordTrans- the transformation coordinates to use for reprojectionfeatureStore-FeatureStoreto load the data to draw from- Throws:
LegendException
-
draw
void draw(BufferedImage image, Graphics2D graphics2D, ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.fmap.dal.feature.FeatureQuery featureQuery) throws LegendException Draws theFeatureStoredata using this legend simbology.- Parameters:
image- the base image to draw overgraphics2D- theGraphics2Dto draw toviewPort- the ViewPort to usecancel- theCancellabledelegate objectscale- the scale of the viewqueryParameters- the query parameterscoordTrans- the transformation coordinates to use for reprojectionfeatureStore-FeatureStoreto load the data to draw fromfeatureQuery- the query used to filter the features.- Throws:
LegendException
-
print
void print(Graphics2D g, ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.compat.print.PrintAttributes properties) throws LegendException - Throws:
LegendException
-
print
void print(Graphics2D g, ViewPort viewPort, org.gvsig.tools.task.Cancellable cancel, double scale, Map queryParameters, org.gvsig.crs.projection.lib.CoordinateTransformation coordTrans, org.gvsig.fmap.dal.feature.FeatureStore featureStore, org.gvsig.fmap.dal.feature.FeatureQuery featureQuery, org.gvsig.compat.print.PrintAttributes properties) throws LegendException - Throws:
LegendException
-