Class ChartHoverEvent
- java.lang.Object
-
- org.pepstock.charba.client.events.Event
-
- org.pepstock.charba.client.events.AbstractEvent
-
- org.pepstock.charba.client.events.ChartHoverEvent
-
- All Implemented Interfaces:
HasNativeEvent
,IsChartEvent
public final class ChartHoverEvent extends AbstractEvent
Event which is fired when the user hovers on the chart.- Author:
- Andrea "Stock" Stocchero
-
-
Constructor Summary
Constructors Constructor Description ChartHoverEvent(ChartEventContext eventContext, List<DatasetReference> items)
Creates the event with a list of items with dataset references related to the hover
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected void
dispatch(EventHandler handler)
Implemented by subclasses to dispatch event on the handler.IsChart
getChart()
Returns the chart instance, stored in the event as source.IsChart
getChart()
Returns the chart instance, stored in the event as source.ChartEventContext
getContext()
Returns the java script function context of CHART.JS events.ChartEventContext
getContext()
Returns the java script function context of CHART.JS events.List<DatasetReference>
getItems()
Returns a list of items with dataset references related to the click.Key
getKey()
Returns the options key where default function is stored.Key
getKey()
Returns the options key where default function is stored.-
Methods inherited from class org.pepstock.charba.client.events.AbstractEvent
getNativeEvent, getType
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.pepstock.charba.client.events.HasNativeEvent
getNativeEvent
-
-
-
-
Field Detail
-
TYPE
public static final EventType TYPE
Event type
-
-
Constructor Detail
-
ChartHoverEvent
public ChartHoverEvent(ChartEventContext eventContext, List<DatasetReference> items)
Creates the event with a list of items with dataset references related to the hover- Parameters:
eventContext
- event context generated by CHART.jsitems
- a list of items with dataset references related to the hover
-
-
Method Detail
-
dispatch
protected void dispatch(EventHandler handler)
Description copied from class:Event
Implemented by subclasses to dispatch event on the handler.
-
getItems
public final List<DatasetReference> getItems()
Returns a list of items with dataset references related to the click.- Specified by:
getItems
in interfaceIsChartEvent
- Returns:
- a list of items with dataset references related to the click
-
getContext
public abstract ChartEventContext getContext()
Returns the java script function context of CHART.JS events.- Returns:
- the java script function context of CHART.JS events.
-
getKey
public abstract Key getKey()
Returns the options key where default function is stored.- Returns:
- the options key where default function is stored
-
getChart
public abstract IsChart getChart()
Returns the chart instance, stored in the event as source.- Returns:
- the chart instance
-
getContext
public final ChartEventContext getContext()
Returns the java script function context of CHART.JS events.- Returns:
- the java script function context of CHART.JS events.
-
getKey
public final Key getKey()
Returns the options key where default function is stored.- Returns:
- the options key where default function is stored
-
getChart
public IsChart getChart()
Returns the chart instance, stored in the event as source.- Overrides:
getChart
in classAbstractEvent
- Returns:
- the chart instance
-
-