Class IntervalDataSetCollectionWrapper<T extends XYDataSeriesInternal>

java.lang.Object
org.jfree.data.general.AbstractDataset
org.jfree.data.general.AbstractSeriesDataset
com.illumon.iris.db.plot.datasets.interval.IntervalDataSetCollectionWrapper<T>
All Implemented Interfaces:
DataSetCollection<T>, LabeledDataSetCollection, PlotExceptionCause, DataChangeListener, ObjectInputValidation, Serializable, Cloneable, EventListener, org.jfree.data.general.Dataset, org.jfree.data.general.SeriesChangeListener, org.jfree.data.general.SeriesDataset, org.jfree.data.xy.IntervalXYDataset, org.jfree.data.xy.XYDataset
Direct Known Subclasses:
IntervalAndTableXYDataSetCollectionWrapper, IntervalDataSetCollectionWrapper.IntervalDataSetCollectionWrapperSnapshot

public class IntervalDataSetCollectionWrapper<T extends XYDataSeriesInternal> extends org.jfree.data.general.AbstractSeriesDataset implements org.jfree.data.xy.XYDataset, DataSetCollection<T>, LabeledDataSetCollection, org.jfree.data.xy.IntervalXYDataset, Serializable
Collection of IntervalXYDataSeriesInternal. Data values are placed in the middle of the bar. Bar width is based off the smallest difference between adjacent data points.
See Also:
  • Constructor Details

    • IntervalDataSetCollectionWrapper

      public IntervalDataSetCollectionWrapper(LambdaGovernor governor, XYDataSetCollection<T> data, boolean notifyDataChanged)
      Creates an instance of IntervalDataSetCollectionWrapper. Calculates a dataset suitable for bar charts from an XYDataSetCollection.
      Parameters:
      governor - update throttle
      data - data
      notifyDataChanged - whether to fire dataset changed events
  • Method Details

    • getGovernor

      protected LambdaGovernor getGovernor()
    • axes

      public AxesImpl axes()
      Specified by:
      axes in interface DataSetCollection<T extends XYDataSeriesInternal>
      Returns:
      the axes of this dataset collection
    • getLabel

      public String getLabel(int series, int item)
      Description copied from interface: LabeledDataSetCollection
      Gets the label for a data point.
      Specified by:
      getLabel in interface LabeledDataSetCollection
      Parameters:
      series - series index
      item - data point index inside specified series
      Returns:
      label for specified data point
    • series

      public Collection<T> series()
      Specified by:
      series in interface DataSetCollection<T extends XYDataSeriesInternal>
      Returns:
      the series (not including the MultiSeries) in this collection
    • multiSeries

      public Collection<MultiSeriesInternal<T>> multiSeries()
      Specified by:
      multiSeries in interface DataSetCollection<T extends XYDataSeriesInternal>
    • add

      public void add(T series)
      Description copied from interface: DataSetCollection
      Adds a series to this collection.
      Specified by:
      add in interface DataSetCollection<T extends XYDataSeriesInternal>
      Parameters:
      series - series
    • add

      public void add(MultiSeriesInternal<T> series)
      Specified by:
      add in interface DataSetCollection<T extends XYDataSeriesInternal>
    • remove

      public Set<? extends SeriesInternal> remove(String... names)
      Description copied from interface: DataSetCollection
      Removes the series with the specified names from this collection.
      Specified by:
      remove in interface DataSetCollection<T extends XYDataSeriesInternal>
      Parameters:
      names - series names
    • dimension

      public int dimension()
      Description copied from interface: DataSetCollection
      Gets the dimension of this data set.
      Specified by:
      dimension in interface DataSetCollection<T extends XYDataSeriesInternal>
      Returns:
      dimension of this data set
    • getAllSeries

      public List<T> getAllSeries()
      Specified by:
      getAllSeries in interface DataSetCollection<T extends XYDataSeriesInternal>
      Returns:
      all series from this collection
    • constructSnapshot

      public void constructSnapshot()
      Description copied from interface: DataSetCollection
      Constructs a snapshot of this dataset collection.
      Specified by:
      constructSnapshot in interface DataSetCollection<T extends XYDataSeriesInternal>
    • id

      public int id()
      Description copied from interface: DataSetCollection
      Gets the id of this datasetcollection which is same as the id of the Axes instance it is associated with
      Specified by:
      id in interface DataSetCollection<T extends XYDataSeriesInternal>
      Returns:
      - id of the datasetcollection
    • getCurrentSnapshot

      public IntervalDataSetCollectionWrapper getCurrentSnapshot()
      Description copied from interface: DataSetCollection
      Returns a snapshot of this dataset collection in which no series which will update.
      Specified by:
      getCurrentSnapshot in interface DataSetCollection<T extends XYDataSeriesInternal>
    • notifyDataChanged

      public void notifyDataChanged()
      Description copied from interface: DataChangeListener
      Notifies this listener that the underlying data has changed.
      Specified by:
      notifyDataChanged in interface DataChangeListener
    • notifyDataChanged

      public void notifyDataChanged(RunnableFuture callback)
      Description copied from interface: DataChangeListener
      Notifies this listener that the underlying data has changed.
      Specified by:
      notifyDataChanged in interface DataChangeListener
      Parameters:
      callback - to call once done
    • notifySeriesChanged

      public void notifySeriesChanged(boolean seriesChanged)
      Description copied from interface: DataChangeListener
      Notifies this listener that the underlying data has a new series.
      Specified by:
      notifySeriesChanged in interface DataChangeListener
      Parameters:
      seriesChanged - whether the series change is additive
    • getSeriesCount

      public int getSeriesCount()
      Specified by:
      getSeriesCount in interface org.jfree.data.general.SeriesDataset
      Specified by:
      getSeriesCount in class org.jfree.data.general.AbstractSeriesDataset
    • getSeriesKey

      public Comparable getSeriesKey(int i)
      Specified by:
      getSeriesKey in interface org.jfree.data.general.SeriesDataset
      Specified by:
      getSeriesKey in class org.jfree.data.general.AbstractSeriesDataset
    • get

      public Integer get(Comparable seriesName)
      Description copied from interface: DataSetCollection
      Returns index of the series, -1 if its not found
      Specified by:
      get in interface DataSetCollection<T extends XYDataSeriesInternal>
      Parameters:
      seriesName - name of the series
      Returns:
      index of the series
    • getStartX

      public Number getStartX(int i, int i1)
      Specified by:
      getStartX in interface org.jfree.data.xy.IntervalXYDataset
    • getStartXValue

      public double getStartXValue(int i, int i1)
      Specified by:
      getStartXValue in interface org.jfree.data.xy.IntervalXYDataset
    • getEndX

      public Number getEndX(int i, int i1)
      Specified by:
      getEndX in interface org.jfree.data.xy.IntervalXYDataset
    • getEndXValue

      public double getEndXValue(int i, int i1)
      Specified by:
      getEndXValue in interface org.jfree.data.xy.IntervalXYDataset
    • getStartY

      public Number getStartY(int i, int i1)
      Specified by:
      getStartY in interface org.jfree.data.xy.IntervalXYDataset
    • getStartYValue

      public double getStartYValue(int i, int i1)
      Specified by:
      getStartYValue in interface org.jfree.data.xy.IntervalXYDataset
    • getEndY

      public Number getEndY(int i, int i1)
      Specified by:
      getEndY in interface org.jfree.data.xy.IntervalXYDataset
    • getEndYValue

      public double getEndYValue(int i, int i1)
      Specified by:
      getEndYValue in interface org.jfree.data.xy.IntervalXYDataset
    • getDomainOrder

      public org.jfree.data.DomainOrder getDomainOrder()
      Specified by:
      getDomainOrder in interface org.jfree.data.xy.XYDataset
    • getItemCount

      public int getItemCount(int i)
      Specified by:
      getItemCount in interface org.jfree.data.xy.XYDataset
    • getX

      public Number getX(int i, int i1)
      Specified by:
      getX in interface org.jfree.data.xy.XYDataset
    • getXValue

      public double getXValue(int i, int i1)
      Specified by:
      getXValue in interface org.jfree.data.xy.XYDataset
    • getY

      public Number getY(int i, int i1)
      Specified by:
      getY in interface org.jfree.data.xy.XYDataset
    • getYValue

      public double getYValue(int i, int i1)
      Specified by:
      getYValue in interface org.jfree.data.xy.XYDataset
    • addFireDatasetChangeListener

      public void addFireDatasetChangeListener(AbstractDataSetCollection.FireDatasetChangeListener listener)
    • fireDatasetChanged

      protected void fireDatasetChanged()
      Overrides:
      fireDatasetChanged in class org.jfree.data.general.AbstractDataset
    • calculateXRangeWithBars

      public org.jfree.data.Range calculateXRangeWithBars()
    • getPlotInfo

      public PlotInfo getPlotInfo()
      Specified by:
      getPlotInfo in interface PlotExceptionCause