Class PieChartGenerator

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible
Direct Known Subclasses:
BarChartGenerator

public class PieChartGenerator extends ChartGenerator
A ChartGenerator for Pie Charts.
See Also:
  • Field Details

    • MAXIMUM_PIE_CHART_ITEMS

      public static final int MAXIMUM_PIE_CHART_ITEMS
      The total number of unique groups permitted in the generator, to keep from overwhelming JFreeChart.
      See Also:
  • Constructor Details

    • PieChartGenerator

      public PieChartGenerator()
  • Method Details

    • removeSeries

      public void removeSeries(int index)
      Description copied from class: ChartGenerator
      Override this to remove a series from the chart. Be sure to call super(...) first.
      Overrides:
      removeSeries in class ChartGenerator
    • moveSeries

      public void moveSeries(int index, boolean up)
      Description copied from class: ChartGenerator
      Override this to move a series relative to other series. Be sure to call super(...) first.
      Overrides:
      moveSeries in class ChartGenerator
    • getSeriesDataset

      public org.jfree.data.general.Dataset getSeriesDataset()
      Specified by:
      getSeriesDataset in class ChartGenerator
    • setSeriesDataset

      public void setSeriesDataset(org.jfree.data.general.Dataset obj)
      Specified by:
      setSeriesDataset in class ChartGenerator
    • getProspectiveSeriesCount

      public int getProspectiveSeriesCount(Object[] objs)
    • getSeriesCount

      public int getSeriesCount()
      Specified by:
      getSeriesCount in class ChartGenerator
    • buildChart

      protected void buildChart()
      Description copied from class: ChartGenerator
      Override this to construct the appropriate kind of chart. This is the first thing called from the constructor; so certain of your instance variables may not have been set yet and you may need to set them yourself. You'll need to set the dataset.
      Specified by:
      buildChart in class ChartGenerator
    • update

      protected void update()
      Overrides:
      update in class ChartGenerator
    • buildNewAttributes

      protected PieChartSeriesAttributes buildNewAttributes(String name, org.jfree.data.general.SeriesChangeListener stopper)
    • addSeries

      public SeriesAttributes addSeries(double[] amounts, String[] labels, String name, org.jfree.data.general.SeriesChangeListener stopper)
      Adds a series, plus a (possibly null) SeriesChangeListener which will receive a single event if/when the series is deleted from the chart by the user. Returns the series attributes.
    • addSeries

      public SeriesAttributes addSeries(Object[] objs, String name, org.jfree.data.general.SeriesChangeListener stopper)
      Adds a series, plus a (possibly null) SeriesChangeListener which will receive a single event if/when the series is deleted from the chart by the user. Returns the series attributes.
    • addSeries

      public SeriesAttributes addSeries(Collection objs, String name, org.jfree.data.general.SeriesChangeListener stopper)
      Adds a series, plus a (possibly null) SeriesChangeListener which will receive a single event if/when the series is deleted from the chart by the user. Returns the series attributes.
    • updateSeries

      public void updateSeries(int index, Collection objs)
    • updateSeries

      public void updateSeries(int index, Object[] objs)
    • updateSeries

      public void updateSeries(int index, double[] amounts, String[] labels)