mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-07-05 03:41:53 +00:00
fix eventConsumer issue and add flush() method
This commit is contained in:
@@ -2505,24 +2505,25 @@ SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int argnum, int flags)
|
||||
#define SWIGTYPE_p_Stream swig_types[7]
|
||||
#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_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_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_p_switch_event_node_t swig_types[10]
|
||||
#define SWIGTYPE_p_session_flag_t swig_types[11]
|
||||
#define SWIGTYPE_p_switch_call_cause_t swig_types[12]
|
||||
#define SWIGTYPE_p_switch_channel_state_t swig_types[13]
|
||||
#define SWIGTYPE_p_switch_channel_t swig_types[14]
|
||||
#define SWIGTYPE_p_switch_core_session_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)
|
||||
|
||||
@@ -5028,6 +5029,126 @@ fail:
|
||||
}
|
||||
|
||||
|
||||
SWIGINTERN PyObject *_wrap_EventConsumer_enodes_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
|
||||
PyObject *resultobj = 0;
|
||||
EventConsumer *arg1 = (EventConsumer *) 0 ;
|
||||
switch_event_node_t **arg2 ;
|
||||
void *argp1 = 0 ;
|
||||
int res1 = 0 ;
|
||||
void *argp2 = 0 ;
|
||||
int res2 = 0 ;
|
||||
PyObject * obj0 = 0 ;
|
||||
PyObject * obj1 = 0 ;
|
||||
|
||||
if (!PyArg_ParseTuple(args,(char *)"OO:EventConsumer_enodes_set",&obj0,&obj1)) SWIG_fail;
|
||||
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_EventConsumer, 0 | 0 );
|
||||
if (!SWIG_IsOK(res1)) {
|
||||
SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventConsumer_enodes_set" "', argument " "1"" of type '" "EventConsumer *""'");
|
||||
}
|
||||
arg1 = reinterpret_cast< EventConsumer * >(argp1);
|
||||
res2 = SWIG_ConvertPtr(obj1, &argp2,SWIGTYPE_p_p_switch_event_node_t, 0 | 0 );
|
||||
if (!SWIG_IsOK(res2)) {
|
||||
SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "EventConsumer_enodes_set" "', argument " "2"" of type '" "switch_event_node_t *[SWITCH_EVENT_ALL+1]""'");
|
||||
}
|
||||
arg2 = reinterpret_cast< switch_event_node_t ** >(argp2);
|
||||
{
|
||||
if (arg2) {
|
||||
size_t ii = 0;
|
||||
for (; ii < (size_t)SWITCH_EVENT_ALL+1; ++ii) arg1->enodes[ii] = arg2[ii];
|
||||
} else {
|
||||
SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in variable '""enodes""' of type '""switch_event_node_t *[SWITCH_EVENT_ALL+1]""'");
|
||||
}
|
||||
}
|
||||
resultobj = SWIG_Py_Void();
|
||||
return resultobj;
|
||||
fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
SWIGINTERN PyObject *_wrap_EventConsumer_enodes_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
|
||||
PyObject *resultobj = 0;
|
||||
EventConsumer *arg1 = (EventConsumer *) 0 ;
|
||||
switch_event_node_t **result = 0 ;
|
||||
void *argp1 = 0 ;
|
||||
int res1 = 0 ;
|
||||
PyObject * obj0 = 0 ;
|
||||
|
||||
if (!PyArg_ParseTuple(args,(char *)"O:EventConsumer_enodes_get",&obj0)) SWIG_fail;
|
||||
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_EventConsumer, 0 | 0 );
|
||||
if (!SWIG_IsOK(res1)) {
|
||||
SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventConsumer_enodes_get" "', argument " "1"" of type '" "EventConsumer *""'");
|
||||
}
|
||||
arg1 = reinterpret_cast< EventConsumer * >(argp1);
|
||||
result = (switch_event_node_t **)(switch_event_node_t **) ((arg1)->enodes);
|
||||
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_p_switch_event_node_t, 0 | 0 );
|
||||
return resultobj;
|
||||
fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
SWIGINTERN PyObject *_wrap_EventConsumer_node_index_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
|
||||
PyObject *resultobj = 0;
|
||||
EventConsumer *arg1 = (EventConsumer *) 0 ;
|
||||
uint32_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:EventConsumer_node_index_set",&obj0,&obj1)) SWIG_fail;
|
||||
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_EventConsumer, 0 | 0 );
|
||||
if (!SWIG_IsOK(res1)) {
|
||||
SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventConsumer_node_index_set" "', argument " "1"" of type '" "EventConsumer *""'");
|
||||
}
|
||||
arg1 = reinterpret_cast< EventConsumer * >(argp1);
|
||||
{
|
||||
res2 = SWIG_ConvertPtr(obj1, &argp2, SWIGTYPE_p_uint32_t, 0 | 0);
|
||||
if (!SWIG_IsOK(res2)) {
|
||||
SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "EventConsumer_node_index_set" "', argument " "2"" of type '" "uint32_t""'");
|
||||
}
|
||||
if (!argp2) {
|
||||
SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "EventConsumer_node_index_set" "', argument " "2"" of type '" "uint32_t""'");
|
||||
} else {
|
||||
uint32_t * temp = reinterpret_cast< uint32_t * >(argp2);
|
||||
arg2 = *temp;
|
||||
if (SWIG_IsNewObj(res2)) delete temp;
|
||||
}
|
||||
}
|
||||
if (arg1) (arg1)->node_index = arg2;
|
||||
|
||||
resultobj = SWIG_Py_Void();
|
||||
return resultobj;
|
||||
fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
SWIGINTERN PyObject *_wrap_EventConsumer_node_index_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
|
||||
PyObject *resultobj = 0;
|
||||
EventConsumer *arg1 = (EventConsumer *) 0 ;
|
||||
uint32_t result;
|
||||
void *argp1 = 0 ;
|
||||
int res1 = 0 ;
|
||||
PyObject * obj0 = 0 ;
|
||||
|
||||
if (!PyArg_ParseTuple(args,(char *)"O:EventConsumer_node_index_get",&obj0)) SWIG_fail;
|
||||
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_EventConsumer, 0 | 0 );
|
||||
if (!SWIG_IsOK(res1)) {
|
||||
SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventConsumer_node_index_get" "', argument " "1"" of type '" "EventConsumer *""'");
|
||||
}
|
||||
arg1 = reinterpret_cast< EventConsumer * >(argp1);
|
||||
result = ((arg1)->node_index);
|
||||
resultobj = SWIG_NewPointerObj((new uint32_t(static_cast< const uint32_t& >(result))), SWIGTYPE_p_uint32_t, SWIG_POINTER_OWN | 0 );
|
||||
return resultobj;
|
||||
fail:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
SWIGINTERN PyObject *_wrap_new_EventConsumer(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
|
||||
PyObject *resultobj = 0;
|
||||
char *arg1 = (char *) NULL ;
|
||||
@@ -8742,6 +8863,10 @@ static PyMethodDef SwigMethods[] = {
|
||||
{ (char *)"EventConsumer_e_subclass_name_get", _wrap_EventConsumer_e_subclass_name_get, METH_VARARGS, NULL},
|
||||
{ (char *)"EventConsumer_e_cb_arg_set", _wrap_EventConsumer_e_cb_arg_set, METH_VARARGS, NULL},
|
||||
{ (char *)"EventConsumer_e_cb_arg_get", _wrap_EventConsumer_e_cb_arg_get, METH_VARARGS, NULL},
|
||||
{ (char *)"EventConsumer_enodes_set", _wrap_EventConsumer_enodes_set, METH_VARARGS, NULL},
|
||||
{ (char *)"EventConsumer_enodes_get", _wrap_EventConsumer_enodes_get, METH_VARARGS, NULL},
|
||||
{ (char *)"EventConsumer_node_index_set", _wrap_EventConsumer_node_index_set, METH_VARARGS, NULL},
|
||||
{ (char *)"EventConsumer_node_index_get", _wrap_EventConsumer_node_index_get, METH_VARARGS, NULL},
|
||||
{ (char *)"new_EventConsumer", _wrap_new_EventConsumer, METH_VARARGS, NULL},
|
||||
{ (char *)"delete_EventConsumer", _wrap_delete_EventConsumer, METH_VARARGS, NULL},
|
||||
{ (char *)"EventConsumer_bind", _wrap_EventConsumer_bind, METH_VARARGS, NULL},
|
||||
@@ -8861,6 +8986,7 @@ static swig_type_info _swigt__p_PYTHON__Session = {"_p_PYTHON__Session", "PYTHON
|
||||
static swig_type_info _swigt__p_Stream = {"_p_Stream", "Stream *", 0, 0, (void*)0, 0};
|
||||
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_p_switch_event_node_t = {"_p_p_switch_event_node_t", "switch_event_node_t **", 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};
|
||||
@@ -8889,6 +9015,7 @@ static swig_type_info *swig_type_initial[] = {
|
||||
&_swigt__p_Stream,
|
||||
&_swigt__p_char,
|
||||
&_swigt__p_input_callback_state,
|
||||
&_swigt__p_p_switch_event_node_t,
|
||||
&_swigt__p_session_flag_t,
|
||||
&_swigt__p_switch_call_cause_t,
|
||||
&_swigt__p_switch_channel_state_t,
|
||||
@@ -8917,6 +9044,7 @@ static swig_cast_info _swigc__p_PYTHON__Session[] = { {&_swigt__p_PYTHON__Sessi
|
||||
static swig_cast_info _swigc__p_Stream[] = { {&_swigt__p_Stream, 0, 0, 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_p_switch_event_node_t[] = { {&_swigt__p_p_switch_event_node_t, 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}};
|
||||
@@ -8945,6 +9073,7 @@ static swig_cast_info *swig_cast_initial[] = {
|
||||
_swigc__p_Stream,
|
||||
_swigc__p_char,
|
||||
_swigc__p_input_callback_state,
|
||||
_swigc__p_p_switch_event_node_t,
|
||||
_swigc__p_session_flag_t,
|
||||
_swigc__p_switch_call_cause_t,
|
||||
_swigc__p_switch_channel_state_t,
|
||||
|
||||
Reference in New Issue
Block a user