public final class DatasetsItemsSelector extends AbstractPlugin
AtLeastOneDatasetHandler
Modifier and Type | Field and Description |
---|---|
static DatasetsItemsSelectorOptionsFactory |
FACTORY
The factory to read options for plugin
|
static String |
ID
Plugin ID "datasetsitemsselector".
|
Constructor and Description |
---|
DatasetsItemsSelector() |
Modifier and Type | Method and Description |
---|---|
void |
clearSelection(IsChart chart)
Clears the selection on the chart.
|
void |
clearSelection(IsChart chart,
boolean fireEvent)
Clears the selection on the chart and set if an event should fire on clear action.
|
String |
getId()
Plugins must define a unique id in order to be configurable.
Returns the plugin id. |
double |
getPadding(IsChart chart)
Returns the padding height used by clear selection element if enabled.
This is very helpful when you have added padding for your purposes and you need to know the amount of space that the element allocated. |
void |
onAfterDraw(IsChart chart,
double easing)
Called after the 'chart' has been drawn for the specific easing value.
|
boolean |
onBeforeEvent(IsChart chart,
ChartNativeEvent event)
Called before processing the specified 'event'.
|
boolean |
onBeforeUpdate(IsChart chart)
Called before updating 'chart'.
|
void |
onConfigure(IsChart chart)
Called before initializing configuration of 'chart'.
|
void |
onDestroy(IsChart chart)
Called after the chart as been destroyed.
|
void |
skipNextRefreshFireEvent(IsChart chart)
Sets a flag to skip to send event after refresh.
|
onAfterDatasetDraw, onAfterDatasetsDraw, onAfterDatasetsUpdate, onAfterDatasetUpdate, onAfterEvent, onAfterInit, onAfterLayout, onAfterRender, onAfterTooltipDraw, onAfterUpdate, onBeforeDatasetDraw, onBeforeDatasetsDraw, onBeforeDatasetsUpdate, onBeforeDatasetUpdate, onBeforeDraw, onBeforeInit, onBeforeLayout, onBeforeRender, onBeforeTooltipDraw, onResize, toString
public static final String ID
public static final DatasetsItemsSelectorOptionsFactory FACTORY
public double getPadding(IsChart chart)
chart
- chart instanceClearSelection.DEFAULT_VALUE
if disabledpublic void clearSelection(IsChart chart)
chart
- chart instance to clear the selectionDatasetsItemsSelectorOptions.isFireEventOnClearSelection()
,
DatasetsItemsSelectorOptions.setFireEventOnClearSelection(boolean)
public void clearSelection(IsChart chart, boolean fireEvent)
chart
- chart instance to clear the selectionfireEvent
- if true
an event is fired otherwise not.public void skipNextRefreshFireEvent(IsChart chart)
chart
- chart instance to apply the fire events skipping.public String getId()
Plugin
public void onConfigure(IsChart chart)
Plugin
onConfigure
in interface Plugin
onConfigure
in class AbstractPlugin
chart
- the chart instance.public boolean onBeforeUpdate(IsChart chart)
Plugin
false
, the update is cancelled (and thus subsequent
render(s)) until another 'update' is triggered.onBeforeUpdate
in interface Plugin
onBeforeUpdate
in class AbstractPlugin
chart
- the chart instance.false
to cancel the chart update.public void onAfterDraw(IsChart chart, double easing)
Plugin
onAfterDraw
in interface Plugin
onAfterDraw
in class AbstractPlugin
chart
- the chart instance.easing
- The current animation value, between 0.0 and 1.0.public void onDestroy(IsChart chart)
Plugin
onDestroy
in interface Plugin
onDestroy
in class AbstractPlugin
chart
- the chart instance.public boolean onBeforeEvent(IsChart chart, ChartNativeEvent event)
Plugin
false
, the event will be discarded.onBeforeEvent
in interface Plugin
onBeforeEvent
in class AbstractPlugin
chart
- the chart instance.event
- The event object.false
to discard the event.