119 #include "asterisk/logger.h"
141 if (
args.argc != 2) {
146 if (sscanf(
args.number,
"%d", &number) != 1) {
147 ast_log(
LOG_WARNING,
"First argument must be a number between 0 and 2,147,483,647.\n");
165 ast_log(
LOG_WARNING,
"SayCountedAdj requires two or three arguments (<number>,<adjective>[,<gender>])\n");
177 if (sscanf(
args.number,
"%d", &number) != 1) {
178 ast_log(
LOG_WARNING,
"First argument must be a number between 0 and 2,147,483,647.\n");
183 if (strchr(
"cCfFmMnN",
args.gender[0])) {
184 ast_log(
LOG_WARNING,
"SayCountedAdj gender option must be one of 'f', 'm', 'c', or 'n'.\n");
Main Channel structure associated with a channel.
static int saycountedadj_exec(struct ast_channel *chan, const char *data)
#define AST_MODULE_INFO_STANDARD(keystr, desc)
static int unload_module(void)
Asterisk main include file. File version handling, generic pbx functions.
#define AST_DECLARE_APP_ARGS(name, arglist)
Declare a structure to hold an application's arguments.
int ast_unregister_application(const char *app)
Unregister an application.
int ast_say_counted_noun(struct ast_channel *chan, int num, const char *noun)
static force_inline int attribute_pure ast_strlen_zero(const char *s)
static int load_module(void)
#define ast_strdupa(s)
duplicate a string in memory from the stack
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 i...
int ast_say_counted_adjective(struct ast_channel *chan, int num, const char *adjective, const char *gender)
static void parse(struct mgcp_request *req)
Application convenience functions, designed to give consistent look and feel to Asterisk apps...
#define AST_APP_ARG(name)
Define an application argument.
#define AST_STANDARD_APP_ARGS(args, parse)
Performs the 'standard' argument separation process for an application.
Say numbers and dates (maybe words one day too)
#define ASTERISK_GPL_KEY
The text the key() function should return.
Asterisk module definitions.
#define ast_register_application_xml(app, execute)
Register an application using XML documentation.
#define ASTERISK_FILE_VERSION(file, version)
Register/unregister a source code file with the core.
static int saycountednoun_exec(struct ast_channel *chan, const char *data)