rwlogo
Rogue Wave Views 5.6

Rogue Wave Views
Charts Package API Reference Guide

Product Documentation:

Rogue Wave Views
Documentation Home

List of all members | Public Member Functions | Protected Member Functions
IlvAbstractChartFunction Class Reference

Class for data sets described by a function. More...

#include <ilviews/charts/data.h>

Inheritance diagram for IlvAbstractChartFunction:
IlvChartDataSet IlvCallbackChartFunction IlvScriptChartFunction

Public Member Functions

virtual IlUInt getDataCount () const
 Returns the number of defined data items. More...
 
IlDouble getXMax () const
 Returns the maximum value considered for the abscissa. More...
 
IlDouble getXMin () const
 Returns the minimum value considered for the abscissa. More...
 
virtual IlBoolean isFunctionDefined () const
 Indicates whether the function is defined. More...
 
virtual IlBoolean isIncreasingOnX () const
 Indicates whether the managed data has increasing abscissa values. More...
 
void setDataCount (IlUInt count)
 Sets the number of considered data points. More...
 
void setXMax (IlDouble max)
 Sets the maximum value considered for the abscissa. More...
 
void setXMin (IlDouble min)
 Sets the minimum value considered for the abscissa. More...
 
virtual void write (IlvOutputFile &file) const
 Writes the attributes of the current object in a file. More...
 
- Public Member Functions inherited from IlvChartDataSet
virtual ~IlvChartDataSet ()
 Destructor. More...
 
void addListener (IlvChartDataSetListener *listener)
 Adds a listener. More...
 
IlBoolean addPoint (const IlvDoublePoint &point, IlvChartDataPointInfo *pointInfo=0, IlBoolean copyPointInfo=IlFalse)
 Adds a represented data point (and its associated point information object if any). More...
 
IlBoolean areListenersEnabled () const
 Indicates whether the listeners are enabled. More...
 
virtual IlvChartDataSetcopy () const =0
 Virtual copy constructor. More...
 
virtual void dataAllPointsRemoved ()
 Performs the necessary updates when all data points are removed. More...
 
virtual void dataPointAdded (IlUInt position)
 Performs the necessary updates when a new data point is added. More...
 
virtual void dataPointChanged (IlUInt ptidx, IlBoolean beforeChange)
 Performs the necessary updates when a data point is changed. More...
 
virtual void dataPointRemoved (IlUInt ptidx)
 Performs the necessary updates when a data point is removed. More...
 
void enableListeners (IlBoolean b)
 Specifies whether the listeners should be enabled. More...
 
virtual void endBatch ()
 Specifies the end of a set of modifications. More...
 
IlUInt getAddMaxIdx () const
 Returns the maximum index of the data points that have been added between the first call of the startBatch method and the last call of the endBatch method. More...
 
IlUInt getAddMinIdx () const
 Returns the minimum index of the data points that have been added between the first call of the startBatch method and the last call of the endBatch method. More...
 
void getBoundingValues (IlvCoordInterval &xRange, IlvCoordInterval &yRange) const
 Returns the bounding values of the managed data. More...
 
IlvChartDataSetListener *const * getListeners (IlUInt &count) const
 Returns all the listeners. More...
 
IlUInt getMaxCount () const
 Returns the maximum number of data items that can be managed. More...
 
const char * getName () const
 Returns the name of the current data set. More...
 
virtual void getPoint (IlUInt i, IlvDoublePoint &point) const =0
 Returns a represented data point. More...
 
IlvChartDataPointInfogetPointInfo (IlUInt ptidx) const
 Returns the point information associated with a data item. More...
 
IlvPointInfoCollectiongetPointInfoCollection () const
 Returns the object used to manage the point information. More...
 
IlUInt getPointInfoCount () const
 Returns the number of defined point information items. More...
 
IlvDoublePointgetPoints (IlUInt &count) const
 Returns all the represented data points. More...
 
virtual IlvDoublePointgetPointsBetween (IlUInt indexMin, IlUInt indexMax, IlUInt &count) const
 Returns some of the data points represented by the current data set. More...
 
virtual IlvDoublePointgetPointsInRange (IlUInt &count, IlUInt *&dataPointIndexes, const IlvCoordInterval &xRange, const IlvCoordInterval &yRange, IlBoolean needContinuity) const
 Returns a range of data points represented by the current data set. More...
 
virtual const IlvCoordIntervalgetXRange () const
 Returns the abscissa bounding values of the managed data. More...
 
