rwlogo
Rogue Wave Views 5.6

Rogue Wave Views
Charts Package API Reference Guide

Product Documentation:

Rogue Wave Views
Documentation Home

IlvCoordinateTransformer Class Reference

Base class defining a transformation to be applied to a coordinate. More...

#include <ilviews/charts/common.h>

Inheritance diagram for IlvCoordinateTransformer:
IlvChartCoordinateTransformer IlvZoomCoordinateTransformer IlvAffineChartTransformer IlvSimpleChartTransformer

List of all members.

Public Member Functions

virtual ~IlvCoordinateTransformer ()
 Destructor.
virtual IlvCoordinateTransformercopy () const =0
 Virtual copy constructor.
const IlvCoordinateInfogetOwner () const
 Returns the coordinate information that owns the current object.
virtual IlBoolean inverseTransformInterval (IlvCoordInterval &itvl) const
 Applies the inverse transformation to an interval.
virtual IlBoolean inverseTransformPoints (IlUInt pointsCount, IlvDoublePoint *points) const
 Applies the inverse transformation to points.
virtual IlBoolean inverseTransformValue (IlDouble &val) const =0
 Applies the inverse transformation to a value.
virtual IlBoolean inverseTransformValues (IlUInt valuesCount, IlDouble *values) const
 Applies the inverse transformation to values.
IlvOutputFilesave (IlvOutputFile &file) const
 Writes a complete description of the current object in a file.
virtual IlBoolean transformInterval (IlvCoordInterval &itvl) const
 Applies a transformation to an interval.
virtual IlBoolean transformPoints (IlUInt pointsCount, IlvDoublePoint *points) const
 Applies a transformation to data points.
virtual IlBoolean transformValue (IlDouble &value) const =0
 Applies a transformation to a data value.
virtual IlBoolean transformValues (IlUInt valuesCount, IlDouble *values) const
 Applies a transformation to data values.
virtual IlBoolean validateInterval (IlvCoordInterval &interval) const
 Validates an interval.
virtual void write (IlvOutputFile &file) const
 Writes the attributes of the current object in a file.

Static Public Member Functions

static IlvCoordinateTransformerLoad (IlvInputFile &file)
 Reads a coordinate transformer object from a file.

Protected Member Functions

 IlvCoordinateTransformer (IlvInputFile &file)
 Constructor.
 IlvCoordinateTransformer (const IlvCoordinateTransformer &transfo)
 Constructor.
 IlvCoordinateTransformer ()
 Constructor.

Detailed Description

Base class defining a transformation to be applied to a coordinate.

Library: ilvcharts

This is an abstract class that allows you to specify a transformation that is applied to a given data coordinate (x, y, theta, or rho) represented by a scale. For example, by specifying the transformation to use, you can transform data values expressed in degrees Celsius to degrees Fahrenheit, thus displaying the values with a scale graduated in degrees Fahrenheit.

The IlvCoordinateTransformer object that is applied to a given coordinate is stored in a specific class named IlvCoordinateInfo. The IlvCoordinateInfo class stores all the information related to a given data coordinate which is represented by a scale. Therefore, we use the term "coordinate information" to describe every instance of the IlvCoordinateInfo class or one of its derived classes.

See also:
IlvChartCoordinateTransformer, IlvCoordinateInfo, IlvDoublePoint.

Constructor & Destructor Documentation

virtual IlvCoordinateTransformer::~IlvCoordinateTransformer (  )  [virtual]

Destructor.

The destructor sets the stored pointer to the coordinate information object that owns the current object to 0.

IlvCoordinateTransformer::IlvCoordinateTransformer (  )  [protected]

Constructor.

Initializes a new IlvCoordinateTransformer object.

IlvCoordinateTransformer::IlvCoordinateTransformer ( const IlvCoordinateTransformer transfo  )  [protected]

Constructor.

Initializes a new IlvCoordinateTransformer object which is a copy of transfo.

Parameters:
transfo The object used to initialize the current one.
IlvCoordinateTransformer::IlvCoordinateTransformer ( IlvInputFile file  )  [protected]

Constructor.

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

Parameters:
file The file used to initialize the current object.

Member Function Documentation

virtual IlvCoordinateTransformer* IlvCoordinateTransformer::copy (  )  const [pure virtual]

Virtual copy constructor.

Creates and returns a copy of the current object. This method must be overloaded in subclasses. It is automatically declared by the DeclareCoordinateTransformerTypeInfo macro. The IlvPredefinedCoordinateTransformerIOMembers macro lets you define a default implementation, which returns an instance initialized with the copy constructor.

Returns:
A copy of the current object.

Implemented in IlvZoomCoordinateTransformer.

const IlvCoordinateInfo* IlvCoordinateTransformer::getOwner (  )  const

Returns the coordinate information that owns the current object.

Returns:
A pointer to the coordinate information object that owns the current object.
virtual IlBoolean IlvCoordinateTransformer::inverseTransformInterval ( IlvCoordInterval itvl  )  const [virtual]

Applies the inverse transformation to an interval.

Parameters:
itvl This parameter stores the interval to transform inversely and is also used to return the interval once it has been inversely transformed.
Returns:
IlTrue if the inverse transformation has been successfully applied and IlFalse otherwise.
virtual IlBoolean IlvCoordinateTransformer::inverseTransformPoints ( IlUInt  pointsCount,
IlvDoublePoint points 
) const [virtual]

