Class PlotCategoryDataset

java.lang.Object
org.jfree.data.general.AbstractDataset
hudson.plugins.plot.PlotCategoryDataset
All Implemented Interfaces:
ObjectInputValidation, Serializable, Cloneable, org.jfree.data.category.CategoryDataset, org.jfree.data.general.Dataset, org.jfree.data.KeyedValues2D, org.jfree.data.Values2D

public class PlotCategoryDataset extends org.jfree.data.general.AbstractDataset implements org.jfree.data.category.CategoryDataset
A CategoryDataset implementation that stores numeric data points and corresponding URLs. This data structure is basically a table with row and column names (keys).
Author:
Nigel Daley
See Also:
  • Constructor Details

    • PlotCategoryDataset

      public PlotCategoryDataset()
      Creates a new empty instance.
  • Method Details

    • clipDataset

      public void clipDataset(int maxColumns)
      Truncates the dataset to the last maxColumns columns.
      Parameters:
      maxColumns - the maximum number columns that will appear to be in the dataset.
    • getRowCount

      public int getRowCount()
      Specified by:
      getRowCount in interface org.jfree.data.Values2D
    • getColumnCount

      public int getColumnCount()
      Specified by:
      getColumnCount in interface org.jfree.data.Values2D
    • getValue

      public Number getValue(int row, int column)
      Specified by:
      getValue in interface org.jfree.data.Values2D
    • getRowKey

      public Comparable getRowKey(int row)
      Specified by:
      getRowKey in interface org.jfree.data.KeyedValues2D
    • getRowIndex

      public int getRowIndex(Comparable key)
      Specified by:
      getRowIndex in interface org.jfree.data.KeyedValues2D
    • getRowKeys

      public List getRowKeys()
      Specified by:
      getRowKeys in interface org.jfree.data.KeyedValues2D
    • getColumnKey

      public Comparable getColumnKey(int column)
      Specified by:
      getColumnKey in interface org.jfree.data.KeyedValues2D
    • getColumnIndex

      public int getColumnIndex(Comparable key)
      Specified by:
      getColumnIndex in interface org.jfree.data.KeyedValues2D
    • getColumnKeys

      public List getColumnKeys()
      Specified by:
      getColumnKeys in interface org.jfree.data.KeyedValues2D
    • getValue

      public Number getValue(Comparable rowKey, Comparable columnKey)
      Gets the value with the given row and column keys.
      Specified by:
      getValue in interface org.jfree.data.KeyedValues2D
      Parameters:
      rowKey - the row key
      columnKey - the column key
      Returns:
      the value with the given row and column keys
    • getUrl

      public String getUrl(int row, int column)
      Returns the URL at the given row and column.
      Parameters:
      row - the row index
      column - the column index
      Returns:
      the URL
    • setValue

      public void setValue(Number value, String url, Comparable rowKey, Comparable columnKey)
      Adds or updates a value.
      Parameters:
      value - the value to add
      url - the URL to add and associate with the value
      rowKey - the row key
      columnKey - the column key