org.moxieapps.gwt.highcharts.client.labels
Class LegendLabelsData

java.lang.Object
  extended by org.moxieapps.gwt.highcharts.client.labels.LegendLabelsData

public class LegendLabelsData
extends Object

An object that represents the state information that will be passed to any custom LegendLabelsFormatter to allow for custom strings to be rendered as the legend labels.

See the LegendLabelsFormatter.format(LegendLabelsData) method for more details on the capabilities that custom formatters can provide.

Since:
1.3.0
Author:
squinn@moxiegroup.com (Shawn Quinn)

Constructor Summary
LegendLabelsData(com.google.gwt.core.client.JavaScriptObject data)
          This constructor needs to be public scope but you should not construct this object directly, but instead simply implement a custom LegendLabelsFormatter and this API will pass you the appropriate instance of this object at runtime.
 
Method Summary
 com.google.gwt.core.client.JavaScriptObject getNativeData()
          Returns a pointer to the native Highchart's instance data object that this GWT instance is wrapping.
 Point getPoint()
          For pie charts, return a GWT point instance that is connected to the Highcharts JS point instance associated with the legend label.
 String getPointName()
          For pie charts, return the name of the point (e.g.
 String getSeriesId()
          Retrieve the unique id of the series that the point is a part of which received the event.
 String getSeriesName()
          Return the name of the series that the legend label applies to (e.g.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LegendLabelsData

public LegendLabelsData(com.google.gwt.core.client.JavaScriptObject data)
This constructor needs to be public scope but you should not construct this object directly, but instead simply implement a custom LegendLabelsFormatter and this API will pass you the appropriate instance of this object at runtime.

Parameters:
data - A reference to the native Highcharts javascript object.
Method Detail

getSeriesId

public String getSeriesId()
Retrieve the unique id of the series that the point is a part of which received the event. This id can then be used to obtain the Series instance itself via the BaseChart.getSeries(String) method.

Returns:
The unique id of the series that the point was a part of that the event was triggered on.

getSeriesName

public String getSeriesName()
Return the name of the series that the legend label applies to (e.g. "series.name").

Returns:
The name of the series that the legend label applies to

getPointName

public String getPointName()
For pie charts, return the name of the point (e.g. "point.name") that the legend label is associated with.

Returns:
The name of the point that the legend label is associated with.

getPoint

public Point getPoint()
For pie charts, return a GWT point instance that is connected to the Highcharts JS point instance associated with the legend label.

Returns:
A Point instance that is connected to the Highcharts data point associated with the legend label

getNativeData

public com.google.gwt.core.client.JavaScriptObject getNativeData()
Returns a pointer to the native Highchart's instance data object that this GWT instance is wrapping. For advanced JSNI use-cases only.

Returns:
The native Highcharts object instance that this GWT instance is associated with.
Since:
1.5.0


Copyright © 2015. All Rights Reserved.