INET Framework for OMNeT++/OMNEST
|
Given two iterators defining a range of key-value-pairs this class provides linear interpolation of the value at an arbitrary key-position. More...
#include <Interpolation.h>
Public Member Functions | |
Linear () | |
Linear (mapped_cref_type oorv) | |
virtual | ~Linear () |
virtual interpolated | operator() (const const_iterator &first, const const_iterator &last, key_cref_type pos, const_iterator upperBound) const |
Functor operator of this class which linear interpolates the value at the passed position using the values between the passed Iterators. More... | |
Public Member Functions inherited from inet::physicallayer::InterpolatorBase< _ContainerType > | |
InterpolatorBase () | |
InterpolatorBase (mapped_cref_type oorv) | |
virtual | ~InterpolatorBase () |
bool | continueAtOutOfRange (void) const |
interpolated | operator() (const const_iterator &first, const const_iterator &last, key_cref_type pos) const |
Functor operator of this class which interpolates the value at the passed position using the values between the passed Iterators. More... | |
virtual bool | isStepping () const |
Represents the interpolator a stepping function. More... | |
void | setOutOfRangeVal (mapped_cref_type oorv) |
Getter and Setter method for out of range value. More... | |
mapped_cref_type | getOutOfRangeVal (void) const |
Protected Types | |
typedef InterpolatorBase< _ContainerType > | base_class_type |
Static Protected Member Functions | |
static mapped_type | linearInterpolationFactor (key_cref_type t, key_cref_type t0, key_cref_type t1) |
Calculates the linear interpolation factor used for the interpolation. More... | |
static mapped_type | linearInterpolation (key_cref_type t, key_cref_type t0, key_cref_type t1, mapped_cref_type v0, mapped_cref_type v1) |
Additional Inherited Members | |
Public Attributes inherited from inet::physicallayer::InterpolatorBase< _ContainerType > | |
comparator_type | comp |
Comparator for STL functions. More... | |
Protected Member Functions inherited from inet::physicallayer::InterpolatorBase< _ContainerType > | |
interpolated | asInterpolated (mapped_cref_type rVal, bool bIsOutOfRange, bool bIsInterpolated=true) const |
Protected Attributes inherited from inet::physicallayer::InterpolatorBase< _ContainerType > | |
bool | continueOutOfRange |
interpolated | outOfRangeVal |
Given two iterators defining a range of key-value-pairs this class provides linear interpolation of the value at an arbitrary key-position.
|
protected |
typedef base_class_type::comparator_type inet::physicallayer::Linear< _ContainerType >::comparator_type |
typedef base_class_type::const_iterator inet::physicallayer::Linear< _ContainerType >::const_iterator |
typedef base_class_type::container_type inet::physicallayer::Linear< _ContainerType >::container_type |
typedef base_class_type::interpolated inet::physicallayer::Linear< _ContainerType >::interpolated |
typedef base_class_type::iterator inet::physicallayer::Linear< _ContainerType >::iterator |
typedef base_class_type::key_cref_type inet::physicallayer::Linear< _ContainerType >::key_cref_type |
typedef base_class_type::key_type inet::physicallayer::Linear< _ContainerType >::key_type |
typedef base_class_type::mapped_cref_type inet::physicallayer::Linear< _ContainerType >::mapped_cref_type |
typedef base_class_type::mapped_type inet::physicallayer::Linear< _ContainerType >::mapped_type |
typedef base_class_type::pair_type inet::physicallayer::Linear< _ContainerType >::pair_type |
typedef base_class_type::storage_type inet::physicallayer::Linear< _ContainerType >::storage_type |
|
inline |
|
inline |
|
inlinevirtual |
|
inlinestaticprotected |
|
inlinestaticprotected |
|
inlinevirtual |
Functor operator of this class which linear interpolates the value at the passed position using the values between the passed Iterators.
The upperBound-iterator has to point to the entry next bigger as the passed position to interpolate.
The returned instance of interpolated represents the result. Which can be either an actual entry of the interpolated map (if the position two interpolate was exactly that. Or it can be an interpolated value, if the passed position was between two entries of the map. This state can be retrieved with the "isInterpolated"-Member of the returned "interpolated".
Implements inet::physicallayer::InterpolatorBase< _ContainerType >.