@@ -237,14 +237,14 @@ public function record($record) {
237
237
} else {
238
238
$ transcription = $ params ["transcription " ];
239
239
}
240
- $ p = array ('attempts ' , 'bargein ' , 'beep ' , 'format ' , 'maxTime ' , 'maxSilence ' , 'method ' , 'password ' , 'required ' , 'timeout ' , 'username ' , 'url ' , 'allowSignals ' );
240
+ $ p = array ('attempts ' , 'allowSignals ' , ' bargein ' , 'beep ' , 'format ' , 'maxTime ' , 'maxSilence ' , 'method ' , 'password ' , 'required ' , 'timeout ' , 'username ' , 'url ' , 'voice ' );
241
241
foreach ($ p as $ option ) {
242
242
$ $ option = null ;
243
243
if (is_array ($ params ) && array_key_exists ($ option , $ params )) {
244
244
$ $ option = $ params [$ option ];
245
245
}
246
246
}
247
- $ record = new Record ($ attempts , $ bargein , $ beep , $ choices , $ format , $ maxSilence , $ maxTime , $ method , $ password , $ required , $ say , $ timeout , $ transcription , $ username , $ url , $ allowSignals );
247
+ $ record = new Record ($ attempts , $ allowSignals , $ bargein , $ beep , $ choices , $ format , $ maxSilence , $ maxTime , $ method , $ password , $ required , $ say , $ timeout , $ transcription , $ username , $ url , $ voice );
248
248
}
249
249
$ this ->record = sprintf ($ record );
250
250
}
@@ -1005,6 +1005,7 @@ public function __toString() {
1005
1005
class Record extends BaseClass {
1006
1006
1007
1007
private $ _attempts ;
1008
+ private $ _allowSignals ;
1008
1009
private $ _bargein ;
1009
1010
private $ _beep ;
1010
1011
private $ _choices ;
@@ -1018,13 +1019,15 @@ class Record extends BaseClass {
1018
1019
private $ _timeout ;
1019
1020
private $ _transcription ;
1020
1021
private $ _username ;
1021
- private $ _url ;
1022
- private $ _allowSignals ;
1022
+ private $ _url ;
1023
+ private $ _voice ;
1024
+
1023
1025
1024
1026
/**
1025
1027
* Class constructor
1026
1028
*
1027
1029
* @param int $attempts
1030
+ * @param string|array $allowSignals
1028
1031
* @param boolean $bargein
1029
1032
* @param boolean $beep
1030
1033
* @param Choices $choices
@@ -1037,10 +1040,11 @@ class Record extends BaseClass {
1037
1040
* @param int $timeout
1038
1041
* @param string $username
1039
1042
* @param string $url
1040
- * @param string|array $allowSignals
1043
+ * @param string $voice
1041
1044
*/
1042
- public function __construct ($ attempts =NULL , $ bargein =NULL , $ beep =NULL , Choices $ choices =NULL , $ format =NULL , $ maxSilence =NULL , $ maxTime =NULL , $ method =NULL , $ password =NULL , $ required =NULL , $ say =NULL , $ timeout =NULL , Transcription $ transcription =NULL , $ username =NULL , $ url =NULL , $ allowSignals =NULL ) {
1045
+ public function __construct ($ attempts =NULL , $ allowSignals = NULL , $ bargein =NULL , $ beep =NULL , Choices $ choices =NULL , $ format =NULL , $ maxSilence =NULL , $ maxTime =NULL , $ method =NULL , $ password =NULL , $ required =NULL , $ say =NULL , $ timeout =NULL , Transcription $ transcription =NULL , $ username =NULL , $ url =NULL , $ voice =NULL ) {
1043
1046
$ this ->_attempts = $ attempts ;
1047
+ $ this ->_allowSignals = $ allowSignals ;
1044
1048
$ this ->_bargein = $ bargein ;
1045
1049
$ this ->_beep = $ beep ;
1046
1050
$ this ->_choices = isset ($ choices ) ? sprintf ($ choices ) : null ;
@@ -1057,7 +1061,7 @@ public function __construct($attempts=NULL, $bargein=NULL, $beep=NULL, Choices $
1057
1061
$ this ->_transcription = isset ($ transcription ) ? sprintf ($ transcription ) : null ;
1058
1062
$ this ->_username = $ username ;
1059
1063
$ this ->_url = $ url ;
1060
- $ this ->_allowSignals = $ allowSignals ;
1064
+ $ this ->_voice = $ voice ;
1061
1065
}
1062
1066
1063
1067
/**
@@ -1066,6 +1070,7 @@ public function __construct($attempts=NULL, $bargein=NULL, $beep=NULL, Choices $
1066
1070
*/
1067
1071
public function __toString () {
1068
1072
if (isset ($ this ->_attempts )) { $ this ->attempts = $ this ->_attempts ; }
1073
+ if (isset ($ this ->_allowSignals )) { $ this ->allowSignals = $ this ->_allowSignals ; }
1069
1074
if (isset ($ this ->_bargein )) { $ this ->bargein = $ this ->_bargein ; }
1070
1075
if (isset ($ this ->_beep )) { $ this ->beep = $ this ->_beep ; }
1071
1076
if (isset ($ this ->_choices )) { $ this ->choices = $ this ->_choices ; }
@@ -1079,7 +1084,7 @@ public function __toString() {
1079
1084
if (isset ($ this ->_transcription )) { $ this ->transcription = $ this ->_transcription ; }
1080
1085
if (isset ($ this ->_username )) { $ this ->username = $ this ->_username ; }
1081
1086
if (isset ($ this ->_url )) { $ this ->url = $ this ->_url ; }
1082
- if (isset ($ this ->_allowSignals )) { $ this ->allowSignals = $ this ->_allowSignals ; }
1087
+ if (isset ($ this ->_voice )) { $ this ->voice = $ this ->_voice ; }
1083
1088
return $ this ->unescapeJSON (json_encode ($ this ));
1084
1089
}
1085
1090
}
@@ -1131,6 +1136,7 @@ class Reject extends EmptyBaseClass { }
1131
1136
class Result {
1132
1137
1133
1138
private $ _sessionId ;
1139
+ private $ _callId ;
1134
1140
private $ _state ;
1135
1141
private $ _sessionDuration ;
1136
1142
private $ _sequence ;
@@ -1165,6 +1171,7 @@ public function __construct($json=NULL) {
1165
1171
throw new TropoException ('Not a result object. ' );
1166
1172
}
1167
1173
$ this ->_sessionId = $ result ->result ->sessionId ;
1174
+ $ this ->_callId = $ result ->result ->callId ;
1168
1175
$ this ->_state = $ result ->result ->state ;
1169
1176
$ this ->_sessionDuration = $ result ->result ->sessionDuration ;
1170
1177
$ this ->_sequence = $ result ->result ->sequence ;
@@ -1186,6 +1193,10 @@ function getSessionId() {
1186
1193
return $ this ->_sessionId ;
1187
1194
}
1188
1195
1196
+ function getCallId () {
1197
+ return $ this ->_callId ;
1198
+ }
1199
+
1189
1200
function getState () {
1190
1201
return $ this ->_state ;
1191
1202
}
0 commit comments