public abstract class AbstractIntervalLegend extends AbstractClassifiedVectorLegend implements IVectorialIntervalLegend
| Modifier and Type | Class and Description |
|---|---|
static class |
AbstractIntervalLegend.RegisterPersistence |
| Modifier and Type | Field and Description |
|---|---|
protected ISymbol |
defaultSymbol |
static int |
EQUAL_INTERVALS |
static String |
INTERVAL_LEGEND_PERSISTENCE_DEFINITION_NAME |
protected int |
intervalType |
protected List<Object> |
keys |
static int |
NATURAL_INTERVALS |
static int |
QUANTILE_INTERVALS |
protected Map<Object,ISymbol> |
symbols |
protected boolean |
useDefaultSymbol |
CLASSIFIED_VECTOR_LEGEND_PERSISTENCE_DEFINITION_NAMEVECTORIAL_LEGEND_PERSISTENCE_DEFINITION_NAME, zSortLEGEND_PERSISTENCE_DEFINITION_NAMELEGEND_NAME| Constructor and Description |
|---|
AbstractIntervalLegend() |
| Modifier and Type | Method and Description |
|---|---|
void |
addSymbol(Object key,
ISymbol symbol)
Inserts a symbol.
|
IInterval[] |
calculateIntervals(FeatureStore featureStore,
String fieldName,
int numIntervalos,
int shapeType) |
void |
clear()
Deletes all the information of classification:
intervals, values, or other classifying elements
|
Object |
clone()
Creates a copy of the object.
|
Map<IInterval,ISymbol> |
createSymbols(IInterval[] intervals) |
void |
delSymbol(Object obj)
Deletes a symbol using for that its key which is the parameter of the
method.
|
ISymbol |
getDefaultSymbol()
Obtains the default symbol of the legend.
|
String[] |
getDescriptions()
Obtains the descriptions of the classes that are in the classification
|
IInterval |
getInterval(Object v) |
int |
getIntervalType() |
ISymbol |
getSymbol(FeatureReference featureID) |
ISymbol |
getSymbolByFeature(Feature feat)
Returns a symbol starting from an IFeature.
|
ISymbol |
getSymbolByInterval(IInterval key)
Returns the symbol starting from an interval
|
ISymbol[] |
getSymbols()
Obtains the symbols of each class of the classification for the user.
|
Object[] |
getValues()
Obtains the values in relation with each class of the classification
|
boolean |
isUseDefaultSymbol()
Returns true or false depending on if the rest of values are used.
|
void |
loadFromState(PersistentState state)
Set the state of the object from the state passed as parameter.
|
void |
replace(ISymbol oldSymbol,
ISymbol newSymbol)
Removes oldSymbol from the Legend and substitutes it with the newSymbol
|
void |
saveToState(PersistentState state)
Saves the internal state of the object on the provided
PersistentState object.
|
void |
setDefaultSymbol(ISymbol s)
Establishes the default symbol of a legend.
|
void |
setIntervals(IInterval[] intervals) |
void |
setIntervalType(int intervalType)
Inserts the type of the classification of the intervals.
|
void |
useDefaultSymbol(boolean b) |
fireClassifiedSymbolChangeEvent, fireLegendClearEvent, getClassifyingFieldNames, getClassifyingFieldTypes, getRequiredFeatureAttributeNames, isSuitableForShapeType, setClassifyingFieldNames, setClassifyingFieldTypesdraw, draw, draw, getZSort, internalDraw, print, print, setZSortaddDrawingObserver, addLegendListener, addObserver, beginComplexNotification, cloneLegend, countObservers, deleteDrawingObserver, deleteDrawingObservers, deleteObserver, disableNotifications, enableNotifications, endComplexNotification, fireDefaultSymbolChangedEvent, getListeners, getManager, getSymbolManager, inComplex, isEnabledNotifications, notifyObservers, notifyObservers, removeLegendListenerequals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetEndColor, getStartColor, setEndColor, setStartColorgetClassifyingFieldNames, getClassifyingFieldTypes, setClassifyingFieldNames, setClassifyingFieldTypesdraw, draw, getShapeType, isSuitableForShapeType, print, print, setShapeTypeaddLegendListener, cloneLegend, fireDefaultSymbolChangedEvent, getListeners, removeLegendListeneraddDrawingObserver, deleteDrawingObserver, deleteDrawingObserverspublic static final String INTERVAL_LEGEND_PERSISTENCE_DEFINITION_NAME
protected ISymbol defaultSymbol
protected int intervalType
protected boolean useDefaultSymbol
public static final int EQUAL_INTERVALS
public static final int NATURAL_INTERVALS
public static final int QUANTILE_INTERVALS
public void addSymbol(Object key, ISymbol symbol)
IClassifiedVectorLegendaddSymbol in interface IClassifiedVectorLegendpublic ISymbol getSymbol(FeatureReference featureID) throws MapContextException, DataException
MapContextExceptionDataExceptionpublic ISymbol getSymbolByFeature(Feature feat) throws MapContextException
IVectorLegendgetSymbolByFeature in interface IVectorLegendfeat - IFeature.MapContextExceptionpublic IInterval[] calculateIntervals(FeatureStore featureStore, String fieldName, int numIntervalos, int shapeType) throws DataException
calculateIntervals in interface IVectorialIntervalLegendDataExceptionpublic ISymbol getSymbolByInterval(IInterval key)
IVectorialIntervalLegendgetSymbolByInterval in interface IVectorialIntervalLegendkey - interval.public String[] getDescriptions()
IClassifiedLegendgetDescriptions in interface IClassifiedLegendpublic Object[] getValues()
IClassifiedLegendgetValues in interface IClassifiedLegendpublic void clear()
IClassifiedVectorLegendclear in interface IClassifiedVectorLegendpublic ISymbol[] getSymbols()
IClassifiedLegendgetSymbols in interface IClassifiedLegendpublic void setDefaultSymbol(ISymbol s)
IVectorLegendsetDefaultSymbol in interface IVectorialIntervalLegendsetDefaultSymbol in interface IVectorLegends - default symbol.public ISymbol getDefaultSymbol()
ILegendgetDefaultSymbol in interface ILegendpublic IInterval getInterval(Object v)
getInterval in interface IVectorialIntervalLegendpublic void setIntervalType(int intervalType)
IVectorialIntervalLegendsetIntervalType in interface IVectorialIntervalLegendintervalType - type of the classification.public int getIntervalType()
getIntervalType in interface IVectorialIntervalLegendpublic void useDefaultSymbol(boolean b)
useDefaultSymbol in interface IVectorLegendpublic boolean isUseDefaultSymbol()
IVectorLegendisUseDefaultSymbol in interface IVectorLegendpublic void delSymbol(Object obj)
IClassifiedVectorLegenddelSymbol in interface IClassifiedVectorLegendobj - clave.public void replace(ISymbol oldSymbol, ISymbol newSymbol)
IClassifiedVectorLegendreplace in interface IClassifiedVectorLegendpublic Object clone() throws CloneNotSupportedException
Cloneableclone in class AbstractClassifiedVectorLegendCloneNotSupportedException - 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 void loadFromState(PersistentState state) throws PersistenceException
PersistentloadFromState in interface PersistentloadFromState in class AbstractClassifiedVectorLegendPersistenceExceptionpublic void saveToState(PersistentState state) throws PersistenceException
PersistentsaveToState in interface PersistentsaveToState in class AbstractClassifiedVectorLegendPersistenceExceptionpublic Map<IInterval,ISymbol> createSymbols(IInterval[] intervals)
createSymbols in interface IVectorialIntervalLegendpublic void setIntervals(IInterval[] intervals)
setIntervals in interface IVectorialIntervalLegend