TUnicodeExpander Class Reference

#include <s32ucmp.h>

class TUnicodeExpander : public TUnicodeCompressionState

Inherits from

Detailed Description

A class to hold functions to expand text using the Standard Compression Scheme for Unicode.

A note on error handling and leaving.

Although all the public functions except the constructor can leave, it is possible to guarantee success: that is, guarantee that a call will not leave, and that expansion will be completed. To do this, (i) supply a MUnicodeSink object with a non-leaving WriteUnicodeValueL function, such as a TMemoryUnicodeSink; (ii) read input from a RReadStream with a non-leaving ReadL function; (iii) supply a big enough buffer to write the ouput; you can find out how big by calling ExpandedSizeL, using methods (i) and (ii) to guarantee success.

This guarantee of success is particularly useful when expanding from one memory buffer to another.

Constructor & Destructor Documentation

TUnicodeExpander ( )

IMPORT_CTUnicodeExpander()

Member Function Documentation

ExpandL ( MUnicodeSink &, RReadStream &, TInt, TInt, TInt *, TInt * )

IMPORT_C voidExpandL(MUnicodeSink &aOutput,
RReadStream &aInput,
TIntaMaxOutputWords =  KMaxTInt ,
TIntaMaxInputBytes =  KMaxTInt ,
TInt *aOutputWords = 0,
TInt *aInputBytes = 0
)

ExpandL ( MUnicodeSink &, const TUint8 *, TInt, TInt, TInt *, TInt * )

IMPORT_C voidExpandL(MUnicodeSink &aOutput,
const TUint8 *aInput,
TIntaMaxOutputWords =  KMaxTInt ,
TIntaMaxInputBytes =  KMaxTInt ,
TInt *aOutputWords = 0,
TInt *aInputBytes = 0
)

ExpandedSizeL ( RReadStream &, TInt )

IMPORT_C TIntExpandedSizeL(RReadStream &aInput,
TIntaInputBytes
)[static]

ExpandedSizeL ( const TUint8 *, TInt )

IMPORT_C TIntExpandedSizeL(const TUint8 *aInput,
TIntaInputBytes
)[static]

FlushL ( MUnicodeSink &, TInt, TInt & )

IMPORT_C TIntFlushL(MUnicodeSink &aOutput,
TIntaMaxOutputWords,
TInt &aOutputWords
)