comparison mcabber/mcabber/caps.h @ 1999:51f032d5ca22

Add support for XEP-0115 Entity Capabilities, with offline cache
author Hermitifier
date Mon, 03 Oct 2011 16:00:34 +0200
parents e6d355e50d7a
children
comparison
equal deleted inserted replaced
1998:41667bc02883 1999:51f032d5ca22
3 3
4 #include <glib.h> 4 #include <glib.h>
5 5
6 void caps_init(void); 6 void caps_init(void);
7 void caps_free(void); 7 void caps_free(void);
8 void caps_add(char *hash); 8 void caps_add(const char *hash);
9 int caps_has_hash(const char *hash); 9 void caps_remove(const char *hash);
10 void caps_move_to_local(const char *hash, char *bjid);
11 int caps_has_hash(const char *hash, const char *bjid);
12 void caps_add_identity(const char *hash,
13 const char *category,
14 const char *name,
15 const char *type,
16 const char *lang);
10 void caps_set_identity(char *hash, 17 void caps_set_identity(char *hash,
11 const char *category, 18 const char *category,
12 const char *name, 19 const char *name,
13 const char *type); 20 const char *type);
21 void caps_add_dataform(const char *hash, const char *formtype);
22 void caps_add_dataform_field(const char *hash, const char *formtype,
23 const char *field, const char *value);
14 void caps_add_feature(char *hash, const char *feature); 24 void caps_add_feature(char *hash, const char *feature);
15 int caps_has_feature(char *hash, char *feature); 25 int caps_has_feature(char *hash, char *feature, char *bjid);
16 void caps_foreach_feature(const char *hash, GFunc func, gpointer user_data); 26 void caps_foreach_feature(const char *hash, GFunc func, gpointer user_data);
17 27
18 char *caps_generate(void); 28 char *caps_generate(void);
29 gboolean caps_verify(const char *hash, char *function);
30 void caps_copy_to_persistent(const char *hash, char *xml);
31 gboolean caps_restore_from_persistent(const char *hash);
19 32
20 #endif /* __MCABBER_CAPS_H__ */ 33 #endif /* __MCABBER_CAPS_H__ */
21 34
22 /* vim: set expandtab cindent cinoptions=>2\:2(0 sw=2 ts=2: For Vim users... */ 35 /* vim: set expandtab cindent cinoptions=>2\:2(0 sw=2 ts=2: For Vim users... */