[Telepathy] How to share connections across applications?
Simon McVittie
simon.mcvittie at collabora.co.uk
Mon Jul 26 03:44:11 PDT 2010
On Thu, 22 Jul 2010 at 11:40:48 -0700, Paddy Carman wrote:
> I have been successful creating text chats using the python
> examples given in the Telepathy developer's manual. I would like to
> understand how to share telepathy connections across applications.
Instead of creating a Connection directly (with RequestConnection), create
an Account in the AccountManager, and tell it to connect. Then, use that
Connection.
See: http://people.collabora.co.uk/~danni/telepathy-book/chapter.accounts.html
Existing Telepathy clients like Empathy also use the account manager, so for a
simple application, telling users to create an account using Empathy is the
easiest thing to do.
Similarly, to interact nicely with other clients, you should deal with Channels
via the ChannelDispatcher rather than using the Requests interface directly;
see:
http://people.collabora.co.uk/~danni/telepathy-book/chapter.channel-dispatcher.html
The reference implementation of an AccountManager and ChannelDispatcher is
telepathy-mission-control version 5. 5.4.x is the current stable branch, and
5.5.x is the development branch. In principle, someone could write an
alternative implementation, but we don't recommend doing that :-)
Simon
More information about the telepathy
mailing list