public class XAxis extends BaseOption
The X axis or category axis. Normally this is the horizontal axis, though if the chart is inverted this is the vertical axis. In case of multiple axes, the xAxis node is an array of configuration objects.
See the Axis class for programmatic access to the axis.
Copyright (c) 2026 Powerbuilt Systems. All rights reserved.| Constructor and Description |
|---|
XAxis() |
| Modifier and Type | Method and Description |
|---|---|
List<String> |
getCategories()
If categories are present for the xAxis, names are used instead of numbers for that axis.
|
XAxis |
setCategories(List<String> categories)
If categories are present for the xAxis, names are used instead of numbers for that axis.
|
set_hcNulledOptionpublic static final XAxis NULL
public List<String> getCategories()
If categories are present for the xAxis, names are used instead of numbers for that axis.
Since Highcharts 3.0, categories can also be extracted by giving each point a name and setting axis type to category. However, if you have multiple series, best practice remains defining the categories array.
Example: categories: ['Apples', 'Bananas', 'Oranges']
public XAxis setCategories(List<String> categories)
If categories are present for the xAxis, names are used instead of numbers for that axis.
Since Highcharts 3.0, categories can also be extracted by giving each point a name and setting axis type to category. However, if you have multiple series, best practice remains defining the categories array.
Example: categories: ['Apples', 'Bananas', 'Oranges']
categories - the value for the categories option.Copyright © 2026. All rights reserved.