Public Types | Public Member Functions

Mapping Class Reference
[mapping - classes representing mathematical mappings]

Represents a changeable mapping (mathematical function) from at least time to double. More...

#include <MappingBase.h>

Inherits ConstMapping.

Inherited by BaseDelayedMapping< Mapping >, ConstMappingWrapper, LinearIntplMapping, MultiDimMapping< Interpolator >, MultiDimMapping< Linear >, TimeMapping< Interpolator >, and TimeMapping< Linear >.

Collaboration diagram for Mapping:
Collaboration graph
[legend]

List of all members.

Public Types

enum  InterpolationMethod { STEPS, NEAREST, LINEAR }
 

Types of interpolation methods for mappings.

More...

Public Member Functions

 Mapping (const DimensionSet &dims)
 Initializes the Mapping with the passed DimensionSet as domain.
 Mapping ()
 Initializes the Mapping with the time dimension as domain.
virtual void setValue (const Argument &pos, double value)=0
 Changes the value of the Mapping at the specified position.
virtual void appendValue (const Argument &pos, double value)
 Appends the passed value at the passed position to the mapping. This method assumes that the passed position is after the last key entry of the mapping.
virtual MappingIteratorcreateIterator ()=0
 Returns a pointer of a new Iterator which is able to iterate over the Mapping and can change it.
virtual MappingIteratorcreateIterator (const Argument &pos)=0
 Returns a pointer of a new Iterator which is able to iterate over the function and can change it.
virtual ConstMappingIteratorcreateConstIterator ()
 Returns an ConstMappingIterator by use of the respective implementation of the "createIterator()"-method.
virtual ConstMappingIteratorcreateConstIterator (const Argument &pos)
 Returns an ConstMappingIterator by use of the respective implementation of the "createIterator()"-method.
virtual Mappingclone () const =0
 Returns a deep copy of this Mapping.
virtual ConstMappingconstClone () const
 Returns a deep const copy of this mapping by using the according "clone()"-implementation.

Detailed Description

Represents a changeable mapping (mathematical function) from at least time to double.

This class extends the ConstMapping interface with write access.

See ConstMapping for details.

Author:
Karl Wessel

Definition at line 874 of file MappingBase.h.


Member Enumeration Documentation

Types of interpolation methods for mappings.

Enumerator:
STEPS 

interpolates with next lower entry

NEAREST 

interpolates with nearest entry

LINEAR 

interpolates linear with next lower and next upper entry constant before the first and after the last entry

Definition at line 877 of file MappingBase.h.

                           {
    STEPS,
    NEAREST,
    LINEAR
  };


Constructor & Destructor Documentation

Mapping::Mapping ( const DimensionSet dims  )  [inline]

Initializes the Mapping with the passed DimensionSet as domain.

The passed DimensionSet has to contain the time dimension!

Definition at line 896 of file MappingBase.h.

                                   :
    ConstMapping(dims) {}


Member Function Documentation

virtual void Mapping::appendValue ( const Argument pos,
double  value 
) [inline, virtual]

Appends the passed value at the passed position to the mapping. This method assumes that the passed position is after the last key entry of the mapping.

Depending on the implementation of the underlying method this method could be faster or at least as fast as the "setValue()"-method.

Implementations of the Mapping interface can override this method if appending values to the end of the mapping could be implemented faster than the "setValue()" method. Otherwise this method just calls the "setValue()"-method implementation.

Reimplemented in FilledUpMapping.

Definition at line 928 of file MappingBase.h.

References setValue().

Referenced by FilledUpMapping::appendValue(), and LogNormalShadowing::filterSignal().

                                                              {
    setValue(pos, value);
  }

virtual ConstMappingIterator* Mapping::createConstIterator (  )  [inline, virtual]

Returns an ConstMappingIterator by use of the respective implementation of the "createIterator()"-method.

Override this method if your ConstIterator differs from the normal iterator.

Implements ConstMapping.

Reimplemented in ConstMappingWrapper.

Definition at line 952 of file MappingBase.h.

References createIterator().

Referenced by SNRThresholdDecider::checkIfAboveThreshold(), and Decider80211::checkIfSignalOk().

                                                      {
    return createIterator();
  }

virtual ConstMappingIterator* Mapping::createConstIterator ( const Argument pos  )  [inline, virtual]

Returns an ConstMappingIterator by use of the respective implementation of the "createIterator()"-method.

Override this method if your ConstIterator differs from the normal iterator.

Implements ConstMapping.

Reimplemented in ConstMappingWrapper.

Definition at line 962 of file MappingBase.h.

References createIterator().

                                                                         {
    return createIterator(pos);
  }

virtual MappingIterator* Mapping::createIterator ( const Argument pos  )  [pure virtual]

Returns a pointer of a new Iterator which is able to iterate over the function and can change it.

The iterator starts at the passed position.

Implemented in TimeMapping< Interpolator >, LinearIntplMapping, ConstMappingWrapper, MultiDimMapping< Interpolator >, FilledUpMapping, DelayedMapping, TimeMapping< Linear >, and MultiDimMapping< Linear >.

virtual void Mapping::setValue ( const Argument pos,
double  value 
) [pure virtual]

The documentation for this class was generated from the following file: