Package org.pepstock.charba.client.geo
Class ChoroplethDataPoint
- java.lang.Object
-
- org.pepstock.charba.client.commons.NativeObjectContainer
-
- org.pepstock.charba.client.data.AbstractDataPoint
-
- org.pepstock.charba.client.geo.ChoroplethDataPoint
-
public final class ChoroplethDataPoint extends AbstractDataPoint
Used for GEO data sets to set the data to render.
A GEO data has to have afeatureproperty containing the feature to render and avalueproperty containing the value for the coloring.- Author:
- Andrea "Stock" Stocchero
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classChoroplethDataPoint.ChoroplethDataPointFactoryCreatesChoroplethDataPointform aNativeObject.-
Nested classes/interfaces inherited from class org.pepstock.charba.client.data.AbstractDataPoint
AbstractDataPoint.CharbaProperty
-
-
Field Summary
Fields Modifier and Type Field Description static ChoroplethDataPoint.ChoroplethDataPointFactoryFACTORYFactory instance to create data points.
-
Constructor Summary
Constructors Constructor Description ChoroplethDataPoint()Creates the object with an empty native object.ChoroplethDataPoint(Feature feature)Creates the object with the assigned feature.ChoroplethDataPoint(Feature feature, double value)Creates the object with the assigned feature and value.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DataPointCentergetCenter()Returns the coordinates where the tooltip should appear.FeaturegetFeature()Returns the feature object to identify the region.doublegetValue()Returns the value for the coloring.voidsetCenter(DataPointCenter center)Sets the coordinates where the tooltip should appear.voidsetFeature(Feature feature)Sets the feature object to identify the region.voidsetValue(double value)Sets the value for the coloring.-
Methods inherited from class org.pepstock.charba.client.data.AbstractDataPoint
checkAndSetType, getAttribute, getAttributeAsDate, getAttributeAsObject, getAttributeAsString, setAttribute, setAttribute, setAttribute, setAttribute
-
Methods inherited from class org.pepstock.charba.client.commons.NativeObjectContainer
checkAndGetColor, checkDefaultValuesArgument, empty, getArrayValue, getElement, getIncrementalId, getNativeChart, getNativeEvent, getNativeObject, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValueForMultipleKeyTypes, getValueForMultipleKeyTypes, getValueForMultipleKeyTypes, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, getValueOrArray, has, has, isType, keys, loadNativeObject, remove, remove, setArrayValue, setArrayValue, setArrayValue, setElement, setEmptyValue, setNewIncrementalId, setNewIncrementalId, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, setValueOrArray, toJSON, type
-
-
-
-
Field Detail
-
FACTORY
public static final ChoroplethDataPoint.ChoroplethDataPointFactory FACTORY
Factory instance to create data points. To use byDataItemto get the data point for choropleth chart.
-
-
Constructor Detail
-
ChoroplethDataPoint
public ChoroplethDataPoint()
Creates the object with an empty native object.
-
ChoroplethDataPoint
public ChoroplethDataPoint(Feature feature)
Creates the object with the assigned feature.- Parameters:
feature- the feature object to identify the region.
-
ChoroplethDataPoint
public ChoroplethDataPoint(Feature feature, double value)
Creates the object with the assigned feature and value.- Parameters:
feature- the feature object to identify the region.value- the value for the coloring
-
-
Method Detail
-
setFeature
public void setFeature(Feature feature)
Sets the feature object to identify the region.- Parameters:
feature- the feature object to identify the region
-
getFeature
public Feature getFeature()
Returns the feature object to identify the region.- Returns:
- the feature object to identify the region
-
setValue
public final void setValue(double value)
Sets the value for the coloring.- Parameters:
value- the value for the coloring
-
getValue
public final double getValue()
Returns the value for the coloring.- Returns:
- the value for the coloring
-
setCenter
public final void setCenter(DataPointCenter center)
Sets the coordinates where the tooltip should appear. e.g. at the capital city.- Parameters:
center- the coordinates where the tooltip should appear. e.g. at the capital city.
-
getCenter
public final DataPointCenter getCenter()
Returns the coordinates where the tooltip should appear. e.g. at the capital city.- Returns:
- the coordinates where the tooltip should appear. e.g. at the capital city.
-
-