public class Data extends BaseOption
An array of data points for the series. For the pie
series type, points can be given in the following ways:
An array of numerical values. In this case, the numerical values will be interpreted as y
options. Example:
data: [0, 5, 3, 5]
An array of objects with named values. The following snippet shows only a few settings, see the complete options set below. If the total number of data points exceeds the series' turboThreshold, this option is not available.
data: [{ y: 1, name: "Point2", color: "#00FF00" }, { y: 7, name: "Point1", color: "#FF00FF" }]
Constructor and Description |
---|
Data() |
Modifier and Type | Method and Description |
---|---|
String |
getName()
The name of the point as shown in the legend, tooltip, dataLabels etc.
|
Boolean |
getSelected()
Whether the data point is selected initially.
|
Boolean |
getSliced()
Whether to display a slice offset from the center.
|
Number |
getY()
The y value of the point.
|
String |
name()
The name of the point as shown in the legend, tooltip, dataLabels etc.
|
Data |
name(String name)
The name of the point as shown in the legend, tooltip, dataLabels etc.
|
Boolean |
selected()
Whether the data point is selected initially.
|
Data |
selected(Boolean selected)
Whether the data point is selected initially.
|
Data |
setName(String name)
The name of the point as shown in the legend, tooltip, dataLabels etc.
|
Data |
setSelected(Boolean selected)
Whether the data point is selected initially.
|
Data |
setSliced(Boolean sliced)
Whether to display a slice offset from the center.
|
Data |
setY(Number y)
The y value of the point.
|
Boolean |
sliced()
Whether to display a slice offset from the center.
|
Data |
sliced(Boolean sliced)
Whether to display a slice offset from the center.
|
Number |
y()
The y value of the point.
|
Data |
y(Number y)
The y value of the point.
|
set_hcNulledOption
public String name()
The name of the point as shown in the legend, tooltip, dataLabels etc.
public Data name(String name)
The name of the point as shown in the legend, tooltip, dataLabels etc.
name
- the value for the name optionpublic String getName()
The name of the point as shown in the legend, tooltip, dataLabels etc.
public Data setName(String name)
The name of the point as shown in the legend, tooltip, dataLabels etc.
name
- the value for the name optionpublic Boolean selected()
Whether the data point is selected initially.
public Data selected(Boolean selected)
Whether the data point is selected initially.
selected
- the value for the selected optionpublic Boolean getSelected()
Whether the data point is selected initially.
public Data setSelected(Boolean selected)
Whether the data point is selected initially.
selected
- the value for the selected optionpublic Boolean sliced()
Whether to display a slice offset from the center.
public Data sliced(Boolean sliced)
Whether to display a slice offset from the center.
sliced
- the value for the sliced optionpublic Boolean getSliced()
Whether to display a slice offset from the center.
public Data setSliced(Boolean sliced)
Whether to display a slice offset from the center.
sliced
- the value for the sliced optionpublic Number y()
The y value of the point.
public Data y(Number y)
The y value of the point.
y
- the value for the y optionpublic Number getY()
The y value of the point.
Copyright © 2022. All rights reserved.