Fri Jul 24 00:41:59 2009

Asterisk developer's documentation


say.h File Reference

Say numbers and dates (maybe words one day too). More...

#include "asterisk/channel.h"
#include "asterisk/file.h"
#include <time.h>

Go to the source code of this file.

Defines

#define SAY_EXTERN   extern
#define SAY_INIT(x)
 The basic ast_say_* functions are implemented as function pointers, initialized to the function say_stub() which simply returns an error. Other interfaces, declared here as regular functions, are simply wrappers around the basic functions.

Functions

int ast_say_character_str (struct ast_channel *chan, const char *num, const char *ints, const char *lang)
int ast_say_counted_adjective (struct ast_channel *chan, int num, const char *adjective, const char *gender)
int ast_say_counted_noun (struct ast_channel *chan, int num, const char *noun)
int ast_say_digit_str (struct ast_channel *chan, const char *num, const char *ints, const char *lang)
int ast_say_digits (struct ast_channel *chan, int num, const char *ints, const char *lang)
int ast_say_digits_full (struct ast_channel *chan, int num, const char *ints, const char *lang, int audiofd, int ctrlfd)
int ast_say_enumeration (struct ast_channel *chan, int num, const char *ints, const char *lang, const char *options)
int ast_say_number (struct ast_channel *chan, int num, const char *ints, const char *lang, const char *options)
int ast_say_phonetic_str (struct ast_channel *chan, const char *num, const char *ints, const char *lang)

Variables

SAY_EXTERN int(*) ast_say_character_str_full (struct ast_channel *chan, const char *num, const char *ints, const char *lang, int audiofd, int ctrlfd) SAY_INIT(ast_say_character_str_full)
SAY_EXTERN int(*) ast_say_date (struct ast_channel *chan, time_t t, const char *ints, const char *lang) SAY_INIT(ast_say_date)
SAY_EXTERN int(*) ast_say_date_with_format (struct ast_channel *chan, time_t t, const char *ints, const char *lang, const char *format, const char *timezone) SAY_INIT(ast_say_date_with_format)
SAY_EXTERN int(*) ast_say_datetime (struct ast_channel *chan, time_t t, const char *ints, const char *lang) SAY_INIT(ast_say_datetime)
SAY_EXTERN int(*) ast_say_datetime_from_now (struct ast_channel *chan, time_t t, const char *ints, const char *lang) SAY_INIT(ast_say_datetime_from_now)
SAY_EXTERN int(*) ast_say_digit_str_full (struct ast_channel *chan, const char *num, const char *ints, const char *lang, int audiofd, int ctrlfd) SAY_INIT(ast_say_digit_str_full)
SAY_EXTERN int(*) ast_say_enumeration_full (struct ast_channel *chan, int num, const char *ints, const char *lang, const char *options, int audiofd, int ctrlfd) SAY_INIT(ast_say_enumeration_full)
SAY_EXTERN int(*) ast_say_full (struct ast_channel *chan, const char *num, const char *ints, const char *lang, const char *options, int audiofd, int ctrlfd) SAY_INIT(ast_say_full)
SAY_EXTERN int(*) ast_say_number_full (struct ast_channel *chan, int num, const char *ints, const char *lang, const char *options, int audiofd, int ctrlfd) SAY_INIT(ast_say_number_full)
SAY_EXTERN int(*) ast_say_phonetic_str_full (struct ast_channel *chan, const char *num, const char *ints, const char *lang, int audiofd, int ctrlfd) SAY_INIT(ast_say_phonetic_str_full)
SAY_EXTERN int(*) ast_say_time (struct ast_channel *chan, time_t t, const char *ints, const char *lang) SAY_INIT(ast_say_time)


Detailed Description

Say numbers and dates (maybe words one day too).

Definition in file say.h.


Define Documentation

#define SAY_EXTERN   extern

Definition at line 66 of file say.h.

#define SAY_INIT (  ) 

The basic ast_say_* functions are implemented as function pointers, initialized to the function say_stub() which simply returns an error. Other interfaces, declared here as regular functions, are simply wrappers around the basic functions.

An implementation of the basic ast_say functions (e.g. from say.c or from a dynamically loaded module) will just have to reassign the pointers to the relevant functions to override the previous implementation.

Todo:
XXX As the conversion from the old implementation of say.c to the new implementation will be completed, and the API suitably reworked by removing redundant functions and/or arguments, this mechanism may be reverted back to pure static functions, if needed.

Definition at line 65 of file say.h.


Function Documentation

int ast_say_character_str ( struct ast_channel chan,
const char *  num,
const char *  ints,
const char *  lang 
)

Definition at line 5458 of file channel.c.

References ast_say_character_str_full, and chan.

Referenced by common_exec(), pbx_builtin_saycharacters(), play_mailbox_owner(), rpt_tele_thread(), saycharstr(), and saynode().

05460 {
05461    return ast_say_character_str_full(chan, str, ints, lang, -1, -1);
05462 }

