@DomEvent(value="point-update") public class PointUpdateEvent extends ComponentEvent<Chart> implements HasItem
source| Constructor and Description |
|---|
PointUpdateEvent(Chart source,
boolean fromClient,
int seriesIndex,
String category,
int pointIndex,
String pointId,
Double oldXValue,
Double oldYValue,
Double newXValue,
Double newYValue) |
| Modifier and Type | Method and Description |
|---|---|
String |
getCategory() |
String |
getItemId()
The ID of the series item that is associated with the event.
|
int |
getItemIndex()
Returns the index of the series item, that is associated with this event,
in
HasSeries.getSeries(). |
Double |
getOldXValue() |
Double |
getOldYValue() |
int |
getSeriesItemIndex()
Returns the index of the series
|
Double |
getxValue() |
Double |
getyValue() |
getSource, isFromClient, unregisterListenertoStringpublic PointUpdateEvent(Chart source, boolean fromClient, @EventData(value="event.detail.originalEvent.target.series.index") int seriesIndex, @EventData(value="event.detail.originalEvent.target.category") String category, @EventData(value="event.detail.originalEvent.target.index") int pointIndex, @EventData(value="event.detail.originalEvent.target.id") String pointId, @EventData(value="event.detail.originalEvent.target.x") Double oldXValue, @EventData(value="event.detail.originalEvent.target.y") Double oldYValue, @EventData(value="event.detail.originalEvent.options.x") Double newXValue, @EventData(value="event.detail.originalEvent.options.y") Double newYValue)
public Double getOldXValue()
public Double getOldYValue()
public Double getxValue()
public Double getyValue()
public int getSeriesItemIndex()
HasSeriesgetSeriesItemIndex in interface HasSeriespublic String getCategory()
getCategory in interface HasItempublic int getItemIndex()
HasItemHasSeries.getSeries(). Can be used to identify the item within the
series.
Example for ListSeries:
int itemIndex = event.getItemIndex(); ListSeries series = (ListSeries) event.getSeries(); Number datum = series.getData()[itemIndex];
getItemIndex in interface HasItemHasItem.getItem(),
HasItem.getItemId()public String getItemId()
HasItem
Example for TreeSeries:
String id = this.getItemId();
TreeSeries series = (TreeSeries) this.getSeries();
Optional<TreeSeriesItem> treeItem = series.getData().stream()
.filter(item -> item.getId().equals(id)).findFirst();
Only AbstractSeriesItem supports setting an ID. For other types
of series items this property will always return null. For
AbstractSeriesItem the ID is optional. Unless the developer has
explicitly set an ID for the item associated with the event, this
property will be null. See HasItem.getItem() or HasItem.getItemIndex()
for alternatives.
getItemId in interface HasItemHasItem.getItem(),
HasItem.getItemIndex()Copyright © 2025. All rights reserved.