|
Asterisk - The Open Source Telephony Project
18.5.0
|


Go to the source code of this file.
Macros | |
| #define | _ASTERISK_PHONEPROV_H |
Typedefs | |
| typedef int(* | ast_phoneprov_load_users_cb) (void) |
| Causes the provider to load its users. More... | |
Functions | |
| int | ast_phoneprov_add_extension (char *provider_name, struct varshead *vars) |
| Adds an extension. More... | |
| void | ast_phoneprov_delete_extension (char *provider_name, char *macaddress) |
| Deletes an extension. More... | |
| void | ast_phoneprov_delete_extensions (char *provider_name) |
| Deletes all extensions for this provider. More... | |
| int | ast_phoneprov_provider_register (char *provider_name, ast_phoneprov_load_users_cb load_users) |
| Registers a config provider to phoneprov. More... | |
| void | ast_phoneprov_provider_unregister (char *provider_name) |
| Unegisters a config provider from phoneprov and frees its resources. More... | |
| const char * | ast_phoneprov_std_variable_lookup (enum ast_phoneprov_std_variables var) |
| Returns the string respresentation of a phoneprov standard variable. More... | |
| #define _ASTERISK_PHONEPROV_H |
Definition at line 24 of file phoneprov.h.
| typedef int(* ast_phoneprov_load_users_cb) (void) |
Causes the provider to load its users.
This function is called by phoneprov in response to a ast_phoneprov_provider_register call by the provider. It may also be called by phoneprov to request a reload in response to the res_phoneprov module being reloaded.
| 0 | if successful |
| non-zero | if failure |
Definition at line 75 of file phoneprov.h.
Definition at line 29 of file phoneprov.h.
| int ast_phoneprov_add_extension | ( | char * | provider_name, |
| struct varshead * | vars | ||
| ) |
Adds an extension.
| provider_name | The name of the provider |
| defaults | An ast_vat_t linked list of the extension's variables. The list is automatically cloned and it must contain at least MACADDRESS and USERNAME entries. |
| 0 | if successful |
| non-zero | if failure |
Definition at line 1614 of file res_phoneprov.c.
Referenced by users_apply_handler().
| void ast_phoneprov_delete_extension | ( | char * | provider_name, |
| char * | macaddress | ||
| ) |
Deletes an extension.
| provider_name | The name of the provider |
| macaddress | The mac address of the extension |
Definition at line 1585 of file res_phoneprov.c.
References CMP_MATCH.
Referenced by phoneprov_destroy().
| void ast_phoneprov_delete_extensions | ( | char * | provider_name | ) |
Deletes all extensions for this provider.
| provider_name | The name of the provider |
Definition at line 1595 of file res_phoneprov.c.
| int ast_phoneprov_provider_register | ( | char * | provider_name, |
| ast_phoneprov_load_users_cb | load_users | ||
| ) |
Registers a config provider to phoneprov.
| provider_name | The name of the provider |
| load_users | Callback that gathers user variables then loads them by calling ast_phoneprov_add_extension once for each extension. |
| 0 | if successful |
| non-zero | if failure |
Definition at line 1514 of file res_phoneprov.c.
References ao2_alloc, ao2_link, ao2_ref, ast_log, ast_string_field_init, ast_string_field_set, ast_strlen_zero, find_provider(), phoneprov_provider::load_users, LOG_ERROR, LOG_WARNING, NULL, provider, provider_destructor(), var, and variable_lookup.
Referenced by load_module(), and reload_module().
| void ast_phoneprov_provider_unregister | ( | char * | provider_name | ) |
Unegisters a config provider from phoneprov and frees its resources.
| provider_name | The name of the provider |
Definition at line 1604 of file res_phoneprov.c.
References ao2_callback, extensions_delete_cb(), OBJ_MULTIPLE, OBJ_NODATA, and OBJ_UNLINK.
Referenced by reload_module(), and unload_module().
| const char* ast_phoneprov_std_variable_lookup | ( | enum ast_phoneprov_std_variables | var | ) |
Returns the string respresentation of a phoneprov standard variable.
| var | One of enum ast_phoneprov_std_variables |
Definition at line 1505 of file res_phoneprov.c.
Referenced by load_endpoint(), and users_apply_handler().
1.8.13