public class VectorialIntervalLegend extends AbstractIntervalLegend
VectorialIntervalLegend (which should be better called GraduatedColorLegend) is a legend that allows to classify ranges of values using a color gradient based on a value.
The color gradient will be calculated according the starting color, the ending color and the amount of intervals.
Modifier and Type | Class and Description |
---|---|
static class |
VectorialIntervalLegend.RegisterLegend |
static class |
VectorialIntervalLegend.RegisterPersistence |
Modifier and Type | Field and Description |
---|---|
static String |
VECTORIAL_INTERVAL_LEGEND_PERSISTENCE_DEFINITION_NAME |
defaultSymbol, EQUAL_INTERVALS, INTERVAL_LEGEND_PERSISTENCE_DEFINITION_NAME, intervalType, keys, NATURAL_INTERVALS, QUANTILE_INTERVALS, symbols, useDefaultSymbol
CLASSIFIED_VECTOR_LEGEND_PERSISTENCE_DEFINITION_NAME
VECTORIAL_LEGEND_PERSISTENCE_DEFINITION_NAME, zSort
LEGEND_PERSISTENCE_DEFINITION_NAME
LEGEND_NAME
Constructor and Description |
---|
VectorialIntervalLegend()
Constructor method
|
VectorialIntervalLegend(int type)
Constructor method
|
Modifier and Type | Method and Description |
---|---|
Object |
clone()
Creates a copy of the object.
|
IInterval |
createInterval(double min,
double max) |
String |
getClassName() |
Color |
getEndColor()
Returns the final color
|
int |
getShapeType()
Returns the type of the shape.
|
Color |
getStartColor()
Returns the initial color.
|
void |
loadFromState(PersistentState state)
Set the state of the object from the state passed as parameter.
|
void |
saveToState(PersistentState state)
Saves the internal state of the object on the provided
PersistentState object.
|
void |
setEndColor(Color endColor)
Inserts the final color.
|
void |
setShapeType(int shapeType)
Defines the type of the shape.
|
void |
setStartColor(Color startColor)
Inserts the initial color
|
addSymbol, calculateIntervals, clear, createSymbols, delSymbol, getDefaultSymbol, getDescriptions, getInterval, getIntervalType, getSymbol, getSymbolByFeature, getSymbolByInterval, getSymbols, getValues, isUseDefaultSymbol, replace, setDefaultSymbol, setIntervals, setIntervalType, useDefaultSymbol
fireClassifiedSymbolChangeEvent, fireLegendClearEvent, getClassifyingFieldNames, getClassifyingFieldTypes, getRequiredFeatureAttributeNames, isSuitableForShapeType, setClassifyingFieldNames, setClassifyingFieldTypes
draw, draw, draw, getZSort, internalDraw, print, print, setZSort
addDrawingObserver, addLegendListener, addObserver, beginComplexNotification, cloneLegend, countObservers, deleteDrawingObserver, deleteDrawingObservers, deleteObserver, disableNotifications, enableNotifications, endComplexNotification, fireDefaultSymbolChangedEvent, getListeners, getManager, getSymbolManager, inComplex, isEnabledNotifications, notifyObservers, notifyObservers, removeLegendListener
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getClassifyingFieldNames, getClassifyingFieldTypes, setClassifyingFieldNames, setClassifyingFieldTypes
draw, draw, isSuitableForShapeType, print, print
addLegendListener, cloneLegend, fireDefaultSymbolChangedEvent, getListeners, removeLegendListener
addDrawingObserver, deleteDrawingObserver, deleteDrawingObservers
public static final String VECTORIAL_INTERVAL_LEGEND_PERSISTENCE_DEFINITION_NAME
public VectorialIntervalLegend()
public VectorialIntervalLegend(int type)
type
- type of the shape.public Color getEndColor()
public void setEndColor(Color endColor)
endColor
- final color.public Color getStartColor()
public void setStartColor(Color startColor)
startColor
- initial color.public int getShapeType()
IVectorLegend
public void setShapeType(int shapeType)
IVectorLegend
shapeType
- type of the shape.public String getClassName()
public Object clone() throws CloneNotSupportedException
Cloneable
clone
in class AbstractIntervalLegend
CloneNotSupportedException
- if the instance of the object cannot
be cloned. As this is extending Cloneable
so
its sure it implements it, so this exception may be used for problems
on specific object instances.Object#clone()}.
public IInterval createInterval(double min, double max)
public void loadFromState(PersistentState state) throws PersistenceException
Persistent
loadFromState
in interface Persistent
loadFromState
in class AbstractIntervalLegend
PersistenceException
public void saveToState(PersistentState state) throws PersistenceException
Persistent
saveToState
in interface Persistent
saveToState
in class AbstractIntervalLegend
PersistenceException