Asterisk - The Open Source Telephony Project GIT-master-f36a736
|
#include "asterisk.h"
#include "asterisk/ast_expr.h"
#include "asterisk/inline_api.h"
#include "asterisk/lock.h"
Go to the source code of this file.
Data Structures | |
struct | varz |
Macros | |
#define | AST_API_MODULE 1 |
#define | AST_API_MODULE 1 |
#define | ASTMM_LIBC ASTMM_IGNORE |
Enumerations | |
enum | ast_lock_type { AST_MUTEX , AST_RDLOCK , AST_WRLOCK } |
Functions | |
int | ast_add_profile (const char *x, uint64_t scale) |
support for event profiling More... | |
struct ast_custom_function * | ast_custom_function_find (const char *name) |
void | ast_log (int level, const char *file, int line, const char *function, const char *fmt,...) |
Used for sending a log message This is the standard logger function. Probably the only way you will invoke it would be something like this: ast_log(AST_LOG_WHATEVER, "Problem with the %s Captain. We should get some more. Will %d be enough?\n", "flux capacitor", 10); where WHATEVER is one of ERROR, DEBUG, EVENT, NOTICE, or WARNING depending on which log you wish to output to. These are implemented as macros, that will provide the function with the needed arguments. More... | |
int | check_eval (char *buffer, char *error_report) |
unsigned int | check_expr (char *buffer, char *error_report) |
char * | find_var (const char *varname) |
int | main (int argc, char **argv) |
void | parse_file (const char *fname) |
void | set_var (const char *varname, const char *varval) |
Variables | |
static int | global_expr_count =0 |
static int | global_expr_max_size =0 |
static int | global_expr_tot_size =0 |
static int | global_lineno = 1 |
static int | global_OK_count =0 |
struct varz * | global_varlist |
static int | global_warn_count =0 |
#define AST_API_MODULE 1 |
Definition at line 31 of file check_expr.c.
#define AST_API_MODULE 1 |
Definition at line 31 of file check_expr.c.
#define ASTMM_LIBC ASTMM_IGNORE |
Definition at line 23 of file check_expr.c.
enum ast_lock_type |
Enumerator | |
---|---|
AST_MUTEX | |
AST_RDLOCK | |
AST_WRLOCK |
Definition at line 35 of file check_expr.c.
int ast_add_profile | ( | const char * | x, |
uint64_t | scale | ||
) |
support for event profiling
(note, this must be documented a lot more) ast_add_profile allocates a generic 'counter' with a given name, which can be shown with the command 'core show profile <name>'
The counter accumulates positive or negative values supplied by
support for event profiling
Definition at line 139 of file check_expr.c.
Referenced by extension_match_core().
struct ast_custom_function * ast_custom_function_find | ( | const char * | name | ) |
Definition at line 237 of file check_expr.c.
Referenced by ast_compile_ael2(), AST_TEST_DEFINE(), chanavail_exec(), config_curl(), destroy_curl(), op_func(), realtime_curl(), realtime_multi_curl(), require_curl(), store_curl(), update2_curl(), and update_curl().
void ast_log | ( | int | level, |
const char * | file, | ||
int | line, | ||
const char * | function, | ||
const char * | fmt, | ||
... | |||
) |
Used for sending a log message This is the standard logger function. Probably the only way you will invoke it would be something like this: ast_log(AST_LOG_WHATEVER, "Problem with the %s Captain. We should get some more. Will %d be enough?\n", "flux capacitor", 10); where WHATEVER is one of ERROR, DEBUG, EVENT, NOTICE, or WARNING depending on which log you wish to output to. These are implemented as macros, that will provide the function with the needed arguments.
level | Type of log event |
file | Will be provided by the AST_LOG_* macro |
line | Will be provided by the AST_LOG_* macro |
function | Will be provided by the AST_LOG_* macro |
fmt | This is what is important. The format is the same as your favorite breed of printf. You know how that works, right? :-) |
Definition at line 121 of file check_expr.c.
References make_ari_stubs::file.
int check_eval | ( | char * | buffer, |
char * | error_report | ||
) |
Definition at line 242 of file check_expr.c.
References ast_expr(), find_var(), global_lineno, NULL, and result.
Referenced by parse_file().
unsigned int check_expr | ( | char * | buffer, |
char * | error_report | ||
) |
Definition at line 165 of file check_expr.c.
References global_lineno, and global_warn_count.
Referenced by parse_file().
char * find_var | ( | const char * | varname | ) |
Definition at line 141 of file check_expr.c.
References global_varlist, varz::next, varz::varname, and varz::varval.
Referenced by check_eval().
int main | ( | int | argc, |
char ** | argv | ||
) |
Definition at line 406 of file check_expr.c.
References global_varlist, parse_file(), and set_var().
void parse_file | ( | const char * | fname | ) |
Definition at line 315 of file check_expr.c.
References check_eval(), check_expr(), global_expr_count, global_expr_max_size, global_expr_tot_size, global_lineno, global_OK_count, global_warn_count, and retval.
Referenced by main().
void set_var | ( | const char * | varname, |
const char * | varval | ||
) |
Definition at line 154 of file check_expr.c.
References calloc, global_varlist, varz::next, varz::varname, and varz::varval.
Referenced by main().
|
static |
Definition at line 102 of file check_expr.c.
Referenced by parse_file().
|
static |
Definition at line 103 of file check_expr.c.
Referenced by parse_file().
|
static |
Definition at line 104 of file check_expr.c.
Referenced by parse_file().
|
static |
Definition at line 101 of file check_expr.c.
Referenced by check_eval(), check_expr(), and parse_file().
|
static |
Definition at line 106 of file check_expr.c.
Referenced by parse_file().
struct varz* global_varlist |
Definition at line 115 of file check_expr.c.
Referenced by find_var(), main(), and set_var().
|
static |
Definition at line 105 of file check_expr.c.
Referenced by check_expr(), and parse_file().