org.nuiton.math.matrix.viewer.renderer.jfreechart
Class GraphMatrixNDDataset

java.lang.Object
  extended by org.jfree.data.general.AbstractDataset
      extended by org.jfree.data.general.AbstractSeriesDataset
          extended by org.nuiton.math.matrix.viewer.renderer.jfreechart.GraphMatrixNDDataset
All Implemented Interfaces:
ObjectInputValidation, Serializable, Cloneable, EventListener, org.jfree.data.category.CategoryDataset, org.jfree.data.general.Dataset, org.jfree.data.general.SeriesChangeListener, org.jfree.data.general.SeriesDataset, org.jfree.data.KeyedValues2D, org.jfree.data.Values2D

public class GraphMatrixNDDataset
extends org.jfree.data.general.AbstractSeriesDataset
implements org.jfree.data.category.CategoryDataset

GraphMatrixNDDataset. Created: Fri May 17 16:26:19 2002

Version:
$Revision: 310 $
Author:
See Also:
Serialized Form

Field Summary
protected  List<?> categories
          The categories.
protected  MatrixND mat
          Storage for the data.
protected  List<?> seriesNames
          The series names.
 
Constructor Summary
GraphMatrixNDDataset(List<?> seriesNames, List<?> categories, MatrixND mat)
          Constructs a GraphMatrixNDDataset, populates it with the matrix, and uses the supplied names for the series and the supplied objects for the categories.
GraphMatrixNDDataset(MatrixND mat)
           
 
Method Summary
protected  List<String> generateNames(int count, String prefix)
          Generates an array of names, by appending a space plus an integer (starting with 1) to the supplied prefix string.
 int getColumnCount()
           
 int getColumnIndex(Comparable key)
           
 Comparable getColumnKey(int column)
           
 List getColumnKeys()
           
 int getRowCount()
           
 int getRowIndex(Comparable key)
           
 Comparable getRowKey(int row)
           
 List getRowKeys()
           
 int getSeriesCount()
           
 Comparable getSeriesKey(int series)
           
 Number getValue(Comparable rowKey, Comparable columnKey)
           
 Number getValue(int row, int column)
           
 
Methods inherited from class org.jfree.data.general.AbstractSeriesDataset
indexOf, seriesChanged
 
Methods inherited from class org.jfree.data.general.AbstractDataset
addChangeListener, clone, fireDatasetChanged, getGroup, hasListener, notifyListeners, removeChangeListener, setGroup, validateObject
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jfree.data.general.Dataset
addChangeListener, getGroup, removeChangeListener, setGroup
 

Field Detail

seriesNames

protected List<?> seriesNames
The series names.


categories

protected List<?> categories
The categories.


mat

protected MatrixND mat
Storage for the data.

Constructor Detail

GraphMatrixNDDataset

public GraphMatrixNDDataset(MatrixND mat)

GraphMatrixNDDataset

public GraphMatrixNDDataset(List<?> seriesNames,
                            List<?> categories,
                            MatrixND mat)
Constructs a GraphMatrixNDDataset, populates it with the matrix, and uses the supplied names for the series and the supplied objects for the categories.

Parameters:
seriesNames - series names.
categories - categories.
mat - matrix.
Method Detail

generateNames

protected List<String> generateNames(int count,
                                     String prefix)
Generates an array of names, by appending a space plus an integer (starting with 1) to the supplied prefix string.

Parameters:
count - number of names required.
prefix - name prefix.

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 series)
Specified by:
getSeriesKey in interface org.jfree.data.general.SeriesDataset
Specified by:
getSeriesKey in class org.jfree.data.general.AbstractSeriesDataset

getColumnIndex

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

getColumnKey

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

getColumnKeys

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

getRowIndex

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

getRowKey

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

getRowKeys

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

getValue

public Number getValue(Comparable rowKey,
                       Comparable columnKey)
Specified by:
getValue in interface org.jfree.data.KeyedValues2D

getColumnCount

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

getRowCount

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

getValue

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


Copyright © 2004-2011 CodeLutin. All Rights Reserved.