class MXIMPProtocolPlugin : public MXIMPBase |
Interface for presence protocol plug-in object. Interface must be implemented by a concrete XIMP Framework protocol plug-ins.
This interface models presence protocol plug-in. XIMP Framework loads a MXIMPProtocolPlugin instance for needed protocol, by instantiating protocol specific CXimpFwProtocolPluginBase object through ECom architecture.
XIMP Framework calls methods defined in this interface to manage protocol connections based on clients requests.
Public Member Functions | |
---|---|
MXIMPProtocolConnection & | AcquireConnectionL(const MXIMPServiceInfo &, const MXIMPContextClientInfo &) |
void | PrimeHost(MXIMPProtocolPluginHost &) |
void | ReleaseConnection(MXIMPProtocolConnection &) |
Protected Member Functions | |
---|---|
~MXIMPProtocolPlugin() |
~MXIMPProtocolPlugin | ( | ) | [protected, inline, virtual] |
Protected destructor. MXIMPProtocolPlugin objects can't be deleted through this interface.
MXIMPProtocolConnection & | AcquireConnectionL | ( | const MXIMPServiceInfo & | aService, |
const MXIMPContextClientInfo & | aContextClient | |||
) | [pure virtual] |
Acquires a presence protocol connection.
Always instantiate a new MXIMPProtocolConnection object to manage each client session as separated entity.
Try to locate suitable existing connection from list of currently existing remote connections, and thus allow two or more client applications to share the remote presence connection. Protocol plug-in implementation can itself select in which circumstance to share the connection. Usually sharing should happen, when two remote connections are targeted to same remote service and to same user account.
Presence Protocol plug-in must maintain internally list of existing presence service connection objects. Direct ownership of acquired presence service connection objects remain in the presence protocol plug-in. When XIMP Framework doesn't anymore need the certain acquired presence service connection, XIMP Framework disposes MXIMPProtocolConnection instance with MXIMPProtocolPlugin::ReleaseConnection(). If the same MXIMPProtocolConnection instance was returned multiple times from MXIMPProtocolPlugin::AcquireConnectionL(), it is still disposed only once with ReleaseConnection(), after closing the last utilizing client session.
const MXIMPServiceInfo & aService | Target address, credentials etc. info for remote presence connection. |
const MXIMPContextClientInfo & aContextClient | Object describing the client requesting the remote presence connection. |
void | PrimeHost | ( | MXIMPProtocolPluginHost & | aHost | ) | [pure virtual] |
Primes presence protocol plug-in with its callback interface.
Primes the presence protocol plug-in instance with its XIMP Framework side callback interface. Here given MXIMPProtocolPluginHost interface is implemented and owned by the XIMP Framework, and presence protocol plug-in must use it to communicate back to XIMP Framework direction.
This method is called by XIMP Framework before requesting any other requests from presence protocol plug-in instance.
This method is called just once for one MXIMPProtocolPlugin, just after loading MXIMPProtocolPlugin instance through ECom architecture.
Presence protocol plug-in instance must use here given specific host interface instance to communicate back to XIMP Framework direction from asynchronous requests.
The presence protocol plug-in implementation must store the here given host reference internally, so protocol plug-in implementation can access the host when needed.
Here given MXIMPProtocolPluginHost instance, is guaranteed to remain valid (usable), untill the protocol plug-in destroyed by deleting. However, protocol plug-in isn't allowed to call MXIMPProtocolPluginHost from its MXIMPProtocolPlugin::~MXIMPProtocolPlugin() destructor.
MXIMPProtocolPluginHost & aHost | Reference to host interface, what this MXIMPProtocolPlugin instance must use when communicating back to XIMP Framework direction. Object ownership is not trasfered. |
void | ReleaseConnection | ( | MXIMPProtocolConnection & | aConnection | ) | [pure virtual] |
Releases presence service connection.
XIMP Framework calls this to releases previously acquired MXIMPProtocolConnection instance. XIMP Framework calls this method just once for each MXIMPProtocolConnection instance, event same MXIMPProtocolConnection instance were returned in several AcquireConnectionL() calls.
MXIMPProtocolConnection & aConnection | Connection object to release. |
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.