Class ProportionalSymbolsLegend
java.lang.Object
org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractLegend
org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractClassifiedVectorLegend
org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialUniqueValueLegend
org.gvsig.symbology.fmap.rendering.ProportionalSymbolsLegend
- All Implemented Interfaces:
Cloneable,org.gvsig.fmap.mapcontext.rendering.legend.DrawingObservable,org.gvsig.fmap.mapcontext.rendering.legend.IClassifiedLegend,org.gvsig.fmap.mapcontext.rendering.legend.IClassifiedVectorLegend,org.gvsig.fmap.mapcontext.rendering.legend.ILegend,org.gvsig.fmap.mapcontext.rendering.legend.IVectorialUniqueValueLegend,org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend,org.gvsig.fmap.mapcontext.rendering.legend.Legend,org.gvsig.tools.lang.Cloneable,org.gvsig.tools.persistence.Persistent
public class ProportionalSymbolsLegend
extends org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialUniqueValueLegend
Implements a legend which represents the quantitative information
(numeric values). This representation is possible thanks to a symbol
whose size is different each time (depending on the numeric values
and if we want to use normalization or not).
- Author:
- jaume dominguez faus - jaume.dominguez@iver.es, jldominguez
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic class -
Field Summary
FieldsFields inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialUniqueValueLegend
VECTORIAL_UNIQUE_VALUE_LEGEND_PERSISTENCE_DEFINITION_NAMEFields inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractClassifiedVectorLegend
CLASSIFIED_VECTOR_LEGEND_PERSISTENCE_DEFINITION_NAMEFields inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
VECTORIAL_LEGEND_PERSISTENCE_DEFINITION_NAMEFields inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractLegend
LEGEND_PERSISTENCE_DEFINITION_NAMEFields inherited from interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorialUniqueValueLegend
LEGEND_NAME -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.gvsig.fmap.mapcontext.rendering.symbols.ISymbolGets the background symbol which only can appear when the shapetype of the layer is polygonaldoubleObtains the variable which represents the maximum value of the classifying field that is used to calculate the size of the symboldoubleObtains the maximum size for the symboldoubleObtains the variable which represents the minimum value of the classifying field that is used to calculate the size of the symboldoubleObtains the minimum size for the symbolObtains the classifying field name to be used to calculate the size of the symbol when the user is doing it with a normalization value.org.gvsig.fmap.mapcontext.rendering.symbols.ISymbolgetSymbolByFeature(org.gvsig.fmap.dal.feature.Feature feat) org.gvsig.fmap.mapcontext.rendering.symbols.ISymbolgetSymbolByValue(Object key) org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol[]intObtains the shapetype of the template symbolbooleanObtains the boolean which is true if the user wants to calculate the size of the symbol using a normalization field.Obtains the classifying field name to be used to calculate the size of the symbolorg.gvsig.fmap.mapcontext.rendering.legend.ZSortgetZSort()static booleanisLinear(int ty) static booleanisPoint(int ty) static booleanisPolygonal(int ty) voidloadFromState(org.gvsig.tools.persistence.PersistentState state) voidsaveToState(org.gvsig.tools.persistence.PersistentState state) voidsetBackgroundSymbol(org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol backgroundSymbol) Sets the background symbol which is used only when the shapetype of the layer is polygonalvoidsetClassifyingFieldNames(String[] fNames) voidsetMaxFeature(double maxFeature) Sets the variable which represents the maximum value of the classifying field that is used to calculate the size of the symbolvoidsetMaxSize(double maxSize) Sets the maximum size for the symbolvoidsetMinFeature(double minFeature) Sets the variable which represents the minimum value of the classifying field that is used to calculate the size of the symbolvoidsetMinSize(double minSize) Sets the minimum size for the symbolvoidsetNormalizationField(String normalizationField) Sets the classifying field name to be used to calculate the size of the symbol when the user is doing it with a normalization value.voidsetTemplateShapeType(int tst) Sets the shapetype of the template symbolvoidsetUseNormalization(boolean useNormalization) Sets the boolean which is true if the user wants to calculate the size of the symbol using a normalization field.voidsetValueField(String valueField) Sets the classifying field name to be used to calculate the size of the symbolvoidsetZSort(org.gvsig.fmap.mapcontext.rendering.legend.ZSort zSort) Methods inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialUniqueValueLegend
addSymbol, clear, clone, delAllSymbols, delSymbol, getClassName, getColorScheme, getDefaultSymbol, getDescriptions, getShapeType, getSymbolKey, getValues, isUseDefaultSymbol, replace, setClassifyingFieldTypes, setColorScheme, setDefaultSymbol, setShapeType, setValueSymbolByID, useDefaultSymbolMethods inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractClassifiedVectorLegend
fireClassifiedSymbolChangeEvent, fireLegendClearEvent, getClassifyingFieldNames, getClassifyingFieldTypes, getRequiredFeatureAttributeNames, isSuitableForShapeTypeMethods inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
draw, draw, draw, drawFeatures, internalDraw, isDrawSymbolInEeachPrimitive, print, print, setDrawSymbolInEeachPrimitiveMethods inherited from class org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractLegend
addDrawingObserver, addLegendListener, addObserver, beginComplexNotification, cloneLegend, countObservers, deleteDrawingObserver, deleteDrawingObservers, deleteObserver, disableNotifications, enableNotifications, endComplexNotification, fireDefaultSymbolChangedEvent, getListeners, getManager, getSymbolManager, inComplex, isEnabledNotifications, notifyObservers, notifyObservers, removeLegendListenerMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.gvsig.fmap.mapcontext.rendering.legend.DrawingObservable
addDrawingObserver, deleteDrawingObserver, deleteDrawingObserversMethods inherited from interface org.gvsig.fmap.mapcontext.rendering.legend.IClassifiedVectorLegend
getClassifyingFieldNames, getClassifyingFieldTypesMethods inherited from interface org.gvsig.fmap.mapcontext.rendering.legend.ILegend
addLegendListener, cloneLegend, fireDefaultSymbolChangedEvent, getListeners, removeLegendListenerMethods inherited from interface org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend
draw, draw, isSuitableForShapeType, print, print
-
Field Details
-
PROPORTIONAL_SYMBOL_LEGEND_NAME
- See Also:
-
PROPORTIONAL_SYMBOL_LEGEND_PERSISTENCE_DEFINITION_NAME
- See Also:
-
-
Constructor Details
-
ProportionalSymbolsLegend
public ProportionalSymbolsLegend()
-
-
Method Details
-
setClassifyingFieldNames
- Specified by:
setClassifyingFieldNamesin interfaceorg.gvsig.fmap.mapcontext.rendering.legend.IClassifiedVectorLegend- Overrides:
setClassifyingFieldNamesin classorg.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialUniqueValueLegend
-
getSymbolByValue
- Specified by:
getSymbolByValuein interfaceorg.gvsig.fmap.mapcontext.rendering.legend.IVectorialUniqueValueLegend- Overrides:
getSymbolByValuein classorg.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialUniqueValueLegend
-
getSymbolByFeature
public org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol getSymbolByFeature(org.gvsig.fmap.dal.feature.Feature feat) - Specified by:
getSymbolByFeaturein interfaceorg.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend- Overrides:
getSymbolByFeaturein classorg.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialUniqueValueLegend
-
isPolygonal
public static boolean isPolygonal(int ty) -
isLinear
public static boolean isLinear(int ty) -
isPoint
public static boolean isPoint(int ty) -
getBackgroundSymbol
public org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol getBackgroundSymbol()Gets the background symbol which only can appear when the shapetype of the layer is polygonal- Returns:
- ISymbol the symbol for the background
-
setBackgroundSymbol
public void setBackgroundSymbol(org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol backgroundSymbol) Sets the background symbol which is used only when the shapetype of the layer is polygonal- Parameters:
backgroundSymbol- the symbol for the background
-
getValueField
Obtains the classifying field name to be used to calculate the size of the symbol- Returns:
- String the name of the field
-
setValueField
Sets the classifying field name to be used to calculate the size of the symbol- Parameters:
String- the name of the field
-
getNormalizationField
Obtains the classifying field name to be used to calculate the size of the symbol when the user is doing it with a normalization value.- Returns:
- String the name of the field
-
setNormalizationField
Sets the classifying field name to be used to calculate the size of the symbol when the user is doing it with a normalization value.- Parameters:
String- the name of the field
-
getMinSize
public double getMinSize()Obtains the minimum size for the symbol- Returns:
- double the minimum size for the symbol
-
setMinSize
public void setMinSize(double minSize) Sets the minimum size for the symbol- Parameters:
minSize- the minimum size for the symbol
-
getMaxSize
public double getMaxSize()Obtains the maximum size for the symbol- Returns:
- double the minimum size for the symbol
-
setMaxSize
public void setMaxSize(double maxSize) Sets the maximum size for the symbol- Parameters:
maxSize- the minimum size for the symbol
-
getTemplateShapeType
public int getTemplateShapeType()Obtains the shapetype of the template symbol- Returns:
- int shape type for the template symbol
-
setTemplateShapeType
public void setTemplateShapeType(int tst) Sets the shapetype of the template symbol- Parameters:
templateShapeType- shape type for the template symbol
-
getUseNormalization
public boolean getUseNormalization()Obtains the boolean which is true if the user wants to calculate the size of the symbol using a normalization field.- Returns:
- boolean true if the user wants normalization.Otherwise, false.
-
setUseNormalization
public void setUseNormalization(boolean useNormalization) Sets the boolean which is true if the user wants to calculate the size of the symbol using a normalization field.- Parameters:
useNormalization- true if the user wants normalization.Otherwise, false.
-
getMaxFeature
public double getMaxFeature()Obtains the variable which represents the maximum value of the classifying field that is used to calculate the size of the symbol- Returns:
- double the maximum value of the classifying field
-
setMaxFeature
public void setMaxFeature(double maxFeature) Sets the variable which represents the maximum value of the classifying field that is used to calculate the size of the symbol- Parameters:
maxFeature-
-
getMinFeature
public double getMinFeature()Obtains the variable which represents the minimum value of the classifying field that is used to calculate the size of the symbol- Returns:
- double the minimum value of the classifying field
-
setMinFeature
public void setMinFeature(double minFeature) Sets the variable which represents the minimum value of the classifying field that is used to calculate the size of the symbol- Parameters:
minFeature-
-
getSymbols
public org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol[] getSymbols()- Specified by:
getSymbolsin interfaceorg.gvsig.fmap.mapcontext.rendering.legend.IClassifiedLegend- Overrides:
getSymbolsin classorg.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialUniqueValueLegend
-
getZSort
public org.gvsig.fmap.mapcontext.rendering.legend.ZSort getZSort()- Specified by:
getZSortin interfaceorg.gvsig.fmap.mapcontext.rendering.legend.IVectorialUniqueValueLegend- Overrides:
getZSortin classorg.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
-
setZSort
public void setZSort(org.gvsig.fmap.mapcontext.rendering.legend.ZSort zSort) - Specified by:
setZSortin interfaceorg.gvsig.fmap.mapcontext.rendering.legend.IVectorialUniqueValueLegend- Overrides:
setZSortin classorg.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend
-
loadFromState
public void loadFromState(org.gvsig.tools.persistence.PersistentState state) throws org.gvsig.tools.persistence.exception.PersistenceException - Specified by:
loadFromStatein interfaceorg.gvsig.tools.persistence.Persistent- Overrides:
loadFromStatein classorg.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialUniqueValueLegend- Throws:
org.gvsig.tools.persistence.exception.PersistenceException
-
saveToState
public void saveToState(org.gvsig.tools.persistence.PersistentState state) throws org.gvsig.tools.persistence.exception.PersistenceException - Specified by:
saveToStatein interfaceorg.gvsig.tools.persistence.Persistent- Overrides:
saveToStatein classorg.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialUniqueValueLegend- Throws:
org.gvsig.tools.persistence.exception.PersistenceException
-