Symbian
 Developer Library

DEVELOPER LIBRARY

[Index] [Glossary] [Previous] [Next]



Location: faxstore.h
Link against: FaxStrm.lib

Class CReadFaxFile

CReadFaxFile

Support

Supported from 5.0

Description

Opens a fax file for reading.

The class provides the functionality to open and close a fax file. The ability to read individual fax pages is provided by the CReadFaxPages data member, which is created when the file is opened.

In pre-v5.1 versions of Symbian OS, the import library was faxst2.lib.

Derivation

CBaseBase class for all classes to be instantiated on the heap
CReadFaxFileOpens a fax file for reading

Defined in CReadFaxFile:
Close(), NewL(), OpenL(), iReadFaxPages, ~CReadFaxFile()

Inherited from CBase:
operator new()

See also:


Construction and destruction


NewL()

static CReadFaxFile* NewL();

Description

Constructs a CReadFaxFile object, which offers the public API for opening a fax file for reading.

Return value

CReadFaxFile*

A pointer to the newly created object.

Leave codes

The function may leave with KErrNoMemory if there is insufficient memory to perform the operation.

Notes:


~CReadFaxFile()

~CReadFaxFile();

Description

Destructor

Closes the session with the file server, and frees all resources owned by the object, prior to its destruction.

[Top]


Member functions


OpenL()

void OpenL(const TDesC& aFileName);

Description

Opens a fax file for reading.

The function also allocates memory to create a CReadFaxPages object — which is pointed to by the iReadFaxPages class data member. This class defines the API for reading individual pages from the file store.

Fax files which have been opened should be paired with a Close() function.

Parameters

const TDesC& aFileName

The name of the fax file.


Close()

void Close();

Description

Closes the fax file, and deletes the resources owned by the object.

Although this function is called in the destructor, it is good programming practice to invoke it manually to pair previous OpenL() calls.

[Top]


Data members


iReadFaxPages

CReadFaxPages* iReadFaxPages

Description

A pointer to the object which can be used to access the fax pages stored in the file. Memory is allocated for the object when the fax file is opened.