Symbian
 Developer Library

DEVELOPER LIBRARY

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



Location: cfaxio.h
Link against: FaxIO.lib

Class CFaxHeaderLines

CFaxHeaderLines

Support

Supported from 5.0

Description

Read/write fax header line data

Allows applications to read and write information from the fax header line data file: including the header line template, a font bitmap, and character offset information. This data can be used to generate a fax header line — which contains send-time information — in real time.

This class is not intended for user derivation.

In pre-v5.1 releases of Symbian OS, this class was defined in faxstore.h and had an import library faxst2.lib.

Derivation

CBaseBase class for all classes to be instantiated on the heap
CFaxHeaderLinesRead/write fax header line data

Defined in CFaxHeaderLines:
NewL(), NewLC(), ReadFaxHeaderInfoL(), ReadRawFontLineL(), ReadRawHeaderLineL(), WriteFaxHeaderInfoL(), WriteRawFontLineL(), WriteRawHeaderLineL(), iOurFaxHeaderInfoPckg, ~CFaxHeaderLines()

Inherited from CBase:
operator new()


Construction and destruction


NewL()

static CFaxHeaderLines* NewL();

Description

Constructs a CFaxHeaderLines object, which is used to read and write the fax header line data file.

Return value

CFaxHeaderLines*

A pointer to the newly created object.

Leave codes

KErrNoMemory

There is insufficient memory to perform the operation.

Notes:


NewLC()

static CFaxHeaderLines* NewLC();

Description

Constructs a CFaxHeaderLines object, which is used to read and write the fax header line data file.

As is usual in Symbian OS, the only difference between this function and NewL() is that this variant pushes the object to the cleanup stack.

Return value

CFaxHeaderLines*

Pointer to the newly created object.

Leave codes

KErrNoMemory

There is insufficient memory to perform the operation.

Notes:


~CFaxHeaderLines()

~CFaxHeaderLines();

Description

Closes the open header line data file and shuts down the file server session.

[Top]


Writing fax header data file

Description

A new fax header data file — C:\System\faxhead.dat — should be created every time the user identity or phone number changes. The WriteFaxHeaderInfoL() must be invoked first, as it creates/opens the file and adds the font and character offset information to it. WriteRawFontLineL() should then be invoked to add the header line template scan lines, and WriteRawHeaderLineL() should be called to add the font bitmap scan lines.


WriteFaxHeaderInfoL()

void WriteFaxHeaderInfoL(TFaxHeaderInfo &aFaxHeaderInfo);

Description

Creates and opens the fax header data file, and then writes font and character offset information to it.

The font and character offset information is used by the fax server to determine at which position the font bitmap characters should be inserted in the header line template — to create the send-time header line for a page.

Parameters

TFaxHeaderInfo &aFaxHeaderInfo

The fax header line information to be written to the file.

Notes:


WriteRawFontLineL()

void WriteRawFontLineL(const TInt alineNumber,TRawScanLine& aUncompressedDataLine);

Description

Writes header line font bitmap scan lines to the header line data file.

It should be called to add every scan line in the font bitmap.

Parameters

const TInt alineNumber

The line number of the current scan line.

TRawScanLine& aUncompressedDataLine

A reference to a raw font bitmap scan line to be added to the header line data file.


WriteRawHeaderLineL()

void WriteRawHeaderLineL(const TInt alineNumber,TRawScanLine& aUncompressedDataLine);

Description

Writes the header line template's scan lines to the header line data file. It should be called to add every scan line in the template.

Parameters

const TInt alineNumber

The line number of the current scan line.

TRawScanLine& aUncompressedDataLine

A reference to a raw header line template scan line to be added to the header line data file.

[Top]


Reading fax header data file

Description

The ReadFaxHeaderInfoL() is invoked first, as it opens the file and reads the font and character offset information. ReadRawFontLineL() and ReadRawHeaderLineL() are then be called to get the header line template and the font bitmap.

The fax header data file — C:\System\faxhead.dat — is read by the fax server, and used to create a new fax header line every time a page is sent.


ReadFaxHeaderInfoL()

void ReadFaxHeaderInfoL(TFaxHeaderInfo &aFaxHeaderInfo);

Description

Opens the fax header data file, and then reads font and character offset information from it.

The font and character offset information is used by the fax server to determine at which position the font bitmap characters should be inserted in the header line template — to create the send time header line for a page.

Parameters

TFaxHeaderInfo &aFaxHeaderInfo

On return, contains header line information from the header data file.

Notes:


ReadRawFontLineL()

void ReadRawFontLineL(const TInt alineNumber,TRawScanLine &aUncompressedDataLine);

Description

Reads the font bitmap's scan lines from the header line data file.

It should be called to read every scan line in the bitmap.

In normal operation the function is called by the fax server prior to sending a page.

Parameters

const TInt alineNumber

The line number to be read.

TRawScanLine &aUncompressedDataLine

On return, contains a reference to the raw scan line.


ReadRawHeaderLineL()

void ReadRawHeaderLineL(const TInt alineNumber,TRawScanLine &aUncompressedDataLine);

Description

Reads the header line template's scan lines from the header line data file. It should be called to read every scan line in the template.

In normal operation the function is called by the fax server prior to sending a page.

Parameters

const TInt alineNumber

The line number of the scan line to be read.

TRawScanLine &aUncompressedDataLine

On return, contains the scan line.

[Top]


Data members


iOurFaxHeaderInfoPckg

TFaxHeaderInfoPckg iOurFaxHeaderInfoPckg

Description

The fax header information package.