Class PieChart

Object
ObjectIdentity
AbstractBuilder
All Implemented Interfaces:
CanDrillDown, Portlet, Portlet

public class PieChart extends AbstractChartBuilder<PieChart> implements CanDrillDown
Builder for a Pie Chart, obtained via ChartBuilder.newPie() rather than instantiated directly. See that factory method for this chart's category/size shape (no X or Y axis) and a Groovy example.

Methods of this class are mostly self-explanatory or equivalent to the Highcharts methods described at HighCharts.Chart.

See Also:
  • Constructor Details

    • PieChart

      public PieChart(IdGenerator idGenerator, Invocations<MethodInvocation> invocations)
  • Method Details

    • addSeries

      public PieChart.PieSeries addSeries()
      Adds a new series to this chart.
      Returns:
      a new PieChart.PieSeries for this chart. Never null.
    • getOptions

      public PieChart.PieOptions getOptions()
      Description copied from class: AbstractChartBuilder
      Returns this chart's Options builder. Each concrete chart type declares its own Options subclass (for example ScatterChart.ScatterOptions, BarLineChart.BarLineOptions) exposing the settings that apply to that chart type, such as title, subtitle, and axis label and bound overrides; the exact set of available options differs per chart type, which is why this method is declared abstract here rather than implemented once for every chart.
      Specified by:
      getOptions in class AbstractChartBuilder<PieChart>
      Returns:
      this chart's type-specific AbstractChartOptions instance. Never null.
    • addAuxLine

      @Deprecated public AuxLine<PieChart> addAuxLine()
      Deprecated.
      since 17.1 - Pie charts do not support reference lines; this method should never have been exposed on PieChart and calling it does not add a line to the rendered chart. There is no replacement.
      Adds a reference line to this chart.
      Overrides:
      addAuxLine in class AbstractChartBuilder<PieChart>
      Returns:
      a new AuxLine builder for this chart. Never null.
    • build

      public ChartBuilderResult build()
      Finishes this chart's definition. The returned object is what Dashboard portlets, Quote headers, and other Data Analyzer areas render.
      Specified by:
      build in class AbstractBuilder
      Returns:
      the finished chart definition. Never null.