67 static const char app[] =
"DumpChan";
71 long elapsed_seconds = 0;
72 int hour = 0,
min = 0, sec = 0;
85 hour = elapsed_seconds / 3600;
86 min = (elapsed_seconds % 3600) / 60;
87 sec = elapsed_seconds % 60;
98 "ConnectedLineIDNum= %s\n" 99 "ConnectedLineIDName=%s\n" 109 "RawWriteFormat= %s\n" 110 "RawReadFormat= %s\n" 111 "WriteTranscode= %s %s\n" 112 "ReadTranscode= %s %s\n" 113 "1stFileDescriptor= %d\n" 116 "TimetoHangup= %ld\n" 117 "ElapsedTime= %dh%dm%ds\n" 158 bridge ? bridge->
uniqueid :
"(Not bridged)",
177 static char *line =
"================================================================================";
186 "Dumping Info For Channel: %s:\n" struct ast_party_caller * ast_channel_caller(struct ast_channel *chan)
const char * ast_channel_blockproc(const struct ast_channel *chan)
#define ast_channel_lock(chan)
Main Channel structure associated with a channel.
#define AST_MODULE_INFO_STANDARD(keystr, desc)
Asterisk main include file. File version handling, generic pbx functions.
const ast_string_field uniqueid
static int load_module(void)
#define ast_test_flag(p, flag)
unsigned int ast_channel_fout(const struct ast_channel *chan)
Support for translation of data formats. translate.c.
static int dumpchan_exec(struct ast_channel *chan, const char *data)
char * ast_str_buffer(const struct ast_str *buf)
Returns the string buffer within the ast_str buf.
#define VERBOSITY_ATLEAST(level)
static int unload_module(void)
ast_channel_state
ast_channel states
static int serialize_showchan(struct ast_channel *c, char *buf, size_t size)
#define ast_str_alloca(init_len)
const char * ast_state2str(enum ast_channel_state)
Gives the string form of a given channel state.
int ast_unregister_application(const char *app)
Unregister an application.
int ast_channel_priority(const struct ast_channel *chan)
#define ast_verb(level,...)
struct ast_trans_pvt * ast_channel_readtrans(const struct ast_channel *chan)
const char * ast_channel_linkedid(const struct ast_channel *chan)
char * ast_print_group(char *buf, int buflen, ast_group_t group)
Print call and pickup groups into buffer.
#define ast_strlen_zero(foo)
struct timeval * ast_channel_whentohangup(struct ast_channel *chan)
struct ast_format * ast_channel_readformat(struct ast_channel *chan)
struct ast_bridge * ast_channel_get_bridge(const struct ast_channel *chan)
Get the bridge associated with a channel.
unsigned int ast_channel_fin(const struct ast_channel *chan)
General Asterisk PBX channel definitions.
struct ast_trans_pvt * ast_channel_writetrans(const struct ast_channel *chan)
struct ast_party_connected_line * ast_channel_connected(struct ast_channel *chan)
#define S_COR(a, b, c)
returns the equivalent of logic or for strings, with an additional boolean check: second one if not e...
const char * ast_channel_exten(const struct ast_channel *chan)
Core PBX routines and definitions.
const char * ast_channel_uniqueid(const struct ast_channel *chan)
Structure that contains information about a bridge.
struct ast_format * ast_channel_rawreadformat(struct ast_channel *chan)
The descriptor of a dynamic string XXX storage will be optimized later if needed We use the ts field ...
struct ast_party_dialed * ast_channel_dialed(struct ast_channel *chan)
const char * ast_channel_appl(const struct ast_channel *chan)
#define ast_channel_unlock(chan)
int ast_channel_get_duration(struct ast_channel *chan)
Obtain how long the channel since the channel was created.
struct ast_party_redirecting * ast_channel_redirecting(struct ast_channel *chan)
struct ast_format_cap * ast_channel_nativeformats(const struct ast_channel *chan)
const char * ast_channel_data(const struct ast_channel *chan)
int ast_channel_fd(const struct ast_channel *chan, int which)
const char * ast_translate_path_to_str(struct ast_trans_pvt *t, struct ast_str **str)
Puts a string representation of the translation path into outbuf.
#define S_OR(a, b)
returns the equivalent of logic or for strings: first one if not empty, otherwise second one...
const char * ast_channel_name(const struct ast_channel *chan)
const char * ast_channel_language(const struct ast_channel *chan)
ast_group_t ast_channel_pickupgroup(const struct ast_channel *chan)
const char * ast_channel_context(const struct ast_channel *chan)
int ast_channel_rings(const struct ast_channel *chan)
struct ast_str * ast_str_thread_get(struct ast_threadstorage *ts, size_t init_len)
Retrieve a thread locally stored dynamic string.
ast_group_t ast_channel_callgroup(const struct ast_channel *chan)
struct ast_flags * ast_channel_flags(struct ast_channel *chan)
#define ASTERISK_GPL_KEY
The text the key() function should return.
Asterisk module definitions.
struct ast_format * ast_channel_writeformat(struct ast_channel *chan)
Application convenience functions, designed to give consistent look and feel to Asterisk apps...
struct ast_format * ast_channel_rawwriteformat(struct ast_channel *chan)
const struct ast_channel_tech * ast_channel_tech(const struct ast_channel *chan)
const char * ast_channel_parkinglot(const struct ast_channel *chan)
#define ast_register_application_xml(app, execute)
Register an application using XML documentation.
int pbx_builtin_serialize_variables(struct ast_channel *chan, struct ast_str **buf)
Create a human-readable string, specifying all variables and their corresponding values.