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()
voidSerializeL(CMdCSerializationBuffer &)
voidSetMax(const T &)
voidSetMin(const T &)
voidSetType(TMdERangeType)
const TMdERangeType &Type()
Private Attributes
TiMax
TiMin
TMdERangeType iType

Constructor & Destructor Documentation

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

TMdERange(const T &aMin,
const T &aMax,
TMdERangeTypeaType = 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 & aValueTested 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 &)

voidSerializeL(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 & aBufferserialized buffer.

SetMax(const T &)

voidSetMax(const T &aMax)[inline]

Sets the upper limit of the range.

Parameters

const T & aMaxThe maximum value.

SetMin(const T &)

voidSetMin(const T &aMin)[inline]

Sets the lower limit of the range.

Parameters

const T & aMinThe minimum value.

SetType(TMdERangeType)

voidSetType(TMdERangeTypeaType)[inline]

Sets the type of the range.

Parameters

TMdERangeType aTypeThe new type.

Type()

const TMdERangeType &Type()const [inline]

Returns the type of the range.

Member Data Documentation

T iMax

TiMax[private]

End of the range.

T iMin

TiMin[private]

Beginning of the range.

TMdERangeType iType

TMdERangeType iType[private]

Type.