#include <asterisk.h>
#include <asterisk/lock.h>
#include <asterisk/linkedlists.h>
#include <asterisk/module.h>
#include <asterisk/utils.h>
#include <asterisk/options.h>
#include <asterisk/frame.h>
#include <asterisk/cli.h>
#include <asterisk/stringfields.h>
Go to the source code of this file.
Data Structures | |
struct | ast_fax_document |
struct | ast_fax_documents |
struct | ast_fax_session |
The data required to handle a fax session. More... | |
struct | ast_fax_session_details |
The data communicated between the high level applications and the generic fax function. More... | |
struct | ast_fax_t38_parameters |
struct | ast_fax_tech |
used to register a FAX technology module with res_fax More... | |
Enumerations | |
enum | ast_fax_capabilities { AST_FAX_TECH_SEND = (1 << 0), AST_FAX_TECH_RECEIVE = (1 << 1), AST_FAX_TECH_AUDIO = (1 << 2), AST_FAX_TECH_T38 = (1 << 3), AST_FAX_TECH_MULTI_DOC = (1 << 4) } |
capabilities for res_fax to locate a fax technology module More... | |
enum | ast_fax_modems { AST_FAX_MODEM_V17 = (1 << 0), AST_FAX_MODEM_V27 = (1 << 1), AST_FAX_MODEM_V29 = (1 << 2), AST_FAX_MODEM_V34 = (1 << 3) } |
fax modem capabilities More... | |
enum | ast_fax_optflag { AST_FAX_OPTFLAG_FALSE = 0, AST_FAX_OPTFLAG_TRUE, AST_FAX_OPTFLAG_DEFAULT } |
fax session options More... | |
enum | ast_fax_state { AST_FAX_STATE_UNINITIALIZED = 0, AST_FAX_STATE_INITIALIZED, AST_FAX_STATE_OPEN, AST_FAX_STATE_ACTIVE, AST_FAX_STATE_COMPLETE, AST_FAX_STATE_RESERVED, AST_FAX_STATE_INACTIVE } |
current state of a fax session More... | |
Functions | |
void | ast_fax_log (int level, const char *file, const int line, const char *function, const char *msg) |
Log message at FAX or recommended level. More... | |
unsigned int | ast_fax_maxrate (void) |
get the maxiumum supported fax rate More... | |
unsigned int | ast_fax_minrate (void) |
get the minimum supported fax rate More... | |
const char * | ast_fax_state_to_str (enum ast_fax_state state) |
convert an ast_fax_state to a string More... | |
int | ast_fax_tech_register (struct ast_fax_tech *tech) |
register a fax technology More... | |
void | ast_fax_tech_unregister (struct ast_fax_tech *tech) |
unregister a fax technology More... | |
enum ast_fax_capabilities |
capabilities for res_fax to locate a fax technology module
Definition at line 34 of file res_fax.h.
enum ast_fax_modems |
fax modem capabilities
Enumerator | |
---|---|
AST_FAX_MODEM_V17 |
V.17 |
AST_FAX_MODEM_V27 |
V.27 |
AST_FAX_MODEM_V29 |
V.29 |
AST_FAX_MODEM_V34 |
V.34 |
enum ast_fax_optflag |
fax session options
Enumerator | |
---|---|
AST_FAX_OPTFLAG_FALSE |
false/disable configuration override |
AST_FAX_OPTFLAG_TRUE |
true/enable configuration override |
AST_FAX_OPTFLAG_DEFAULT |
use the configured default |
enum ast_fax_state |
current state of a fax session
Definition at line 60 of file res_fax.h.
void ast_fax_log | ( | int | level, |
const char * | file, | ||
const int | line, | ||
const char * | function, | ||
const char * | msg | ||
) |
Log message at FAX or recommended level.
The first four parameters can be represented with Asterisk's LOG_* levels. In other words, this function may be called like
ast_fax_log(LOG_DEBUG, msg);
Definition at line 680 of file res_fax.c.
References ast_log(), and ast_log_dynamic_level.
Referenced by spandsp_log().
unsigned int ast_fax_maxrate | ( | void | ) |
get the maxiumum supported fax rate
Definition at line 444 of file res_fax.c.
References get_general_options(), and fax_options::maxrate.
Referenced by acf_faxopt_write().
unsigned int ast_fax_minrate | ( | void | ) |
get the minimum supported fax rate
Definition at line 452 of file res_fax.c.
References get_general_options(), and fax_options::minrate.
Referenced by acf_faxopt_write().
const char* ast_fax_state_to_str | ( | enum ast_fax_state | state | ) |
convert an ast_fax_state to a string
convert an ast_fax_state to a string
Definition at line 657 of file res_fax.c.
References AST_FAX_STATE_ACTIVE, AST_FAX_STATE_COMPLETE, AST_FAX_STATE_INACTIVE, AST_FAX_STATE_INITIALIZED, AST_FAX_STATE_OPEN, AST_FAX_STATE_RESERVED, AST_FAX_STATE_UNINITIALIZED, ast_log(), and LOG_WARNING.
Referenced by cli_fax_show_sessions(), spandsp_fax_cli_show_session(), and spandsp_fax_write().
int ast_fax_tech_register | ( | struct ast_fax_tech * | tech | ) |
register a fax technology
register a fax technology
Definition at line 616 of file res_fax.c.
References ast_calloc, ast_module_ref(), AST_RWLIST_INSERT_TAIL, AST_RWLIST_UNLOCK, AST_RWLIST_WRLOCK, ast_verb, ast_fax_tech::description, ast_module_info::self, fax_module::tech, and ast_fax_tech::type.
Referenced by load_module().
void ast_fax_tech_unregister | ( | struct ast_fax_tech * | tech | ) |
unregister a fax technology
unregister a fax technology
Definition at line 635 of file res_fax.c.
References ast_free, ast_module_unref(), AST_RWLIST_REMOVE_CURRENT, AST_RWLIST_TRAVERSE_SAFE_BEGIN, AST_RWLIST_TRAVERSE_SAFE_END, AST_RWLIST_UNLOCK, AST_RWLIST_WRLOCK, ast_verb, ast_module_info::self, fax_module::tech, and ast_fax_tech::type.
Referenced by unload_module().