JClass DesktopViews 6.3.0 API
Documentation

com.klg.jclass.chart3d.data
Class JCEditable3dGridDataSource

java.lang.Object
  |
  +--com.klg.jclass.chart3d.event.Chart3dDataSupport
        |
        +--com.klg.jclass.chart3d.data.Base3dDataSource
              |
              +--com.klg.jclass.chart3d.data.Base3dGridDataSource
                    |
                    +--com.klg.jclass.chart3d.data.JCDefault3dGridDataSource
                          |
                          +--com.klg.jclass.chart3d.data.JCEditable3dGridDataSource
All Implemented Interfaces:
Chart3dDataManager, Chart3dDataModel, Chart3dGridDataModel, Cloneable, EditableChart3dDataModel, HoleValueChart3dDataModel, LabelledChart3dDataModel, LabelledChart3dGridDataModel, Serializable
Direct Known Subclasses:
JCSwing3dDataSource

public class JCEditable3dGridDataSource
extends JCDefault3dGridDataSource
implements EditableChart3dDataModel

Extension to JCDefault3dGridDataSource with convenience methods that permit editing of data.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.klg.jclass.chart3d.data.Base3dGridDataSource
chartDataListeners, dataSourceName, xGrid, xLabels, yGrid, yLabels, zValues
 
Fields inherited from class com.klg.jclass.chart3d.data.Base3dDataSource
holeValue
 
Fields inherited from class com.klg.jclass.chart3d.event.Chart3dDataSupport
source
 
Fields inherited from interface com.klg.jclass.chart3d.HoleValueChart3dDataModel
DEFAULT_HOLE_VALUE
 
Constructor Summary
JCEditable3dGridDataSource()
          No argument constructor which sets all params to null.
JCEditable3dGridDataSource(String name, double[] xGrid, double[] yGrid, double[][] zValues)
          Constructor that creates a populated JCEditable3dGridDataSource.
 
Method Summary
 double getZValue(int xIndex, int yIndex)
          Retrieves the specified point value, given series and point indices.
 double getZValue(com.klg.jclass.chart3d.JCData3dIndex index)
          Retrieves the zValue based on the JCData3dIndex object.
 boolean setZValue(int xIndex, int yIndex, double newValue)
          Sets the value for a location given the x and y indices.
 boolean setZValue(com.klg.jclass.chart3d.JCData3dIndex index, double newValue)
          Sets the point for a given data index which must be of type JCData3dGridIndex.
 
Methods inherited from class com.klg.jclass.chart3d.data.JCDefault3dGridDataSource
getXGridSize, getYGridSize, getZArray, setZArray
 
Methods inherited from class com.klg.jclass.chart3d.data.Base3dGridDataSource
clone, getDataSourceName, getNumX, getNumY, getXGrid, getXLabels, getYGrid, getYLabels, getZValues, setDataSourceName, setXGrid, setXLabels, setYGrid, setYLabels, setZValues
 
Methods inherited from class com.klg.jclass.chart3d.data.Base3dDataSource
getHoleValue, setHoleValue
 
Methods inherited from class com.klg.jclass.chart3d.event.Chart3dDataSupport
addChart3dDataListener, fireChart3dDataEvent, fireChart3dDataEvent, removeChart3dDataListener
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JCEditable3dGridDataSource

public JCEditable3dGridDataSource()
No argument constructor which sets all params to null.


JCEditable3dGridDataSource

public JCEditable3dGridDataSource(String name,
                                  double[] xGrid,
                                  double[] yGrid,
                                  double[][] zValues)
Constructor that creates a populated JCEditable3dGridDataSource.

Parameters:
name - String name of the datasource
xGrid - array of doubles which holds the X values
yGrid - array of doubles which holds the Y values
zValues - two-dimensional array of doubles holds the Z values
Method Detail

getZValue

public double getZValue(int xIndex,
                        int yIndex)
Retrieves the specified point value, given series and point indices.

Parameters:
xIndex - int indicating which series contains the point
yIndex - int indicating where in the series the point is
Returns:
the value of that point as a double

getZValue

public double getZValue(com.klg.jclass.chart3d.JCData3dIndex index)
Retrieves the zValue based on the JCData3dIndex object.

Parameters:
index - a JCData3dGridIndex object
Returns:
the double value at that location

setZValue

public boolean setZValue(com.klg.jclass.chart3d.JCData3dIndex index,
                         double newValue)
Sets the point for a given data index which must be of type JCData3dGridIndex.

Specified by:
setZValue in interface EditableChart3dDataModel
Parameters:
index - the data index from which the x and y indices of the point to be edited is obtained
newValue - the new z value for the point
Returns:
whether the edit succeeded

setZValue

public boolean setZValue(int xIndex,
                         int yIndex,
                         double newValue)
Sets the value for a location given the x and y indices.

Parameters:
xIndex - the X location
yIndex - the Y location
newValue - the new z value for the point
Returns:
whether the edit succeeded

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