Symbian Developer Library

SYMBIAN OS V6.1 EDITION FOR C++

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



Location: sendas.h
Link against: send.lib

Class MSendAsObserver

MSendAsObserver

Support

Supported from 5.0

Description

Allows CSendAs to call back a client with further information or requests. Any client of the Send As functionality needs to implement this class.

Defined in MSendAsObserver:
CancelRendering(), CapabilityOK(), RenderImage()


Function members


CapabilityOK()

virtual TBool CapabilityOK(TInt aCapabilty, TInt aResponse)=0;

Description

Checks an MTM capability that returns a response (e.g. maximum message size). After calling CSendAs::AddRequiredCapability(), the observer is called with the response from the MTM. If the mixin function returns ETrue, then the MTM has satisfied the required capability and will remain in the available MTM array.

Parameters

TUid aCapabilty

UID of capability to check

TInt aResponse

Capability information

Return value

ETrue

Capability supported

EFalse

Capability unsupported


RenderImage()

virtual TInt RenderImage(TUid aPrinterUid, const TDesC& aFileName);
virtual TInt RenderImage(TUid aPrinterUid, const TDesC& aFileName, TRequestStatus& aRequestStatus);

Description

Requests the message to be rendered using a certain printer driver (e.g. fax), using print-to-file. It passes the UID of the printer driver to use and the filename to which to print.

The default implementation returns KErrNotSupported. The asynchronous version is used with the asynchronous SaveMessageL() function.

Parameters

TUid aPrinterUid

UID of the printer driver with which to render message

const TDesC& aFileName TRequestStatus& aStatus

Filename to which to print

TRequestStatus& aRequestStatus

Asynchronous completion object

Return value

TInt

Return KErrNone if successful, otherwise a meaningful error code


CancelRendering()

virtual void CancelRendering();

Description

Requests the client to stop rendering the image. This should occur synchronously. This function will only be called after an asynchronous RenderImage() and before that function has completed. The default implementation is empty.