23#ifndef _ASTERISK_PRESSTATE_H
24#define _ASTERISK_PRESSTATE_H
108 const char *fmt, ...)
109 __attribute__((format(printf, 4, 5)));
129 const
char *presence_provider);
static struct prometheus_metrics_provider provider
struct stasis_cache * ast_presence_state_cache(void)
Backend cache for ast_presence_state_topic_cached()
int ast_presence_state_changed_literal(enum ast_presence_state state, const char *subtype, const char *message, const char *presence_provider)
Notify the world that a presence provider state changed.
int ast_presence_state_prov_add(const char *label, ast_presence_state_prov_cb_type callback)
Add presence state provider.
struct stasis_topic * ast_presence_state_topic_cached(void)
Get caching presence state topic.
enum ast_presence_state ast_presence_state_val(const char *val)
Convert presence state from text to integer value.
enum ast_presence_state(* ast_presence_state_prov_cb_type)(const char *data, char **subtype, char **message)
Presence state provider call back.
struct stasis_topic * ast_presence_state_topic_all(void)
Get presence state topic.
int ast_presence_state_engine_init(void)
enum ast_presence_state ast_presence_state_nocache(const char *presence_provider, char **subtype, char **message)
Asks a presence state provider for the current presence state, bypassing the event cache.
@ AST_PRESENCE_UNAVAILABLE
int ast_presence_state_prov_del(const char *label)
Remove presence state provider.
int ast_presence_state_changed(enum ast_presence_state state, const char *subtype, const char *message, const char *fmt,...)
Notify the world that a presence provider state changed.
const char * ast_presence_state2str(enum ast_presence_state state)
Convert presence state to text string for output.
struct stasis_message_type * ast_presence_state_message_type(void)
Get presence state message type.
#define AST_STRING_FIELD(name)
Declare a string field.
Stasis message payload representing a presence state update.
enum ast_presence_state state
AST_DECLARE_STRING_FIELDS(AST_STRING_FIELD(provider);AST_STRING_FIELD(subtype);AST_STRING_FIELD(message);)