Symbian
Symbian OS Library

SYMBIAN OS V9.3

[Index] [Spacer] [Previous] [Next]



Location: EZGzip.h
Link against: ezlib.lib

Class CEZGZipToFile

class CEZGZipToFile : public CBase;

Description

A CEZGZipToFile object allows de-compression of a compressed file. The name of the compressed file is passed into the constructor along with a target file to contain the uncompressed data. The file is uncompressed by calling the InflateL() function.

Derivation

Members

Defined in CEZGZipToFile:
InflateL(), NewL(), NewLC(), ResetL()

Inherited from CBase:
Delete(), Extension_(), operator new()


Construction and destruction


NewLC()

static IMPORT_C CEZGZipToFile *NewLC(RFs &aRfs, const TDesC &aGzFileName, RFile &aOutput, TInt aBufferSize=0x8000);

Description

Creates a new CEZGZipToFile object and leaves it on the CleanupStack

Parameters

RFs &aRfs

open file server session

const TDesC &aGzFileName

name of the file to be de-compressed

RFile &aOutput

the target file to hold the un-compressed data

TInt aBufferSize

required size of buffers

Return value

CEZGZipToFile *

a pointer to the new CEZGZipToFile object, left on the CleanupStack


NewL()

static IMPORT_C CEZGZipToFile *NewL(RFs &aRfs, const TDesC &aGzFileName, RFile &aOutput, TInt aBufferSize=0x8000);

Description

Creates a new CEZGZipToFile object

Parameters

RFs &aRfs

open file server session

const TDesC &aGzFileName

name of the file to be de-compressed

RFile &aOutput

the target file to hold the un-compressed data

TInt aBufferSize

required size of buffers

Return value

CEZGZipToFile *

a pointer to the new CEZGZipToFile object

[Top]


Member functions


ResetL()

IMPORT_C void ResetL(RFs &aRfs, const TDesC &aGzFileName, RFile &aOutput, TInt aBufferSize=0x8000);

Description

Quits the current de-compression operation and restarts with the specified arguments

Parameters

RFs &aRfs

open file server session

const TDesC &aGzFileName

name of the file to be de-compressed

RFile &aOutput

the target file to hold the un-compressed data

TInt aBufferSize

required size of buffers

Leave codes

...

Any of the system wide error codes


InflateL()

IMPORT_C TBool InflateL();

Description

De-compresses the current zip file in stages. The function needs to called again until the de-compression is finalised, in which case it will return EFalse - for example...

while ( decompressor->InflateL() )
    {
    // No action required
    }

Return value

TBool

ETrue if the de-compression is not complete, and function must be called again EFalse if the de-compression is finalised

Leave codes

KEZlibErrBadGZipCrc

Invalid CRC check

...

Any of the system wide error codes