int ast_say_counted_adjective ( struct ast_channel chan,
int  num,
const char *  adjective,
const char *  gender 
)

int ast_say_counted_noun ( struct ast_channel chan,
int  num,
const char *  noun 
)

int ast_say_digit_str ( struct ast_channel chan,
const char *  num,
const char *  ints,
const char *  lang 
)

Definition at line 5452 of file channel.c.

References ast_say_digit_str_full, and chan.

Referenced by forward_message(), invent_message(), mgcp_ss(), pbx_builtin_saydigits(), play_message_callerid(), and ss_thread().

05454 {
05455    return ast_say_digit_str_full(chan, str, ints, lang, -1, -1);
05456 }

int ast_say_digits ( struct ast_channel chan,
int  num,
const char *  ints,
const char *  lang 
)

Definition at line 5446 of file channel.c.

References ast_say_digits_full(), and chan.

Referenced by ast_park_call_full(), common_exec(), conf_exec(), conf_run(), parkandannounce_exec(), and rpt_tele_thread().

05448 {
05449    return ast_say_digits_full(chan, num, ints, lang, -1, -1);
05450 }

int ast_say_digits_full ( struct ast_channel chan,
int  num,
const char *  ints,
const char *  lang,
int  audiofd,
int  ctrlfd 
)

Definition at line 5470 of file channel.c.

References ast_say_digit_str_full, and chan.

Referenced by ast_say_digits(), ast_say_enumeration_full_da(), ast_say_enumeration_full_de(), ast_say_number_full_cz(), ast_say_number_full_da(), ast_say_number_full_de(), ast_say_number_full_en(), ast_say_number_full_en_GB(), ast_say_number_full_es(), ast_say_number_full_fr(), ast_say_number_full_ge(), ast_say_number_full_he(), ast_say_number_full_hu(), ast_say_number_full_it(), ast_say_number_full_nl(), ast_say_number_full_no(), ast_say_number_full_pt(), ast_say_number_full_ru(), ast_say_number_full_se(), ast_say_number_full_th(), ast_say_number_full_tw(), and say_init_mode().

05472 {
05473    char buf[256];
05474 
05475    snprintf(buf, sizeof(buf), "%d", num);
05476 
05477    return ast_say_digit_str_full(chan, buf, ints, lang, audiofd, ctrlfd);
05478 }

int ast_say_enumeration ( struct ast_channel chan,
int  num,
const char *  ints,
const char *  lang,
const char *  options 
)

Definition at line 5440 of file channel.c.

References ast_say_enumeration_full, and chan.

Referenced by ast_say_date_da(), ast_say_date_de(), ast_say_date_with_format_da(), ast_say_date_with_format_de(), ast_say_date_with_format_en(), and ast_say_date_with_format_pl().

05442 {
05443    return ast_say_enumeration_full(chan, num, ints, language, options, -1, -1);
05444 }

int ast_say_number ( struct ast_channel chan,
int  num,
const char *  ints,
const char *  lang,
const char *  options 
)

Definition at line 5434 of file channel.c.

References ast_say_number_full, and chan.

Referenced by ast_say_date_da(), ast_say_date_de(), ast_say_date_en(), ast_say_date_fr(), ast_say_date_ge(), ast_say_date_gr(), ast_say_date_he(), ast_say_date_hu(), ast_say_date_nl(), ast_say_date_pt(), ast_say_date_th(), ast_say_date_with_format_da(), ast_say_date_with_format_de(), ast_say_date_with_format_en(), ast_say_date_with_format_es(), ast_say_date_with_format_fr(), ast_say_date_with_format_it(), ast_say_date_with_format_nl(), ast_say_date_with_format_pl(), ast_say_date_with_format_pt(), ast_say_date_with_format_th(), ast_say_datetime_en(), ast_say_datetime_fr(), ast_say_datetime_from_now_en(), ast_say_datetime_from_now_fr(), ast_say_datetime_from_now_ge(), ast_say_datetime_from_now_he(), ast_say_datetime_from_now_pt(), ast_say_datetime_he(), ast_say_datetime_pt(), ast_say_datetime_th(), ast_say_datetime_tw(), ast_say_time_de(), ast_say_time_en(), ast_say_time_fr(), ast_say_time_ge(), ast_say_time_gr(), ast_say_time_hu(), ast_say_time_nl(), ast_say_time_pt(), ast_say_time_pt_BR(), ast_say_time_th(), ast_say_time_tw(), bridge_playfile(), conf_exec(), conf_run(), count_exec(), dictate_exec(), get_folder(), gr_say_number_female(), pbx_builtin_saynumber(), play_message(), play_message_duration(), rpt_tele_thread(), say_and_wait(), say_position(), saynum(), try_calling(), vm_intro_gr(), vm_intro_he(), vm_intro_multilang(), vm_intro_pt(), and vm_intro_pt_BR().

05436 {
05437    return ast_say_number_full(chan, num, ints, language, options, -1, -1);
05438 }

int ast_say_phonetic_str ( struct ast_channel chan,
const char *  num,
const char *  ints,
const char *  lang 
)