virtual const IlvCoordIntervalgetYRange () const
 Returns the ordinate bounding values of the managed data. More...
 
virtual IlBoolean insertPoint (const IlvDoublePoint &point, IlUInt ptidx, IlvChartDataPointInfo *pointInfo=0, IlBoolean copyPointInfo=IlFalse)
 Inserts a represented data point (and its associated point information object if any). More...
 
virtual IlBoolean insertPoints (IlUInt count, const IlvDoublePoint *points, IlUInt position=IlvLastPositionIndex, IlvChartDataPointInfo *const *pInfos=0, IlBoolean copyPointInfo=IlFalse)
 Inserts several represented data points (and their associated point information objects if any). More...
 
IlBoolean isLimited () const
 Indicates whether the number of managed data items is limited. More...
 
virtual IlBoolean isRemovalAllowed () const
 Indicates whether managed data can be removed. More...
 
virtual IlBoolean isWritable () const
 Indicates whether managed data can be modified. More...
 
void lock ()
 Locks the current IlvChartDataSet object. More...
 
void removeAllPointInfo ()
 Removes all the defined point information. More...
 
virtual void removeAllPoints ()
 Removes all the represented data points (and their associated point information objects if any). More...
 
IlvChartDataSetListenerremoveListener (IlvChartDataSetListener *l)
 Removes a listener. More...
 
void removeListeners ()
 Removes all the listeners.
 
virtual IlBoolean removePointAndInfo (IlUInt ptidx)
 Removes a represented data point (and its associated point information object if any). More...
 
IlBoolean removePointInfo (IlUInt ptidx)
 Removes the point information associated with a data item. More...
 
virtual void removePointsAndInfo ()
 Removes all the represented data points (and their associated point information objects if any). More...
 
IlvOutputFilesave (IlvOutputFile &file) const
 Writes a complete description of the current object in a file. More...
 
void setMaxCount (IlUInt maxCount)
 Sets the maximum number of managed data items. More...
 
void setName (const char *name)
 Sets the name of the current data set. More...
 
virtual IlBoolean setPoint (IlUInt ptidx, const IlvDoublePoint &point)
 Sets a represented data point. More...
 
IlBoolean setPointInfo (IlUInt ptidx, IlvChartDataPointInfo *pointInfo, IlBoolean copyPointInfo=IlFalse)
 Sets the point information associated with a data item. More...
 
void setPointInfoCollection (IlvPointInfoCollection *ptic)
 Sets the object used to manage the point information. More...
 
virtual void startBatch ()
 Specifies the beginning of a set of modifications. More...
 
void unLock ()
 Unlocks the current IlvChartDataSet object. More...
 

Protected Member Functions

 IlvAbstractChartFunction (const char *name=0, IlvPointInfoCollection *ptInfoCollection=0)
 Constructor. More...
 
 IlvAbstractChartFunction (const IlvCoordInterval &xRange, IlUInt count, const char *name=0, IlvPointInfoCollection *ptInfoCollection=0)
 Constructor. More...
 
 IlvAbstractChartFunction (IlvInputFile &file)
 Constructor. More...
 
 IlvAbstractChartFunction (const IlvAbstractChartFunction &dataSet)
 Constructor. More...
 
- Protected Member Functions inherited from IlvChartDataSet
 IlvChartDataSet (const char *name=0, IlvPointInfoCollection *pointInfoCollection=0)
 Constructor. More...
 
 IlvChartDataSet (const IlvChartDataSet &dataSet)
 Constructor. More...
 
 IlvChartDataSet (IlvInputFile &file)
 Constructor. More...
 
void computeBoundingValues ()
 Computes the bounding values of the managed data. More...
 
virtual void computeMinMaxValues (IlvCoordInterval &xRange, IlvCoordInterval &yRange) const
 Computes the abscissa and ordinate bounding values of the managed data. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from IlvChartDataSet
static IlvChartDataSetLoad (IlvInputFile &file)
 Reads a data set object from a file. More...
 

Detailed Description

Class for data sets described by a function.

Library: ilvcharts

This class is an abstract subclass of IlvChartDataSet for which the data points are described by a function of the type y = f(x).

The abscissa of the nth data point of this data set is obtained by the following formula:

x = ((_xMax - _xMin) / (_dataCount -1)) * i + _xMin,

where _xMin and _xMax are the minimum and the maximum values considered for the abscissa, and _dataCount is the number of considered data. The ordinate is equal to f(x).

