Implements helpers for to and from attributes

xmpp_stanza_{get,set}_{from,to}
This commit is contained in:
Tristan Le Guern
2015-07-29 15:44:18 +02:00
committed by Dmitry Podgorny
parent 64d65b3aed
commit 90a595f8ef
2 changed files with 84 additions and 5 deletions

View File

@@ -345,15 +345,16 @@ int xmpp_stanza_set_text_with_size(xmpp_stanza_t *stanza,
/* common stanza helpers */
char *xmpp_stanza_get_type(xmpp_stanza_t * const stanza);
char *xmpp_stanza_get_id(xmpp_stanza_t * const stanza);
char *xmpp_stanza_get_to(xmpp_stanza_t * const stanza);
char *xmpp_stanza_get_from(xmpp_stanza_t * const stanza);
int xmpp_stanza_set_id(xmpp_stanza_t * const stanza,
const char * const id);
int xmpp_stanza_set_type(xmpp_stanza_t * const stanza,
const char * const type);
/* unimplemented
int xmpp_stanza_set_to();
int xmpp_stanza_set_from();
*/
int xmpp_stanza_set_to(xmpp_stanza_t * const stanza,
const char * const to);
int xmpp_stanza_set_from(xmpp_stanza_t * const stanza,
const char * const from);
/* allocate and initialize a stanza in reply to another */
/* unimplemented