Symbian
Symbian OS Library

SYMBIAN OS V9.3

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



Location: tranp.h
Link against: irtranp.lib

Class CTranpSession

class CTranpSession : public CBase;

Description

Encapsulates the behaviour for sending a picture to a peer device and for receiving a picture from a peer device.

Derivation

Members

Defined in CTranpSession:
Abort(), Config(), Config(), Connect(), Disconnect(), EReqCommands, EReqImageInfo, EReqStatus, Get(), NewL(), Put(), Query(), TTranP, ~CTranpSession()

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


Construction and destruction


NewL()

static IMPORT_C CTranpSession *NewL(MTranpNotification &aNotifier);

Description

Constructs and returns a pointer to a new picture transmission session.

Parameters

MTranpNotification &aNotifier

An implementation of the picture transmission callback interface.

Return value

CTranpSession *

A pointer to the new picture transmission session.


~CTranpSession()

IMPORT_C ~CTranpSession();

Description

Frees all resources owned by the object, prior to its destruction.

[Top]


Member functions


Connect()

IMPORT_C void Connect();

Description

Establishes a connection with a peer device. This function is called before sending a picture.

The callback function Connect() is called when the connection has been successfully established.

See also:


Disconnect()

IMPORT_C void Disconnect();

Description

Breaks the connection with a peer device. This function is called after sending a picture.

The callback function Disconnected() is called when the connection has been broken.

See also:


Abort()

IMPORT_C void Abort();

Description

Aborts any transmission in progress.


Query()

IMPORT_C void Query(TTranP aWhat);

Description

Requests information on the processing ability of the peer device. Typically, this is called before sending a picture to that peer device. The information is returned through the callback function QueryComplete().

Parameters

TTranP aWhat

The specific type of information required from the peer device.

See also:


Get()

IMPORT_C void Get(TTranpPicture &aPicture);

Description

Receives a picture from a peer device.

The following sequence of events is expected:

A peer device connects successfully, resulting in a call to the Connect() callback function.

The peer device sends picture data, resulting in successive calls to the ProgressIndication() callback function indicating how much of the picture data has been received.

Reception of picture data is complete, resulting in a call to the GetComplete() call back function.

Disconnection from the peer device, resulting in a call the Disconnected() callback function.

If the connection with the peer device is dropped at any stage in the transmission, then this results in a call to the Error() callback function.

Parameters

TTranpPicture &aPicture

The picture object

See also:


Put()

IMPORT_C void Put(const TTranpPicture &aPicture);

Description

Sends a picture to a peer device.

The following sequence of events is expected:

This device sends picture data to the peer device, resulting in successive calls to the ProgressIndication() callback function indicating how much of the picture data has been received.

Transmission of picture data is complete, resulting in a call to the GetComplete() callback function.

If the connection with the peer device is dropped at any stage in the transmission, then this results in a call to the Error() callback function.

Parameters

const TTranpPicture &aPicture

The picture object

See also:


Config()

IMPORT_C void Config(const TTranpConfig &aConfig);

Description

Sets the configuration parameters.

Parameters

const TTranpConfig &aConfig

The configuration parameters


Config()

IMPORT_C TTranpConfig Config() const;

Description

Returns the configuration parameters.

Return value

TTranpConfig

The configuration parameters.

[Top]


Member enumerations


Enum TTranP

TTranP

Description

The type of information required from a peer device.

EReqImageInfo

Request still-information from the peer, e.g. resolution and size.

EReqStatus

Request information about the peer's battery status and free memory.

EReqCommands

Request how many commands can be executed in one SCEP session.