add session.hangupCause()

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@14912 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale
2009-09-17 23:28:38 +00:00
parent 3aeeda1d69
commit c54f0c3945
12 changed files with 668 additions and 58 deletions
+108 -17
View File
@@ -2506,23 +2506,24 @@ SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int argnum, int flags)
#define SWIGTYPE_p_char swig_types[8]
#define SWIGTYPE_p_input_callback_state swig_types[9]
#define SWIGTYPE_p_session_flag_t swig_types[10]
#define SWIGTYPE_p_switch_channel_state_t swig_types[11]
#define SWIGTYPE_p_switch_channel_t swig_types[12]
#define SWIGTYPE_p_switch_core_session_t swig_types[13]
#define SWIGTYPE_p_switch_event_node_t swig_types[14]
#define SWIGTYPE_p_switch_event_t swig_types[15]
#define SWIGTYPE_p_switch_event_types_t swig_types[16]
#define SWIGTYPE_p_switch_input_args_t swig_types[17]
#define SWIGTYPE_p_switch_input_type_t swig_types[18]
#define SWIGTYPE_p_switch_priority_t swig_types[19]
#define SWIGTYPE_p_switch_queue_t swig_types[20]
#define SWIGTYPE_p_switch_state_handler_table_t swig_types[21]
#define SWIGTYPE_p_switch_status_t swig_types[22]
#define SWIGTYPE_p_switch_stream_handle_t swig_types[23]
#define SWIGTYPE_p_uint32_t swig_types[24]
#define SWIGTYPE_p_void swig_types[25]
static swig_type_info *swig_types[27];
static swig_module_info swig_module = {swig_types, 26, 0, 0, 0, 0};
#define SWIGTYPE_p_switch_call_cause_t swig_types[11]
#define SWIGTYPE_p_switch_channel_state_t swig_types[12]
#define SWIGTYPE_p_switch_channel_t swig_types[13]
#define SWIGTYPE_p_switch_core_session_t swig_types[14]
#define SWIGTYPE_p_switch_event_node_t swig_types[15]
#define SWIGTYPE_p_switch_event_t swig_types[16]
#define SWIGTYPE_p_switch_event_types_t swig_types[17]
#define SWIGTYPE_p_switch_input_args_t swig_types[18]
#define SWIGTYPE_p_switch_input_type_t swig_types[19]
#define SWIGTYPE_p_switch_priority_t swig_types[20]
#define SWIGTYPE_p_switch_queue_t swig_types[21]
#define SWIGTYPE_p_switch_state_handler_table_t swig_types[22]
#define SWIGTYPE_p_switch_status_t swig_types[23]
#define SWIGTYPE_p_switch_stream_handle_t swig_types[24]
#define SWIGTYPE_p_uint32_t swig_types[25]
#define SWIGTYPE_p_void swig_types[26]
static swig_type_info *swig_types[28];
static swig_module_info swig_module = {swig_types, 27, 0, 0, 0, 0};
#define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
#define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
@@ -5983,6 +5984,67 @@ fail:
}
SWIGINTERN PyObject *_wrap_CoreSession_cause_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
CoreSession *arg1 = (CoreSession *) 0 ;
switch_call_cause_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 ;
int res2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
if (!PyArg_ParseTuple(args,(char *)"OO:CoreSession_cause_set",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_CoreSession, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CoreSession_cause_set" "', argument " "1"" of type '" "CoreSession *""'");
}
arg1 = reinterpret_cast< CoreSession * >(argp1);
{
res2 = SWIG_ConvertPtr(obj1, &argp2, SWIGTYPE_p_switch_call_cause_t, 0 | 0);
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "CoreSession_cause_set" "', argument " "2"" of type '" "switch_call_cause_t""'");
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "CoreSession_cause_set" "', argument " "2"" of type '" "switch_call_cause_t""'");
} else {
switch_call_cause_t * temp = reinterpret_cast< switch_call_cause_t * >(argp2);
arg2 = *temp;
if (SWIG_IsNewObj(res2)) delete temp;
}
}
if (arg1) (arg1)->cause = arg2;
resultobj = SWIG_Py_Void();
return resultobj;
fail:
return NULL;
}
SWIGINTERN PyObject *_wrap_CoreSession_cause_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
CoreSession *arg1 = (CoreSession *) 0 ;
switch_call_cause_t result;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
if (!PyArg_ParseTuple(args,(char *)"O:CoreSession_cause_get",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_CoreSession, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CoreSession_cause_get" "', argument " "1"" of type '" "CoreSession *""'");
}
arg1 = reinterpret_cast< CoreSession * >(argp1);
result = ((arg1)->cause);
resultobj = SWIG_NewPointerObj((new switch_call_cause_t(static_cast< const switch_call_cause_t& >(result))), SWIGTYPE_p_switch_call_cause_t, SWIG_POINTER_OWN | 0 );
return resultobj;
fail:
return NULL;
}
SWIGINTERN PyObject *_wrap_CoreSession_uuid_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
CoreSession *arg1 = (CoreSession *) 0 ;
@@ -6769,6 +6831,28 @@ fail:
}
SWIGINTERN PyObject *_wrap_CoreSession_hangupCause(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
CoreSession *arg1 = (CoreSession *) 0 ;
char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
if (!PyArg_ParseTuple(args,(char *)"O:CoreSession_hangupCause",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_CoreSession, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CoreSession_hangupCause" "', argument " "1"" of type '" "CoreSession *""'");
}
arg1 = reinterpret_cast< CoreSession * >(argp1);
result = (char *)(arg1)->hangupCause();
resultobj = SWIG_FromCharPtr((const char *)result);
return resultobj;
fail:
return NULL;
}
SWIGINTERN PyObject *_wrap_CoreSession_recordFile__SWIG_0(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
CoreSession *arg1 = (CoreSession *) 0 ;
@@ -10251,6 +10335,8 @@ static PyMethodDef SwigMethods[] = {
{ (char *)"CoreSession_cb_state_get", _wrap_CoreSession_cb_state_get, METH_VARARGS, NULL},
{ (char *)"CoreSession_hook_state_set", _wrap_CoreSession_hook_state_set, METH_VARARGS, NULL},
{ (char *)"CoreSession_hook_state_get", _wrap_CoreSession_hook_state_get, METH_VARARGS, NULL},
{ (char *)"CoreSession_cause_set", _wrap_CoreSession_cause_set, METH_VARARGS, NULL},
{ (char *)"CoreSession_cause_get", _wrap_CoreSession_cause_get, METH_VARARGS, NULL},
{ (char *)"CoreSession_uuid_set", _wrap_CoreSession_uuid_set, METH_VARARGS, NULL},
{ (char *)"CoreSession_uuid_get", _wrap_CoreSession_uuid_get, METH_VARARGS, NULL},
{ (char *)"CoreSession_tts_name_set", _wrap_CoreSession_tts_name_set, METH_VARARGS, NULL},
@@ -10267,6 +10353,7 @@ static PyMethodDef SwigMethods[] = {
{ (char *)"CoreSession_process_callback_result", _wrap_CoreSession_process_callback_result, METH_VARARGS, NULL},
{ (char *)"CoreSession_say", _wrap_CoreSession_say, METH_VARARGS, NULL},
{ (char *)"CoreSession_sayPhrase", _wrap_CoreSession_sayPhrase, METH_VARARGS, NULL},
{ (char *)"CoreSession_hangupCause", _wrap_CoreSession_hangupCause, METH_VARARGS, NULL},
{ (char *)"CoreSession_recordFile", _wrap_CoreSession_recordFile, METH_VARARGS, NULL},
{ (char *)"CoreSession_setCallerData", _wrap_CoreSession_setCallerData, METH_VARARGS, NULL},
{ (char *)"CoreSession_originate", _wrap_CoreSession_originate, METH_VARARGS, NULL},
@@ -10348,6 +10435,7 @@ static swig_type_info _swigt__p_Stream = {"_p_Stream", "Stream *", 0, 0, (void*)
static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_input_callback_state = {"_p_input_callback_state", "input_callback_state_t *|input_callback_state *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_session_flag_t = {"_p_session_flag_t", "enum session_flag_t *|session_flag_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_switch_call_cause_t = {"_p_switch_call_cause_t", "switch_call_cause_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_switch_channel_state_t = {"_p_switch_channel_state_t", "switch_channel_state_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_switch_channel_t = {"_p_switch_channel_t", "switch_channel_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_switch_core_session_t = {"_p_switch_core_session_t", "switch_core_session_t *", 0, 0, (void*)0, 0};
@@ -10376,6 +10464,7 @@ static swig_type_info *swig_type_initial[] = {
&_swigt__p_char,
&_swigt__p_input_callback_state,
&_swigt__p_session_flag_t,
&_swigt__p_switch_call_cause_t,
&_swigt__p_switch_channel_state_t,
&_swigt__p_switch_channel_t,
&_swigt__p_switch_core_session_t,
@@ -10404,6 +10493,7 @@ static swig_cast_info _swigc__p_Stream[] = { {&_swigt__p_Stream, 0, 0, 0},{0, 0
static swig_cast_info _swigc__p_char[] = { {&_swigt__p_char, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_input_callback_state[] = { {&_swigt__p_input_callback_state, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_session_flag_t[] = { {&_swigt__p_session_flag_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_switch_call_cause_t[] = { {&_swigt__p_switch_call_cause_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_switch_channel_state_t[] = { {&_swigt__p_switch_channel_state_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_switch_channel_t[] = { {&_swigt__p_switch_channel_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_switch_core_session_t[] = { {&_swigt__p_switch_core_session_t, 0, 0, 0},{0, 0, 0, 0}};
@@ -10432,6 +10522,7 @@ static swig_cast_info *swig_cast_initial[] = {
_swigc__p_char,
_swigc__p_input_callback_state,
_swigc__p_session_flag_t,
_swigc__p_switch_call_cause_t,
_swigc__p_switch_channel_state_t,
_swigc__p_switch_channel_t,
_swigc__p_switch_core_session_t,