[Telepathy] How to get contacts connected to more than one place ?

Dafydd Harries dafydd.harries at collabora.co.uk
Sat Oct 14 16:54:09 PDT 2006


Ar 13/10/2006 am 21:00, ysgrifennodd Xavier Claessens:
> Hi,
> 
> I'm looking at "PresenceUpdate" signal which says:
> 
>         Parameters:
>         a dictionary of contact handles mapped to a struct containing:
>         - a UNIX timestamp of the last activity time (in UTC)
>         - a dictionary mapping the contact's current status identifiers to:
>           a dictionary of optional parameter names mapped to their 
>           variant-boxed values
> 
> If the jabber protocol is used (gabble) the user can have a different
> status for each connection. Is it possible to get the resource and
> status'message for each connection with this signal ?
> 
> daf told me this signal should have parameters like:
> 
> presence[handle].statuses[0]['available'][0]['message']
> 
> So I guess we can have presence[handle].statuses[0,1,2...n] for each
> connection and get optional parameters like ['message'] and
> ['resource'].
> 
> Currently dictionaries seems to always have only one entry which seems a
> but useless. Is it a gabble limitation and will it be improved in the
> future ? Or I am missing something ?

Some protocols can have multiple statuses at the same time. I.e. "hacking on
Gabble", "listening to Iron Maiden".

I'm not really sure that we can map Jabber resources to this structure sanely;
it doesn't help that I can't keep the structure clearly in my head, or that
I'm not sure what a "status identifier" is. I can only imagine that it would
be one of the CONNECTION_PRESENCE_TYPE_* constants.

-- 
Dafydd


More information about the Telepathy mailing list