TMdERange Class Reference

class TMdERange

The TMdERange template is used for representing value ranges of various types. A range is composed of an upper limit, a lower limit, and type that describe how the limits are to be interpreted.

Value ranges are used with CMdERangePropertyCondition nodes to define a range of values that the condition matches. Basic operations such as "greater than", "equals to", and "between" are all implemented using value ranges. There are also more complex ranges that can be used in loops.

TMdERange is the base template for many different kind of value ranges. However, all ranges can be processed with the Min() , Max() , and Type() methods, regardless of any extra data defined by a specialized range type.

Public Member Functions
TMdERange (const T &, const T &, TMdERangeType )
TBool InRange (const T &)
const T & Max ()
const T & Min ()
TUint32 RequiredBufferSize ()
void SerializeL (CMdCSerializationBuffer &)
void SetMax (const T &)
void SetMin (const T &)
void SetType ( TMdERangeType )
const TMdERangeType & Type ()
Private Attributes
T iMax
T iMin
TMdERangeType iType

Constructor & Destructor Documentation

TMdERange(const T &, const T &, TMdERangeType)

TMdERange ( const T & aMin,
const T & aMax,
TMdERangeType aType = EMdERangeTypeAny
) [inline]

Parameters

const T & aMin
const T & aMax
TMdERangeType aType = EMdERangeTypeAny

Member Functions Documentation

InRange(const T &)

TBool InRange ( const T & aValue ) [inline]

Test if value is in the range.

Parameters

const T & aValue Tested value.

Max()

const T & Max ( ) const [inline]

Returns the upper limit of the range.

Min()

const T & Min ( ) const [inline]

Returns the lower limit of the range.

RequiredBufferSize()

TUint32 RequiredBufferSize ( ) [inline]

Get required size of serialized buffer when this is serialized.

SerializeL(CMdCSerializationBuffer &)

void SerializeL ( CMdCSerializationBuffer & aBuffer ) [inline]

Serialize own data to serialized buffer (correct position must be set before calling) and return new position of serialized buffer.

Parameters

CMdCSerializationBuffer & aBuffer serialized buffer.

SetMax(const T &)

void SetMax ( const T & aMax ) [inline]

Sets the upper limit of the range.

Parameters

const T & aMax The maximum value.

SetMin(const T &)

void SetMin ( const T & aMin ) [inline]

Sets the lower limit of the range.

Parameters

const T & aMin The minimum value.

SetType(TMdERangeType)

void SetType ( TMdERangeType aType ) [inline]

Sets the type of the range.

Parameters

TMdERangeType aType The new type.

Type()

const TMdERangeType & Type ( ) const [inline]

Returns the type of the range.

Member Data Documentation

T iMax

T iMax [private]

End of the range.

T iMin

T iMin [private]

Beginning of the range.

TMdERangeType iType

TMdERangeType iType [private]

Type.