Class ChartClickEvent
- java.lang.Object
- 
- org.pepstock.charba.client.events.Event
- 
- org.pepstock.charba.client.events.AbstractEvent
- 
- org.pepstock.charba.client.events.ChartClickEvent
 
 
 
- 
- All Implemented Interfaces:
- IsChartEvent,- IsCommonChartEvent
 
 public final class ChartClickEvent extends AbstractEvent Event which is fired when the user clicks on the chart.- Author:
- Andrea "Stock" Stocchero
 
- 
- 
Constructor SummaryConstructors Constructor Description ChartClickEvent(ChartEventContext eventContext, List<DatasetReference> items)Creates the event with a list of items with dataset references related to the click
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voiddispatch(EventHandler handler)Implemented by subclasses to dispatch event on the handler.IsChartgetChart()Returns the chart instance, stored in the event as source.ChartEventContextgetContext()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.KeygetKey()Returns the options key where default function is stored.- 
Methods inherited from class org.pepstock.charba.client.events.AbstractEventgetNativeEvent, getType
 - 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface org.pepstock.charba.client.events.IsCommonChartEventgetChart, getContext, getKey, getNativeEvent
 
- 
 
- 
- 
- 
Field Detail- 
TYPEpublic static final EventType TYPE Event type
 
- 
 - 
Constructor Detail- 
ChartClickEventpublic ChartClickEvent(ChartEventContext eventContext, List<DatasetReference> items) Creates the event with a list of items with dataset references related to the click- Parameters:
- eventContext- event context generated by CHART.js
- items- a list of items with dataset references related to the click
 
 
- 
 - 
Method Detail- 
dispatchprotected void dispatch(EventHandler handler) Description copied from class:EventImplemented by subclasses to dispatch event on the handler.
 - 
getItemspublic final List<DatasetReference> getItems() Returns a list of items with dataset references related to the click.- Specified by:
- getItemsin interface- IsChartEvent
- Returns:
- a list of items with dataset references related to the click
 
 - 
getContextpublic final ChartEventContext getContext() Returns the java script function context of CHART.JS events.- Returns:
- the java script function context of CHART.JS events.
 
 - 
getKeypublic final Key getKey() Returns the options key where default function is stored.- Returns:
- the options key where default function is stored
 
 - 
getChartpublic IsChart getChart() Returns the chart instance, stored in the event as source.- Overrides:
- getChartin class- AbstractEvent
- Returns:
- the chart instance
 
 
- 
 
-