Group PJSIP_SIMPLE_XPIDF¶
-
group
PJSIP_SIMPLE_XPIDF
Support for XPIDF/Presence Information Data Format.
This is an old presence data format as described in: draft-rosenberg-impp-pidf-00.txt.
We won’t support this format extensively here, as it seems there’s not too many implementations support this anymore, as it shouldn’t.
Typedefs
-
typedef pj_xml_node
pjxpidf_pres
¶ Type definitions for XPIDF root document.
Functions
-
pjxpidf_pres *
pjxpidf_create
(pj_pool_t *pool, const pj_str_t *uri)¶ Create a new XPIDF document.
- Parameters
pool – Pool.
uri – URI to set in the XPIDF document.
- Returns
XPIDF document.
-
pjxpidf_pres *
pjxpidf_parse
(pj_pool_t *pool, char *text, pj_size_t len)¶ Parse XPIDF document.
- Parameters
pool – Pool.
text – Input text.
len – Length of input text.
- Returns
XPIDF document.
-
int
pjxpidf_print
(pjxpidf_pres *pres, char *text, pj_size_t len)¶ Print XPIDF document.
- Parameters
pres – The XPIDF document to print.
text – Buffer to place the output.
len – Length of the buffer.
- Returns
The length printed.
-
pj_str_t *
pjxpidf_get_uri
(pjxpidf_pres *pres)¶ Get URI in the XPIDF document
- Parameters
pres – XPIDF document
- Returns
The URI, or an empty string.
-
pj_status_t
pjxpidf_set_uri
(pj_pool_t *pool, pjxpidf_pres *pres, const pj_str_t *uri)¶ Set the URI of the XPIDF document.
- Parameters
pool – Pool.
pres – The XPIDF document.
uri – URI to set in the XPIDF document.
- Returns
Zero on success.
-
pj_bool_t
pjxpidf_get_status
(pjxpidf_pres *pres)¶ Get presence status in the XPIDF document.
- Parameters
pres – XPIDF document.
- Returns
True to indicate the contact is online.
-
pj_status_t
pjxpidf_set_status
(pjxpidf_pres *pres, pj_bool_t status)¶ Set presence status in the XPIDF document.
- Parameters
pres – XPIDF document.
status – Status to set, True for online, False for offline.
- Returns
Zero on success.
-
typedef pj_xml_node