Definition at line 5464 of file channel.c.

References ast_say_phonetic_str_full, and chan.

Referenced by pbx_builtin_sayphonetic().

05466 {
05467    return ast_say_phonetic_str_full(chan, str, ints, lang, -1, -1);
05468 }


Variable Documentation

SAY_EXTERN int(* ) ast_say_character_str_full(struct ast_channel *chan, const char *num, const char *ints, const char *lang, int audiofd, int ctrlfd) SAY_INIT(ast_say_character_str_full)

Definition at line 150 of file say.h.

Referenced by __say_init(), ast_say_character_str(), handle_sayalpha(), restore_say_mode(), save_say_mode(), and say_init_mode().

SAY_EXTERN int(* ) ast_say_date(struct ast_channel *chan, time_t t, const char *ints, const char *lang) SAY_INIT(ast_say_date)

Definition at line 160 of file say.h.

Referenced by __say_init(), ast_say_datetime_de(), ast_say_datetime_ge(), ast_say_datetime_hu(), ast_say_datetime_nl(), ast_say_datetime_pt_BR(), handle_saydate(), restore_say_mode(), save_say_mode(), and say_init_mode().

SAY_EXTERN int(* ) ast_say_date_with_format(struct ast_channel *chan, time_t t, const char *ints, const char *lang, const char *format, const char *timezone) SAY_INIT(ast_say_date_with_format)

Definition at line 164 of file say.h.

Referenced by __say_init(), ast_say_date_with_format_pl(), handle_saydatetime(), play_message_datetime(), restore_say_mode(), save_say_mode(), say_init_mode(), and sayunixtime_exec().

SAY_EXTERN int(* ) ast_say_datetime(struct ast_channel *chan, time_t t, const char *ints, const char *lang) SAY_INIT(ast_say_datetime)

Definition at line 157 of file say.h.

Referenced by __say_init(), restore_say_mode(), save_say_mode(), and say_init_mode().

SAY_EXTERN int(* ) ast_say_datetime_from_now(struct ast_channel *chan, time_t t, const char *ints, const char *lang) SAY_INIT(ast_say_datetime_from_now)

Definition at line 162 of file say.h.

Referenced by __say_init(), restore_say_mode(), save_say_mode(), and say_init_mode().

SAY_EXTERN int(* ) ast_say_digit_str_full(struct ast_channel *chan, const char *num, const char *ints, const char *lang, int audiofd, int ctrlfd) SAY_INIT(ast_say_digit_str_full)

Definition at line 136 of file say.h.

Referenced by __say_init(), ast_say_digit_str(), ast_say_digits_full(), handle_saydigits(), restore_say_mode(), save_say_mode(), and say_init_mode().

SAY_EXTERN int(* ) ast_say_enumeration_full(struct ast_channel *chan, int num, const char *ints, const char *lang, const char *options, int audiofd, int ctrlfd) SAY_INIT(ast_say_enumeration_full)

Definition at line 103 of file say.h.

Referenced by __say_init(), ast_say_enumeration(), restore_say_mode(), save_say_mode(), and say_init_mode().

SAY_EXTERN int(* ) ast_say_full(struct ast_channel *chan, const char *num, const char *ints, const char *lang, const char *options, int audiofd, int ctrlfd) SAY_INIT(ast_say_full)

Definition at line 142 of file say.h.

SAY_EXTERN int(* ) ast_say_number_full(struct ast_channel *chan, int num, const char *ints, const char *lang, const char *options, int audiofd, int ctrlfd) SAY_INIT(ast_say_number_full)

Definition at line 85 of file say.h.

Referenced by __say_init(), ast_say_number(), handle_saynumber(), restore_say_mode(), save_say_mode(), and say_init_mode().

SAY_EXTERN int(* ) ast_say_phonetic_str_full(struct ast_channel *chan, const char *num, const char *ints, const char *lang, int audiofd, int ctrlfd) SAY_INIT(ast_say_phonetic_str_full)

Definition at line 155 of file say.h.

Referenced by __say_init(), ast_say_phonetic_str(), handle_sayphonetic(), restore_say_mode(), save_say_mode(), and say_init_mode().

SAY_EXTERN int(* ) ast_say_time(struct ast_channel *chan, time_t t, const char *ints, const char *lang) SAY_INIT(ast_say_time)

Definition at line 158 of file say.h.

Referenced by __say_init(), ast_say_datetime_de(), ast_say_datetime_from_now_en(), ast_say_datetime_from_now_fr(), ast_say_datetime_from_now_ge(), ast_say_datetime_from_now_he(), ast_say_datetime_from_now_pt(), ast_say_datetime_ge(), ast_say_datetime_hu(), ast_say_datetime_nl(), ast_say_datetime_pt_BR(), handle_saytime(), restore_say_mode(), rpt_tele_thread(), save_say_mode(), and say_init_mode().


Generated on Fri Jul 24 00:41:59 2009 for Asterisk - the Open Source PBX by  doxygen 1.4.7