On Thu, Feb 21, 2008 at 7:13 AM, Alban Taraire <alban.taraire@xxxxxxxxx> wrote:
>
> Hi all,
>
> I'm not sure how to retrieve the list of RosterItems from a RosterManager. If
> my user just connected, I can call fill() to get the server's roster in my
> local roster, that's fine.
> But then, I only have RosterItem * getRosterItem ( const JID & jid ) to get
> one RosterItem.
> If I assume first connection, I'm not supposed to know the different JIDs for
> which my roster has a RosterItem. So how can I get this list ? For example,
> to populate the contacts view ?
> Is there an iterator of some kind I can use to crawl the RosterItems list ?
>
> Thanks a lot,
>
> Alban
>
>
>
> --
> gloox-dev mailing list
> to unsubscribe:
> send a message with subject 'unsubscribe gloox-dev' to minimalist@xxxxxxxxxx
>
Hi,
Here you see the documentation of that class:
http://camaya.net/api/gloox/classgloox_1_1RosterManager.html
Use the roster() method which returns a pointer to a Roster which is a
typedef to std::map<const std::string, RosterItem*>.
Cheers,
Tobias