powered by Jive Software

How to add a contact to my roster?


I’'m actually developping a Jabber client using Smack library. I have a problem adding a contact to the roster.

To create the roster I use this line : (connection is an XMPPConnection type)


then to add a contact I use this line :

roster.createEntry(user, name, group);

(I’'d also like to know what name is used for ?)

I think it’'s a silly mistakes, I may have forgot to declare something.

Thanks for your help !

What exactly is the problem that you are having?

The “name” parameter is for specifying a nickname for this contact; this is what would be typically displayed in a user interface for contacts.


It’'s OK I found the problem.

It was a problem of declaration.