Applies the inverse transformation to points.

Parameters:
pointsCount The number of points to which the inverse transformation is applied.
points This parameter stores the points to transform inversely and is also used to return the points once they have been inversely transformed.
Returns:
IlTrue if the inverse transformation has been successfully applied and IlFalse otherwise.
Warning:
[note] The inverse transformation is applied only to one coordinate of the points since the transformation is defined for one coordinate (x, y, theta, or rho) represented by a given scale.

Reimplemented in IlvChartCoordinateTransformer, and IlvZoomCoordinateTransformer.

virtual IlBoolean IlvCoordinateTransformer::inverseTransformValue ( IlDouble val  )  const [pure virtual]

Applies the inverse transformation to a value.

Parameters:
val This parameter stores the value to transform inversely and is also used to return the value once it has been inversely transformed.
Returns:
IlTrue if the inverse transformation has been successfully applied and IlFalse otherwise.

Implemented in IlvChartCoordinateTransformer, and IlvZoomCoordinateTransformer.

virtual IlBoolean IlvCoordinateTransformer::inverseTransformValues ( IlUInt  valuesCount,
IlDouble values 
) const [virtual]

Applies the inverse transformation to values.

Parameters:
valuesCount The number of values to which the inverse transformation is applied.
values This parameter stores the values to transform inversely and is also used to return the values once they have been inversely transformed.
Returns:
IlTrue if the inverse transformation has been successfully applied and IlFalse otherwise.

Reimplemented in IlvChartCoordinateTransformer.

static IlvCoordinateTransformer* IlvCoordinateTransformer::Load ( IlvInputFile file  )  [static]

Reads a coordinate transformer object from a file.

Creates a coordinate transformer instance from the description stored in the file file. The object description must have been written with the IlvCoordinateTransformer::save method.

Parameters:
file The file where the object description is stored.
Returns:
A pointer to the created object.
IlvOutputFile& IlvCoordinateTransformer::save ( IlvOutputFile file  )  const

Writes a complete description of the current object in a file.

Writes the complete object description in a file. This description contains all the information necessary to read back this object with the IlvCoordinateTransformer::Load member function. This method first writes information regarding the type of the object and calls the IlvCoordinateTransformer::write method.

Parameters:
file The file where the complete object description is written.
virtual IlBoolean IlvCoordinateTransformer::transformInterval ( IlvCoordInterval itvl  )  const [virtual]

Applies a transformation to an interval.

Parameters:
itvl This parameter stores the interval to transform and is also used to return the interval once it has been transformed.
Returns:
IlTrue if the transformation has been successfully applied and IlFalse otherwise.
virtual IlBoolean IlvCoordinateTransformer::transformPoints ( IlUInt  pointsCount,
IlvDoublePoint points 
) const [virtual]

Applies a transformation to data points.

Parameters:
pointsCount The number of points to which the transformation is applied.
points This parameter stores the points to transform and is also used to return the transformed points.
Returns:
IlTrue if the transformation has been successfully applied and IlFalse otherwise.
Warning:
[note] The transformation is applied only to one coordinate of the points, since the transformation is defined for one coordinate (x, y, theta or rho) represented by a given scale.

Reimplemented in IlvChartCoordinateTransformer, and IlvZoomCoordinateTransformer.

virtual IlBoolean IlvCoordinateTransformer::transformValue ( IlDouble value  )  const [pure virtual]

Applies a transformation to a data value.

Parameters:
value This parameter stores the value to transform and is also used to return the transformed value.
Returns:
IlTrue if the transformation has been successfully applied and IlFalse otherwise.

Implemented in IlvChartCoordinateTransformer, and IlvZoomCoordinateTransformer.

virtual IlBoolean IlvCoordinateTransformer::transformValues ( IlUInt  valuesCount,
IlDouble values 
) const [virtual]

Applies a transformation to data values.

Parameters:
valuesCount The number of values to which the transformation is applied.
values This parameter stores the values to transform and is also used to return the transformed values.
Returns:
IlTrue if the transformation has been successfully applied and IlFalse otherwise.

Reimplemented in IlvChartCoordinateTransformer.

virtual IlBoolean IlvCoordinateTransformer::validateInterval ( IlvCoordInterval interval  )  const [virtual]

Validates an interval.

Changes the interval interval so that it becomes consistent with the definition domain of the transformer. The default implementation does nothing and returns IlFalse, which indicates that the interval has not been modified.

Parameters:
interval The interval to validate.
Returns:
A Boolean value indicating whether the interval has been modified.

Reimplemented in IlvChartCoordinateTransformer, and IlvZoomCoordinateTransformer.

virtual void IlvCoordinateTransformer::write ( IlvOutputFile file  )  const [virtual]

Writes the attributes of the current object in a file.

Called by the IlvCoordinateTransformer::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 DeclareCoordinateTransformerTypeInfo macro within the class declaration.

Parameters:
file The file where the attributes of the current object are written.

Reimplemented in IlvChartCoordinateTransformer, and IlvZoomCoordinateTransformer.

 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

© 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.