[Telepathy] A telepathy-python newbie question

Anand CVR anandcvr01 at gmail.com
Sun Jan 17 16:00:23 PST 2010


Hi All,
      I'm a telepathy newbie, and I'm trying to understand the following
code from the telepathy-python example.

reg = telepathy.client.ManagerRegistry()
reg.LoadManagers()

# get the gabble Connection Manager
self.cm = cm = reg.GetManager('gabble')

# get the parameters required to make a Jabber connection
# Begin Example 2-3
cm[CONNECTION_MANAGER].RequestConnection('jabber',
    {
    'account':  account,
    'password': password,
    },
    reply_handler = self.request_connection_cb,
    error_handler = self.error_cb)

Question: Is cm an array or just one ConnectionManager object? The syntax
cm[CONNECTION_MANAGER] seems to suggest that it is an array. But the
GetManager() method seems to return just a ConnectionManager object.

Can someone please explain?

Thanks in advance.
A
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freedesktop.org/archives/telepathy/attachments/20100117/e19c6e4a/attachment.html 


More information about the telepathy mailing list