-1

Exists any agsxmpp documentation? I cannot find anything. I'm making IM and I need know following:

  • how can i get contact list (contains - current availability, nickname, identificator (user@site))
  • not sure if this event works (need for availability change) : static void xmpp_OnPresence(object sender, Presence pres)
  • is where any timestamp or datetime value in incoming message

What I found is this for getting contacts:

    public void RequestRoster()
    {      
        RosterIq iq = new RosterIq(IqType.get);
        xmpp.IqGrabber.SendIq(iq, new IqCB(OnRosterResult), null);
    }

    private void OnRosterResult(object sender, IQ iq, object data)
    {         
        Roster r = iq.Query as Roster;
        if (r != null)
        {
            foreach (RosterItem i in r.GetRoster())
            {
                Console.WriteLine(i.Name);
            }
        }
    }

But there aren't all properties (I need also availability, identificator) or are they?

sczdavos
  • 2,035
  • 11
  • 37
  • 71
  • docs: http://www.ag-software.de/agsxmpp-sdk/ RosterItem: http://xeus.googlecode.com/svn-history/r279/trunk/xeus/Core/RosterItem.cs – rene Aug 18 '12 at 11:00
  • @rene I found that also but nothing usefull (except the RosterItem class). But I'm still resolving problem with Roster. Can I get contact list before going online? I read that I can getContact list in login and roster is not needed. Do you know anything about that? – sczdavos Aug 18 '12 at 14:18

1 Answers1

1

agsXMPP request the roster automatically on login. You only have to sibscrobe to teh OnRosterItem event to get all your contacts.
agsXMPP also comes with many examples. So look at the sample codes.

Alex
  • 4,066
  • 2
  • 19
  • 21
  • So the OnRoster event will automatically occurs on login? I cant find any sample codes. Can you give me some links please? – sczdavos Sep 12 '12 at 12:14
  • Ohhh, thanks a lot. I've been here when I downloading library: http://www.ag-software.de/download-directory/ – sczdavos Sep 13 '12 at 13:53