163 #define PAGE_BEEP "beep" 185 ast_func_write(chan,
"CONFBRIDGE(bridge,record_conference)",
"yes");
255 char *predial_callee =
NULL;
256 char confbridgeopts[128];
265 unsigned int num_dials;
285 if ((tmp = strchr(originator,
'-'))) {
294 timeout = atoi(
args.timeout);
297 snprintf(confbridgeopts,
sizeof(confbridgeopts),
"ConfBridge,%u", confid);
301 tmp =
args.devices ?:
"";
341 if (!strcasecmp(tech, originator)) {
346 if (!(resource = strchr(tech,
'/'))) {
355 ast_verb(3,
"Destination '%s' has device state '%s'. Paging anyway.\n",
358 ast_verb(3,
"Destination '%s' has device state '%s'.\n",
374 ast_log(
LOG_ERROR,
"Failed to add %s/%s to outbound dial\n", tech, resource);
382 if (predial_callee) {
401 dial_list[pos++] = dial;
421 snprintf(confbridgeopts,
sizeof(confbridgeopts),
"%u", confid);
422 pbx_exec(chan, app, confbridgeopts);
426 for (i = 0; i < pos; i++) {
427 struct ast_dial *dial = dial_list[i];
458 .requires =
"app_confbridge",
const char * ast_devstate2str(enum ast_device_state devstate) attribute_pure
Convert device state to text string for output.
Main Channel structure associated with a channel.
ast_device_state
Device States.
int ast_dial_destroy(struct ast_dial *dial)
Destroys a dialing structure.
int ast_streamfile(struct ast_channel *c, const char *filename, const char *preflang)
Streams a file.
int ast_dial_option_global_enable(struct ast_dial *dial, enum ast_dial_option option, void *data)
Enables an option globally.
Asterisk main include file. File version handling, generic pbx functions.
static void setup_profile_caller(struct ast_channel *chan, struct page_options *options)
void * ast_dial_get_user_data(struct ast_dial *dial)
Return the user data on a dial structure.
int pbx_exec(struct ast_channel *c, struct ast_app *app, const char *data)
Execute an application.
Main dialing structure. Contains global options, channels being dialed, and more! ...
void ast_dial_set_global_timeout(struct ast_dial *dial, int timeout)
Set the maximum time (globally) allowed for trying to ring phones.
const char * ast_app_expand_sub_args(struct ast_channel *chan, const char *args)
Add missing context/exten to subroutine argument string.
#define ast_test_flag(p, flag)
void ast_dial_hangup(struct ast_dial *dial)
Hangup channels.
#define AST_STANDARD_APP_ARGS(args, parse)
Performs the 'standard' argument separation process for an application.
static const char *const app_page
Generic File Format Support. Should be included by clients of the file handling routines. File service providers should instead include mod_format.h.
int ast_unregister_application(const char *app)
Unregister an application.
char * opts[OPT_ARG_ARRAY_SIZE]
#define ast_verb(level,...)
#define ast_strlen_zero(foo)
void ast_dial_set_user_data(struct ast_dial *dial, void *user_data)
Set user data on a dial structure.
#define AST_APP_OPTIONS(holder, options...)
Declares an array of options for an application.
void ast_dial_set_state_callback(struct ast_dial *dial, ast_dial_state_callback callback)
Set a callback for state changes.
void ast_replace_subargument_delimiter(char *s)
Replace '^' in a string with ','.
General Asterisk PBX channel definitions.
enum ast_dial_result ast_dial_join(struct ast_dial *dial)
Cancel async thread.
char * ast_strip(char *s)
Strip leading/trailing whitespace from a string.
static int load_module(void)
static int unload_module(void)
long int ast_random(void)
#define ast_strdupa(s)
duplicate a string in memory from the stack
int ast_app_parse_options(const struct ast_app_option *options, struct ast_flags *flags, char **args, char *optstr)
Parses a string containing application options and sets flags/arguments.
enum ast_dial_result ast_dial_state(struct ast_dial *dial)
Return state of dial.
Core PBX routines and definitions.
enum ast_dial_result ast_dial_run(struct ast_dial *dial, struct ast_channel *chan, int async)
Execute dialing synchronously or asynchronously.
static void setup_profile_bridge(struct ast_channel *chan, struct page_options *options)
#define AST_APP_OPTION_ARG(option, flagno, argno)
Declares an application option that accepts an argument.
static void page_state_callback(struct ast_dial *dial)
int ast_dial_append(struct ast_dial *dial, const char *tech, const char *device, const struct ast_assigned_ids *assignedids)
Append a channel.
struct ast_channel * ast_dial_answered(struct ast_dial *dial)
Return channel that answered.
static void parse(struct mgcp_request *req)
#define ast_calloc(num, len)
A wrapper for calloc()
struct ast_dial * ast_dial_create(void)
New dialing structure.
Structure used to handle boolean flags.
AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_GLOBAL_SYMBOLS|AST_MODFLAG_LOAD_ORDER, "HTTP Phone Provisioning",.support_level=AST_MODULE_SUPPORT_EXTENDED,.load=load_module,.unload=unload_module,.reload=reload,.load_pri=AST_MODPRI_CHANNEL_DEPEND,.requires="http",)
char * strsep(char **str, const char *delims)
void ast_copy_string(char *dst, const char *src, size_t size)
Size-limited null-terminating string copy.
ast_app: A registered application
const char * ast_channel_name(const struct ast_channel *chan)
int ast_waitstream(struct ast_channel *c, const char *breakon)
Waits for a stream to stop or digit to be pressed.
int ast_fileexists(const char *filename, const char *fmt, const char *preflang)
Checks for the existence of a given file.
int ast_app_exec_sub(struct ast_channel *autoservice_chan, struct ast_channel *sub_chan, const char *sub_args, int ignore_hangup)
Run a subroutine on a channel, placing an optional second channel into autoservice.
const char * ast_channel_language(const struct ast_channel *chan)
#define AST_APP_OPTION(option, flagno)
Declares an application option that does not accept an argument.
static const struct ast_app_option page_opts[128]
struct ast_app * pbx_findapp(const char *app)
Look up an application.
#define ASTERISK_GPL_KEY
The text the key() function should return.
Asterisk module definitions.
static int page_exec(struct ast_channel *chan, const char *data)
int ast_func_write(struct ast_channel *chan, const char *function, const char *value)
executes a write operation on a function
static void setup_profile_paged(struct ast_channel *chan, struct page_options *options)
#define AST_DECLARE_APP_ARGS(name, arglist)
Declare a structure to hold an application's arguments.
Application convenience functions, designed to give consistent look and feel to Asterisk apps...
#define ast_register_application_xml(app, execute)
Register an application using XML documentation.
#define AST_APP_ARG(name)
Define an application argument.