1 #ifndef __ROSTER_H 2 #define __ROSTER_H 3 4 enum { 5 XMPP_PRESENCE_UNAVAILABLE, 6 XMPP_PRESENCE_ERROR, 7 XMPP_PRESENCE_XA, 8 XMPP_PRESENCE_DND, 9 XMPP_PRESENCE_AWAY, 10 XMPP_PRESENCE_AVAILABLE, 11 XMPP_PRESENCE_CHAT, 12 XMPP_PRESENCE_ONLINE, 13 XMPP_PRESENCE_SHOW_LEN 14 }; 15 extern const char *xmpp_presence_show[]; 16 17 enum { 18 XMPP_SUBSCRIPTION_REMOVE, 19 XMPP_SUBSCRIPTION_NONE, 20 XMPP_SUBSCRIPTION_TO, 21 XMPP_SUBSCRIPTION_FROM, 22 XMPP_SUBSCRIPTION_BOTH 23 }; 24 extern const char *xmpp_subscription[]; 25 26 /* roster structure */ 27 typedef struct _XMPP_ROSTER_RESOURCE_REC { 28 char *name; 29 int priority; 30 int show; 31 char *status; 32 char *composing_id; 33 } XMPP_ROSTER_RESOURCE_REC; 34 35 typedef struct _XMPP_ROSTER_USER_REC { 36 char *jid; 37 char *name; 38 int subscription; 39 gboolean error; 40 GSList *resources; 41 } XMPP_ROSTER_USER_REC; 42 43 typedef struct _XMPP_ROSTER_GROUP_REC { 44 char *name; 45 GSList *users; 46 } XMPP_ROSTER_GROUP_REC; 47 48 __BEGIN_DECLS 49 void rosters_init(void); 50 void rosters_deinit(void); 51 __END_DECLS 52 53 #endif 54