TVPbkFieldTypeParameters Class Reference

#include <app/TVPbkFieldTypeParameters.h>

Link against: VPbkEng.lib

class TVPbkFieldTypeParameters

Detailed Description

A class for managing field type parameters.

Parameters are based on the Versit 2.1 standard and they can be found from TVPbkFieldTypeParameter in VPbkFieldType.hrh.

See also: VBK_FIELD_VERSIT_PROPERTY in VPbkFieldType.rh TVPbkFieldVersitProperty

library
VPbkEng.lib

Constructor & Destructor Documentation

TVPbkFieldTypeParameters ( )

TVPbkFieldTypeParameters()[inline]

Default constructor. Initializes this parameter set to empty.

TVPbkFieldTypeParameters ( TResourceReader & )

TVPbkFieldTypeParameters(TResourceReader &aResReader)[inline]

Constructs this parameter set from a resource. The resource must have LEN BYTE BYTE[] layout.

Exceptions
VPbkError::Panic(

VPbkError::EInvalidTypeParameterResource) if the resource is invalid.

ParameterDescription
aResReaderA reader to resource LEN BYTE BYTE[] that contains the parameters.

Member Function Documentation

Add ( TVPbkFieldTypeParameter )

Adds aParam to this parameter set.

ParameterDescription
aParamA new parameter to this set. aParam >= 0 && aParam < KVPbkMaxVersitParams. VPbkError::Panic(VPbkError::EInvalidTypeParameter) is raised if the precondition does not hold.

Returns: This object for easy chaining of calls. Contains(aParam)

AddAll ( const TVPbkFieldTypeParameters & )

TVPbkFieldTypeParameters &AddAll(const TVPbkFieldTypeParameters &aParams)[inline]

Adds all parameters of another parameter set to this set.

ParameterDescription
aParamsA set of paramters that are added to this set.

Returns: This object for easy chaining of calls. ContainsAll(aParams)

AddFromResource ( TResourceReader & )

voidAddFromResource(TResourceReader &aResReader)

Adds parameter set from a resource. The resource must have LEN BYTE BYTE[] layout.

Exceptions
VPbkError::Panic(

VPbkError::EInvalidTypeParameterResource) if the resource is invalid.

ParameterDescription
aResReaderA reader to resource LEN BYTE BYTE[] that contains the parameters.

Contains ( TVPbkFieldTypeParameter )

IMPORT_C TBoolContains(TVPbkFieldTypeParameteraParam)const

Returns true if aParam is included in this parameter set.

ParameterDescription
aParamA parameter that is looked for. aParam >= 0 && aParam < KVPbkMaxVersitParams

Returns: ETrue if aParam was found from this set.

ContainsAll ( const TVPbkFieldTypeParameters & )

IMPORT_C TBoolContainsAll(const TVPbkFieldTypeParameters &aOtherParams)const

Returns true if this parameter set contains all the parameters in aOtherParams.

This function is more efficient than calling Contains(TVPbkFieldTypeParameter) in a loop when multiple parameters are checked.

ParameterDescription
aOtherParamsA set of parameters that are looked for.

Returns: ETrue if all the aOtherParams were found from this set.

ContainsNone ( const TVPbkFieldTypeParameters & )

IMPORT_C TBoolContainsNone(const TVPbkFieldTypeParameters &aOtherParams)const

Returns true if this parameter set contains none of the parameters in aOtherParams.

This function is more efficient than calling Contains(TVPbkFieldTypeParameter) in a loop when multiple parameters are checked.

ParameterDescription
aOtherParamsA set of parameters that are looked for.

Returns: ETrue if none of the aOtherParams were found from this set.

FieldTypeParameters ( )

TUint32 *FieldTypeParameters()

Returns field type params configuration.

ReadFromResource ( TResourceReader & )

IMPORT_C voidReadFromResource(TResourceReader &aResReader)

Initializes this parameter set from a resource. The resource must have LEN BYTE BYTE[] layout.

Exceptions
VPbkError::Panic(

VPbkError::EInvalidTypeParameterResource) if the resource is invalid.

ParameterDescription
aResReaderA reader to resource LEN BYTE BYTE[] that contains the parameters.

Remove ( TVPbkFieldTypeParameter )

Removes aParam from this parameter set.

ParameterDescription
aParamA parameter that is removed from this set. aParam >= 0 && aParam < KVPbkMaxVersitParams. VPbkError::Panic(VPbkError::EInvalidTypeParameter) is raised if the precondition does not hold.

Returns: This object for easy chaining of calls. !Contains(aParam)

RemoveAll ( const TVPbkFieldTypeParameters & )

TVPbkFieldTypeParameters &RemoveAll(const TVPbkFieldTypeParameters &aParams)[inline]

Removes all parameters of another parameter set from this set.

ParameterDescription
aParamsParameters that are removed from this set.

Returns: This object for easy chaining of calls. ContainsAll(aParams)

Reset ( )

IMPORT_C voidReset()

Removes all parameters from this set.

Size ( )

TInt Size()

Size of field type params configuration.