Warning
[note] IlvAbstractChartFunction is an abstract class. Its constructors are defined as protected because it is not possible to create an instance of this class directly.
See Also
IlvChartDataSet, IlvCallbackChartFunction, IlvScriptChartFunction, IlvPointInfoCollection, IlvChartDataPointInfo.

Constructor & Destructor Documentation

IlvAbstractChartFunction::IlvAbstractChartFunction ( const char *  name = 0,
IlvPointInfoCollection ptInfoCollection = 0 
)
protected

Constructor.

Initializes a new IlvAbstractChartFunction object. By default, the data count is set to 0.

Parameters
nameIf not 0, this string becomes the name of the created data set. The name passed as a parameter is copied.
ptInfoCollectionThe object used to manage the point information for the created data set.
IlvAbstractChartFunction::IlvAbstractChartFunction ( const IlvCoordInterval xRange,
IlUInt  count,
const char *  name = 0,
IlvPointInfoCollection ptInfoCollection = 0 
)
protected

Constructor.

Initializes a new IlvAbstractChartFunction object.

Parameters
xRangeThe values interval considered for the abscissa.
countThe data count.
nameIf not 0, this string becomes the name of the created data set. The name passed as a parameter is copied.
ptInfoCollectionThe object used to manage the point information for the created data set.
IlvAbstractChartFunction::IlvAbstractChartFunction ( IlvInputFile file)
protected

Constructor.

Initializes a new IlvAbstractChartFunction object from the description read in the input file named file.

Parameters
fileThe file used to initialize the current data set.
IlvAbstractChartFunction::IlvAbstractChartFunction ( const IlvAbstractChartFunction dataSet)
protected

Constructor.

Initializes a new IlvAbstractChartFunction object as a copy of dataSet.

Parameters
dataSetThe data set used to initialize the current one.

Member Function Documentation

virtual IlUInt IlvAbstractChartFunction::getDataCount ( ) const
virtual

Returns the number of defined data items.

Returns
The number of data items (points or values) defined for the data set.

Implements IlvChartDataSet.

IlDouble IlvAbstractChartFunction::getXMax ( ) const

Returns the maximum value considered for the abscissa.

Returns
The maximum value considered for the abscissa.
Warning
[note] This value is used to compute the data points represented by the current data set.
IlDouble IlvAbstractChartFunction::getXMin ( ) const

Returns the minimum value considered for the abscissa.

Returns
The minimum value considered for the abscissa.
Warning
[note] This value is used to compute the data points represented by the current data set.
virtual IlBoolean IlvAbstractChartFunction::isFunctionDefined ( ) const
virtual

Indicates whether the function is defined.

Returns
IlFalse by default since the function is not defined at this level of the class hierarchy, but only in the derived classes.

Reimplemented in IlvCallbackChartFunction, and IlvScriptChartFunction.

virtual IlBoolean IlvAbstractChartFunction::isIncreasingOnX ( ) const
virtual

Indicates whether the managed data has increasing abscissa values.

Returns
IlTrue by default. The data has an increasing abscissa by definition since the data abscissa correspond to increasing values between the minimum and the maximum values considered for the abscissa.
See Also
IlvAbstractChartFunction::getXMin, IlvAbstractChartFunction::getXMax.

Reimplemented from IlvChartDataSet.

void IlvAbstractChartFunction::setDataCount ( IlUInt  count)

Sets the number of considered data points.

Parameters
countThe new number of data points that are considered for the data set.
void IlvAbstractChartFunction::setXMax ( IlDouble  max)

Sets the maximum value considered for the abscissa.

This value is used to compute the data points represented by the current data set.

Parameters
maxThe new maximum value considered for the abscissa.
void IlvAbstractChartFunction::setXMin ( IlDouble  min)

Sets the minimum value considered for the abscissa.

This value is used to compute the data points represented by the current data set.

Parameters
minThe new minimum value considered for the abscissa.
virtual void IlvAbstractChartFunction::write ( IlvOutputFile file) const
virtual

Writes the attributes of the current object in a file.

Called by the IlvChartDataSet::save method. This method can be overloaded in subclasses that define new attributes. The information written by the write method is read by the IO constructor, which takes an IlvInputFile as its only argument. Both this method and the IO constructor can be automatically declared by using the DeclareChartDataSetTypeInfo macro within the class declaration.

Parameters
fileThe file where the attributes of the current object are written.

Reimplemented from IlvChartDataSet.


© Copyright 2012, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.