Symbian
Symbian OS Library

SYMBIAN OS V9.3

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



Location: remconinterfaceselector.h
Link against: remconinterfacebase.lib

Class CRemConInterfaceSelector

class CRemConInterfaceSelector : public CBase;

Description

CRemConInterfaceSelector is only instantiable via its NewL function. It is not derivable.

Derivation

Members

Defined in CRemConInterfaceSelector:
ConnectBearer(), ConnectBearerCancel(), ControllerOpened(), DisconnectBearer(), DisconnectBearerCancel(), GetConnections(), GoConnectionOrientedL(), GoConnectionlessL(), NewL(), NotifyConnectionsChange(), NotifyConnectionsChangeCancel(), OpenControllerL(), OpenTargetL(), RegisterErrorObserver(), Send(), SendCancel(), TargetOpened(), ~CRemConInterfaceSelector()

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


Construction and destruction


NewL()

static IMPORT_C CRemConInterfaceSelector *NewL();

Description

Factory method.

Return value

CRemConInterfaceSelector *

Ownership of a new CRemConInterfaceSelector.


~CRemConInterfaceSelector()

IMPORT_C ~CRemConInterfaceSelector();

Description

Destructor.

[Top]


Member functions


RegisterErrorObserver()

IMPORT_C void RegisterErrorObserver(MRemConErrorObserver *aObserver);

Description

Register an error observer. This is provided to allow the client to discover when an error has occurred passively.

Parameters

MRemConErrorObserver *aObserver

An error observer to be notified on a passive error. NULL to stop receiving notifications.


OpenControllerL()

IMPORT_C void OpenControllerL();

Description

Opens a controller session to RemCon. The session is connectionless until such time as GoConnectionOriented may be called.

Leave codes

KErrInUse

If a controller session is already open.


GoConnectionOrientedL()

IMPORT_C void GoConnectionOrientedL(const TRemConAddress &aConnection);

Description

Makes the controller session (which must already exist- use OpenControllerL) connection-oriented.

Parameters

const TRemConAddress &aConnection

The remote to talk to.


GoConnectionlessL()

IMPORT_C void GoConnectionlessL();

Description

Makes the controller session (which must already exist- use OpenControllerL) connectionless.


ConnectBearer()

IMPORT_C void ConnectBearer(TRequestStatus &aStatus);

Description

Brings up a bearer-level connection. The controller session must already exist (use OpenControllerL) and be connection-oriented.

Parameters

TRequestStatus &aStatus

TRequestStatus for asynchronous completion.


ConnectBearerCancel()

IMPORT_C TInt ConnectBearerCancel();

Description

Cancels interest in the completion of a ConnectBearer request.

Return value

TInt

KErrNone.


DisconnectBearer()

IMPORT_C void DisconnectBearer(TRequestStatus &aStat);

Description

Destroys a bearer-level connection. The controller session must already exist (use OpenControllerL) and be connection-oriented.

Parameters

TRequestStatus &aStat


DisconnectBearerCancel()

IMPORT_C TInt DisconnectBearerCancel();

Description

Cancels interest in the completion of a DisconnectBearer request.

Return value

TInt

KErrNone.


OpenTargetL()

IMPORT_C void OpenTargetL();

Description

Opens a target session to RemCon.

Leave codes

KErrInUse

If a target session is already open.


Send()

IMPORT_C void Send(TRequestStatus &aStatus, TUid aInterfaceUid, TUint aOperationId, TUint &aNumRemotes, TRemConMessageType aMsgType, const TDesC8 &aData=KNullDesC8());

Description

Sends a message to the remote device(s).

Parameters

TRequestStatus &aStatus

TRequestStatus for asynchronous completion.

TUid aInterfaceUid

The UID of the concrete (outer-layer) interface sending the message.

TUint aOperationId

The interface-specific operation identifier.

TUint &aNumRemotes

On success, the number of remotes the message was successfully sent to.

TRemConMessageType aMsgType

Whether the message is a command or a response.

const TDesC8 &aData

Any associated message data in interface-specific format.


SendCancel()

IMPORT_C TInt SendCancel(TRemConMessageType aMsgType);

Description

Cancels interest in the completion of a Send request.

Parameters

TRemConMessageType aMsgType

The type of the message, the completion of the send of which we are not interested in. This is needed because a single CRemConInterfaceSelector may have two sends outstanding at once, one on a controller session and another on a target session.

Return value

TInt

KErrNone.


GetConnections()

IMPORT_C TInt GetConnections(TSglQue< TRemConAddress > &aConnections);

Description

Getter for the current set of connections in the system (not just those associated with this session). The client is responsible for cleaning up aConnections- the addresses will be on the heap.

Parameters

TSglQue< TRemConAddress > &aConnections

A collection of remote addresses, representing all the currently extant connections.

Return value

TInt

Error.


NotifyConnectionsChange()

IMPORT_C void NotifyConnectionsChange(TRequestStatus &aStatus);

Description

Notification for changes in the set of connections.

Parameters

TRequestStatus &aStatus

TRequestStatus for asynchronous completion.


NotifyConnectionsChangeCancel()

IMPORT_C TInt NotifyConnectionsChangeCancel();

Description

Cancels interest in the completion of an outstanding NotifyConnectionsChange operation.

Return value

TInt

KErrNone.


TargetOpened()

IMPORT_C TBool TargetOpened() const;

Description

To determine if a target session has been opened.

Return value

TBool

EFalse if no session has been opened, ETrue otherwise.


ControllerOpened()

IMPORT_C TBool ControllerOpened() const;

Description

To determine if a controller session has been opened.

Return value

TBool

EFalse if no session has been opened, ETrue otherwise.