git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@8254 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale
2008-05-02 19:04:13 +00:00
parent 388f439897
commit 8e0b64a1e6
10 changed files with 268 additions and 0 deletions
+23
View File
@@ -561,6 +561,29 @@ SWITCH_DECLARE(int) CoreSession::transfer(char *extension, char *dialplan, char
return status == SWITCH_STATUS_SUCCESS ? 1 : 0;
}
SWITCH_DECLARE(char *) CoreSession::read(int min_digits,
int max_digits,
const char *prompt_audio_file,
int timeout,
const char *valid_terminators)
{
if (min_digits < 1) {
min_digits = 1;
}
if (max_digits < 1) {
max_digits = 1;
}
if (timeout < 1) {
timeout = 1;
}
switch_ivr_read(session, min_digits, max_digits, prompt_audio_file, NULL, dtmf_buf, sizeof(dtmf_buf), timeout, valid_terminators);
return dtmf_buf;
}
SWITCH_DECLARE(char *) CoreSession::playAndGetDigits(int min_digits,
int max_digits,
int max_tries,