CImapTransportBufferSizes Class Reference

class CImapTransportBufferSizes : public CBase

Stores the transport buffer sizes to be used for IMAP operations.

Each rule consists of a bearer types field, and some buffer size information. The bearer types are defined by the TCommDbBearer enumeration and it is possible to specify multiple bearer types for one rule by performing a bitwise OR operation on the values from the enumeration and passing the resulting value to the various APIs. The buffer size options supported are: 1) Fetch request size - Maximum amount of data that can be requested from the server by a FETCH command. Fetching large email components such as atatchments may require multiple fetch requests to be made dependent on the size specified. 2) Fetch commands outstanding - The maximum number of fetch responses that can be outstanding at any one time. Fetching large email components such as attachments may require multiple fetch requests to be made. It is possible to send multiple fetch requests to the server at the same time, and this option determines how many responses can be outstanding at any one time.

Inherits from

  • CImapTransportBufferSizes

Constructor & Destructor Documentation

CImapTransportBufferSizes()

CImapTransportBufferSizes()[private]

Class constructor

~CImapTransportBufferSizes()

~CImapTransportBufferSizes()

Class destructor

Member Functions Documentation

AddSizesL(TInt, TUint32, TInt, TInt)

IMPORT_C TIntAddSizesL(TIntaPos,
TUint32aBearerTypes,
TIntaFetchRequestSize,
TIntaMaxOutstandingFetchResponses
)

Adds a transport buffer sizes entry

The position for the new entry is specified in the parameter list. If the position is greater than the number of entries already in the list then the new entry is added at the end of the list. If the position is less than the number of entries already in the list, then the new entry is inserted at that position and all subsequent entries moved down by one position. The actual position where the entry was added is given by the return value.

Invalid arguments passed to the routine will cause a panic on debug builds but a leave with KErrArgument on a release build.

leave
KErrArgument Argument passed in is invalid

Parameters

TInt aPosPosition in the list to add the entry.
TUint32 aBearerTypesBearer types that will use the entry.
TInt aFetchRequestSizeFetch request size in bytes. Minimum value 1024. Must be a multiple of 1024.
TInt aMaxOutstandingFetchResponsesMaximum number of outstanding fetch responses allowed. Minimum value 1, Maximum value 8.

ConstructL()

voidConstructL()[private]

Second phase constructor

CopyL()

IMPORT_C CImapTransportBufferSizes *CopyL()

Make copy of an instance of the class.

CopyLC()

IMPORT_C CImapTransportBufferSizes *CopyLC()

Make new copy of an instance of the class. On return the copy will be on the cleanup stack.

DeleteBearerTypesL(TUint32, TBool &)

IMPORT_C TIntDeleteBearerTypesL(TUint32aBearerTypes,
TBool &aSizesRemoved
)

Deletes bearer types from the transport buffer sizes entries.

Every entry is examined to see if the bearer types associated with that entry contain all of the passed in bearer types. If there is a match then the bearer types are removed from the entry. If this results in all the bearer types for the entry being removed then the entry is deleted and all subsequent entries are moved up one position.

Invalid arguments passed to the routine will cause a panic on debug builds but a leave with KErrArgument on a release build.

leave
KErrArgument Argument passed in is invalid

Parameters

TUint32 aBearerTypesBearer types to remove.
TBool & aSizesRemovedIf the bearer types are removed, this flag indicates if the removal resulted in the entry being removed as well.

DeleteSizesL(TInt)

IMPORT_C TBoolDeleteSizesL(TIntaPos)

Deletes a transport buffer sizes entry from a given position

Invalid arguments passed to the routine will cause a panic on debug builds but a leave with KErrArgument on a release build.

leave
KErrArgument Argument passed in is invalid

Parameters

TInt aPosPosition in the list to add the entry.

GetSizesL(TInt, TUint32 &, TInt &, TInt &)

IMPORT_C TBoolGetSizesL(TIntaPos,
TUint32 &aBearerTypes,
TInt &aFetchRequestSize,
TInt &aMaxOutstandingFetchResponses
)const

Gets the transport buffer sizes entry at a given position.

Invalid arguments passed to the routine will cause a panic on debug builds but a leave with KErrArgument on a release build.

leave
KErrArgument Argument passed in is invalid

Parameters

TInt aPosPosition of the entry in the list
TUint32 & aBearerTypesOn successful completion, this holds the bearer types for the entry
TInt & aFetchRequestSizeOn successful completion, this holds the fetch request size in bytes.
TInt & aMaxOutstandingFetchResponsesOn successful completion, this holds the maximum number of outstanding fetch responses allowed.

GetSizesL(TUint32, TInt &, TInt &)

IMPORT_C TIntGetSizesL(TUint32aBearerTypes,
TInt &aFetchRequestSize,
TInt &aMaxOutstandingFetchResponses
)const

Gets the transport buffer sizes entry for a bearer type.

An entry is returned only if the bearer types associated with the entry contain all the bearer types specified in the passed in value.

Invalid arguments passed to the routine will cause a panic on debug builds but a leave with KErrArgument on a release build.

leave
KErrArgument Argument passed in is invalid

Parameters

TUint32 aBearerTypesThe bearer types to search for
TInt & aFetchRequestSizeOn successful completion, this holds the fetch request size in bytes.
TInt & aMaxOutstandingFetchResponsesOn successful completion, this holds the maximum number of outstanding fetch responses allowed.

NewL()

IMPORT_C CImapTransportBufferSizes *NewL()[static]

Factory constructor.

NewLC()

IMPORT_C CImapTransportBufferSizes *NewLC()[static]

Factory constructor.

Reset()

IMPORT_C voidReset()

Reset the entries list so that it is empty

Member Data Documentation

RArray< TImapTransportBufferSizes > iSizesList

RArray< TImapTransportBufferSizes >iSizesList[private]