JClass DesktopViews 6.3.0 API
Documentation

com.klg.jclass.chart.data
Class JCEditableDataSource

java.lang.Object
  |
  +--com.klg.jclass.chart.ChartDataSupport
        |
        +--com.klg.jclass.chart.data.BaseDataSource
              |
              +--com.klg.jclass.chart.data.JCDefaultDataSource
                    |
                    +--com.klg.jclass.chart.data.JCEditableDataSource
All Implemented Interfaces:
ChartDataManageable, ChartDataManager, ChartDataModel, EditableChartDataModel, HoleValueChartDataModel, com.klg.jclass.chart.ImageMapChartDataModel, LabelledChartDataModel, Serializable

public class JCEditableDataSource
extends JCDefaultDataSource
implements EditableChartDataModel

A quick and easy default editable data source. It inherits the vast majority of it's behavior from JCDefaultDataSource. It implements the EditableChartDataModel interface to update the Y-values array with the edited value.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.klg.jclass.chart.data.JCDefaultDataSource
defaultY, suppressMultipleGeneration
 
Fields inherited from class com.klg.jclass.chart.data.BaseDataSource
cloneArrays, clusterImageMapInfo, holeValue, legendImageMapInfo, name, pointImageMapInfo, pointLabels, seriesImageMapInfo, seriesLabels, xvalues, yvalues
 
Fields inherited from class com.klg.jclass.chart.ChartDataSupport
source
 
Fields inherited from interface com.klg.jclass.chart.ChartDataModel
ALL
 
Constructor Summary
JCEditableDataSource()
          The default constructor.
JCEditableDataSource(double[][] xvalues, double[][] yvalues, String[] pointLabels, String[] seriesLabels, String dataSourceName)
          Creates a data source using the provided data.
JCEditableDataSource(double[][] xvalues, double[][] yvalues, String[] pointLabels, String[] seriesLabels, String dataSourceName, com.klg.jclass.util.ImageMapInfo[][] pointImageMapInfo, com.klg.jclass.util.ImageMapInfo[] clusterImageMapInfo, com.klg.jclass.util.ImageMapInfo[] seriesImageMapInfo, com.klg.jclass.util.ImageMapInfo[] legendImageMapInfo)
          Creates a data source using the provided data.
JCEditableDataSource(Locale locale)
          The default constructor specifying a locale.
 
Method Summary
 boolean setDataItem(int seriesIndex, int pointIndex, double newValue)
          Changes the specified Y data value.
 
Methods inherited from class com.klg.jclass.chart.data.JCDefaultDataSource
buildDataSourceString, check, generateLabels, generateLabels, setClusterImageMapInfo, setClusterImageMapInfo, setData, setLegendImageMapInfo, setLegendImageMapInfo, setName, setPointImageMapInfo, setPointImageMapInfo, setPointImageMapInfo, setPointImageMapInfo, setPointLabels, setSeriesImageMapInfo, setSeriesImageMapInfo, setSeriesLabels, setXSeries, setYSeries, updateChart
 
Methods inherited from class com.klg.jclass.chart.data.BaseDataSource
cloneCheck, cloneCheck, cloneCheck, getChartDataManager, getCloneArrays, getClusterImageMapInfo, getDataSourceName, getHoleValue, getLegendImageMapInfo, getNumSeries, getPointImageMapInfo, getPointLabels, getSeriesImageMapInfo, getSeriesLabels, getXSeries, getYSeries, setCloneArrays
 
Methods inherited from class com.klg.jclass.chart.ChartDataSupport
addChartDataListener, fireChartDataEvent, fireChartDataEvent, removeChartDataListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.klg.jclass.chart.ChartDataModel
getNumSeries, getXSeries, getYSeries
 

Constructor Detail

JCEditableDataSource

public JCEditableDataSource()
The default constructor. Used mostly for the DataSourceEditor.


JCEditableDataSource

public JCEditableDataSource(Locale locale)
The default constructor specifying a locale.


JCEditableDataSource

public JCEditableDataSource(double[][] xvalues,
                            double[][] yvalues,
                            String[] pointLabels,
                            String[] seriesLabels,
                            String dataSourceName)
Creates a data source using the provided data.

Parameters:
xvalues - X series arrays; can be null
yvalues - Y series arrays; can be null
pointLabels - array of point labels; can be null
seriesLabels - array of series labels; can be null
dataSourceName - name applied to this data source

JCEditableDataSource

public JCEditableDataSource(double[][] xvalues,
                            double[][] yvalues,
                            String[] pointLabels,
                            String[] seriesLabels,
                            String dataSourceName,
                            com.klg.jclass.util.ImageMapInfo[][] pointImageMapInfo,
                            com.klg.jclass.util.ImageMapInfo[] clusterImageMapInfo,
                            com.klg.jclass.util.ImageMapInfo[] seriesImageMapInfo,
                            com.klg.jclass.util.ImageMapInfo[] legendImageMapInfo)
Creates a data source using the provided data.

Parameters:
xvalues - X series arrays; can be null
yvalues - Y series arrays; can be null
pointLabels - array of point labels; can be null
seriesLabels - array of series labels; can be null
dataSourceName - name to be applied to this data source
pointImageMapInfo - An array of image map information, indexed by series and point.
clusterImageMapInfo - An array of image map information, one for each point cluster.
seriesImageMapInfo - An array of image map information, one for each series.
legendImageMapInfo - An array of legend image map information, one for each series.
Method Detail

setDataItem

public boolean setDataItem(int seriesIndex,
                           int pointIndex,
                           double newValue)
Changes the specified Y data value.

Specified by:
setDataItem in interface EditableChartDataModel
Parameters:
seriesIndex - series index for the changed point
pointIndex - point index for the changed point
newValue - new y value for the specified point
Returns:
boolean value indicating whether the new value was accepted; true means the value was accepted

Copyright © 2004 Quest Software Inc..
All rights reserved.