diff --git a/Makefile.am b/Makefile.am index b77a968edc..d8e116c84c 100644 --- a/Makefile.am +++ b/Makefile.am @@ -599,6 +599,11 @@ speex-reconf: cd libs/speex && ./config.status --recheck cd libs/speex && ./config.status +sndfile-reconf: + cd libs/libsndfile && autoreconf + cd libs/libsndfile && ./config.status --recheck + cd libs/libsndfile && ./config.status + tiff-reconf: cd libs/tiff-3.8.2 && autoreconf -fi cd libs/tiff-3.8.2 && sh ./configure.gnu diff --git a/src/include/switch_types.h b/src/include/switch_types.h index f879783f38..4789d09abd 100644 --- a/src/include/switch_types.h +++ b/src/include/switch_types.h @@ -1181,6 +1181,7 @@ typedef enum { CF_BRIDGE_NOWRITE, CF_RECOVERED, CF_JITTERBUFFER, + CF_JITTERBUFFER_PLC, CF_DIALPLAN, CF_BLOCK_BROADCAST_UNTIL_MEDIA, CF_CNG_PLC, diff --git a/src/include/switch_xml.h b/src/include/switch_xml.h index 6961b2da23..0d436fac2f 100644 --- a/src/include/switch_xml.h +++ b/src/include/switch_xml.h @@ -421,7 +421,7 @@ SWITCH_DECLARE(switch_status_t) switch_xml_unbind_search_function_ptr(_In_ switc ///\return the section mask SWITCH_DECLARE(switch_xml_section_t) switch_xml_parse_section_string(_In_opt_z_ const char *str); -SWITCH_DECLARE(int) switch_xml_std_datetime_check(switch_xml_t xcond); +SWITCH_DECLARE(int) switch_xml_std_datetime_check(switch_xml_t xcond, int *offset); SWITCH_DECLARE(switch_status_t) switch_xml_locate_language(switch_xml_t *root, switch_xml_t *node, switch_event_t *params, switch_xml_t *language, switch_xml_t *phrases, switch_xml_t *macros, const char *str_language); diff --git a/src/mod/applications/mod_sms/mod_sms.c b/src/mod/applications/mod_sms/mod_sms.c index 50778da81f..e3e3f49578 100644 --- a/src/mod/applications/mod_sms/mod_sms.c +++ b/src/mod/applications/mod_sms/mod_sms.c @@ -81,7 +81,7 @@ static int parse_exten(switch_event_t *event, switch_xml_t xexten, switch_event_ switch_bool_t anti_action = SWITCH_TRUE; break_t do_break_i = BREAK_ON_FALSE; - int time_match = switch_xml_std_datetime_check(xcond); + int time_match = switch_xml_std_datetime_check(xcond, NULL); switch_safe_free(field_expanded); switch_safe_free(expression_expanded); diff --git a/src/mod/dialplans/mod_dialplan_xml/mod_dialplan_xml.c b/src/mod/dialplans/mod_dialplan_xml/mod_dialplan_xml.c index b2fb858e31..45a736facf 100644 --- a/src/mod/dialplans/mod_dialplan_xml/mod_dialplan_xml.c +++ b/src/mod/dialplans/mod_dialplan_xml/mod_dialplan_xml.c @@ -87,6 +87,14 @@ static int parse_exten(switch_core_session_t *session, switch_caller_profile_t * int proceed = 0, save_proceed = 0; char *expression_expanded = NULL, *field_expanded = NULL; switch_regex_t *re = NULL, *save_re = NULL; + int offset = 0; + const char *tzoff = switch_channel_get_variable(channel, "tod_tz_offset"); + + if (!zstr(tzoff) && switch_is_number(tzoff)) { + offset = atoi(tzoff); + } else { + tzoff = NULL; + } if (!exten_name) { exten_name = "_anon_"; @@ -102,7 +110,7 @@ static int parse_exten(switch_core_session_t *session, switch_caller_profile_t * switch_bool_t anti_action = SWITCH_TRUE; break_t do_break_i = BREAK_ON_FALSE; - int time_match = switch_xml_std_datetime_check(xcond); + int time_match = switch_xml_std_datetime_check(xcond, tzoff ? &offset : NULL); switch_safe_free(field_expanded); switch_safe_free(expression_expanded); @@ -152,7 +160,7 @@ static int parse_exten(switch_core_session_t *session, switch_caller_profile_t * switch_channel_del_variable_prefix(channel, "DP_REGEX_MATCH"); for (xregex = switch_xml_child(xcond, "regex"); xregex; xregex = xregex->next) { - time_match = switch_xml_std_datetime_check(xregex); + time_match = switch_xml_std_datetime_check(xregex, tzoff ? &offset : NULL); if (time_match == 1) { switch_log_printf(SWITCH_CHANNEL_SESSION_LOG_CLEAN(session), SWITCH_LOG_DEBUG, diff --git a/src/mod/endpoints/mod_h323/changes.txt b/src/mod/endpoints/mod_h323/changes.txt index 0635cd62e8..93a75e8b0f 100644 --- a/src/mod/endpoints/mod_h323/changes.txt +++ b/src/mod/endpoints/mod_h323/changes.txt @@ -1,3 +1,4 @@ +fix stale calls then fax send/recv in some circumstance remove SWITCH_RTP_FLAG_AUTO_CNG - works incorrectly. moves the switch_rtp_request_port() call from the contructor to FSH323Connection::CreateRealTimeLogicalChannel() - fix rtp port leak. tnx to Peter Olsson. diff --git a/src/mod/endpoints/mod_h323/mod_h323.cpp b/src/mod/endpoints/mod_h323/mod_h323.cpp index 3fe2290e4c..fa195c39fa 100644 --- a/src/mod/endpoints/mod_h323/mod_h323.cpp +++ b/src/mod/endpoints/mod_h323/mod_h323.cpp @@ -33,7 +33,7 @@ * * mod_h323.cpp -- H323 endpoint * - * Version 0.0.57 + * Version 0.0.58 */ //#define DEBUG_RTP_PACKETS @@ -1333,7 +1333,19 @@ void FSH323Connection::OnModeChanged(const H245_ModeDescription & newMode) const char *uuid = switch_channel_get_variable(m_fsChannel, SWITCH_SIGNAL_BOND_VARIABLE); if (uuid != NULL) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG,"uuid:%s\n",uuid); - switch_channel_set_private(switch_core_session_get_channel(switch_core_session_locate(switch_channel_get_variable(m_fsChannel, SWITCH_SIGNAL_BOND_VARIABLE))), "t38_options", t38_options); + + switch_core_session_t *session = switch_core_session_locate(switch_channel_get_variable(m_fsChannel, SWITCH_SIGNAL_BOND_VARIABLE)); + if (session) { + switch_channel_t * channel = switch_core_session_get_channel(session); + if (channel) { + switch_channel_set_private(channel, "t38_options", t38_options); + }else { + switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "no channel?\n"); + } + switch_core_session_rwunlock(session); + }else{ + switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "no session\n"); + } switch_core_session_message_t msg = { 0 }; diff --git a/src/mod/endpoints/mod_h323/mod_h323.h b/src/mod/endpoints/mod_h323/mod_h323.h index 3a0d7aa235..3e046d1093 100644 --- a/src/mod/endpoints/mod_h323/mod_h323.h +++ b/src/mod/endpoints/mod_h323/mod_h323.h @@ -32,7 +32,7 @@ * * mod_h323.h -- H323 endpoint * - * Version 0.0.57 + * Version 0.0.58 */ #if defined(__GNUC__) && defined(HAVE_VISIBILITY) diff --git a/src/mod/endpoints/mod_sofia/mod_sofia.c b/src/mod/endpoints/mod_sofia/mod_sofia.c index a700383330..796813aa35 100644 --- a/src/mod/endpoints/mod_sofia/mod_sofia.c +++ b/src/mod/endpoints/mod_sofia/mod_sofia.c @@ -1505,6 +1505,9 @@ static switch_status_t sofia_receive_message(switch_core_session_t *session, swi SWITCH_LOG_DEBUG, "Setting Jitterbuffer to %dms (%d frames) (%d max frames) (%d max drift)\n", len, qlen, maxqlen, max_drift); switch_channel_set_flag(tech_pvt->channel, CF_JITTERBUFFER); + if (!switch_false(switch_channel_get_variable(tech_pvt->channel, "sip_jitter_buffer_plc"))) { + switch_channel_set_flag(tech_pvt->channel, CF_JITTERBUFFER_PLC); + } } else { switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(tech_pvt->session), SWITCH_LOG_WARNING, "Error Setting Jitterbuffer to %dms (%d frames)\n", len, qlen); diff --git a/src/mod/endpoints/mod_sofia/sofia_glue.c b/src/mod/endpoints/mod_sofia/sofia_glue.c index c05cff06e4..0582148056 100644 --- a/src/mod/endpoints/mod_sofia/sofia_glue.c +++ b/src/mod/endpoints/mod_sofia/sofia_glue.c @@ -3324,6 +3324,9 @@ switch_status_t sofia_glue_activate_rtp(private_object_t *tech_pvt, switch_rtp_f switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(tech_pvt->session), SWITCH_LOG_DEBUG, "Setting Jitterbuffer to %dms (%d frames)\n", jb_msec, qlen); switch_channel_set_flag(tech_pvt->channel, CF_JITTERBUFFER); + if (!switch_false(switch_channel_get_variable(tech_pvt->channel, "sip_jitter_buffer_plc"))) { + switch_channel_set_flag(tech_pvt->channel, CF_JITTERBUFFER_PLC); + } } else { switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(tech_pvt->session), SWITCH_LOG_WARNING, "Error Setting Jitterbuffer to %dms (%d frames)\n", jb_msec, qlen); diff --git a/src/mod/formats/mod_sndfile/mod_sndfile.c b/src/mod/formats/mod_sndfile/mod_sndfile.c index 5b011dccb2..b7e4dbfd6b 100644 --- a/src/mod/formats/mod_sndfile/mod_sndfile.c +++ b/src/mod/formats/mod_sndfile/mod_sndfile.c @@ -146,6 +146,9 @@ static switch_status_t sndfile_file_open(switch_file_handle_t *handle, const cha context->sfinfo.format = SF_FORMAT_WAV | SF_FORMAT_IMA_ADPCM; context->sfinfo.channels = 1; context->sfinfo.samplerate = 8000; + } else if (!strcmp(ext, "oga")) { + context->sfinfo.format = SF_FORMAT_OGG | SF_FORMAT_VORBIS; + context->sfinfo.samplerate = handle->samplerate; } if ((mode & SFM_WRITE) && sf_format_check(&context->sfinfo) == 0) { diff --git a/src/mod/languages/mod_managed/freeswitch_wrap.2010.cxx b/src/mod/languages/mod_managed/freeswitch_wrap.2010.cxx index e1144ef955..2b249b272e 100644 --- a/src/mod/languages/mod_managed/freeswitch_wrap.2010.cxx +++ b/src/mod/languages/mod_managed/freeswitch_wrap.2010.cxx @@ -270,7 +270,6 @@ SWIGEXPORT void SWIGSTDCALL SWIGRegisterExceptionArgumentCallbacks_freeswitch( /* Callback for returning strings to C# without leaking memory */ #ifndef _MANAGED -#include #include #include #include @@ -12622,6 +12621,22 @@ SWIGEXPORT int SWIGSTDCALL CSharp_switch_is_number(char * jarg1) { } +SWIGEXPORT char * SWIGSTDCALL CSharp_switch_find_parameter(char * jarg1, char * jarg2, void * jarg3) { + char * jresult ; + char *arg1 = (char *) 0 ; + char *arg2 = (char *) 0 ; + switch_memory_pool_t *arg3 = (switch_memory_pool_t *) 0 ; + char *result = 0 ; + + arg1 = (char *)jarg1; + arg2 = (char *)jarg2; + arg3 = (switch_memory_pool_t *)jarg3; + result = (char *)switch_find_parameter((char const *)arg1,(char const *)arg2,arg3); + jresult = SWIG_csharp_string_callback((const char *)result); + return jresult; +} + + SWIGEXPORT int SWIGSTDCALL CSharp_switch_true(char * jarg1) { int jresult ; char *arg1 = (char *) 0 ; @@ -24339,6 +24354,20 @@ SWIGEXPORT char * SWIGSTDCALL CSharp_switch_channel_get_hold_music_partner(void } +SWIGEXPORT unsigned long SWIGSTDCALL CSharp_switch_channel_del_variable_prefix(void * jarg1, char * jarg2) { + unsigned long jresult ; + switch_channel_t *arg1 = (switch_channel_t *) 0 ; + char *arg2 = (char *) 0 ; + uint32_t result; + + arg1 = (switch_channel_t *)jarg1; + arg2 = (char *)jarg2; + result = (uint32_t)switch_channel_del_variable_prefix(arg1,(char const *)arg2); + jresult = (unsigned long)result; + return jresult; +} + + SWIGEXPORT int SWIGSTDCALL CSharp_switch_channel_export_variable_var_check(void * jarg1, char * jarg2, char * jarg3, char * jarg4, int jarg5) { int jresult ; switch_channel_t *arg1 = (switch_channel_t *) 0 ; @@ -29666,6 +29695,20 @@ SWIGEXPORT char * SWIGSTDCALL CSharp_switch_ivr_check_presence_mapping(char * ja } +SWIGEXPORT int SWIGSTDCALL CSharp_switch_ivr_kill_uuid(char * jarg1, int jarg2) { + int jresult ; + char *arg1 = (char *) 0 ; + switch_call_cause_t arg2 ; + switch_status_t result; + + arg1 = (char *)jarg1; + arg2 = (switch_call_cause_t)jarg2; + result = (switch_status_t)switch_ivr_kill_uuid((char const *)arg1,arg2); + jresult = result; + return jresult; +} + + SWIGEXPORT int SWIGSTDCALL CSharp_SWITCH_RTP_MAX_BUF_LEN_get() { int jresult ; int result; @@ -32159,13 +32202,15 @@ SWIGEXPORT unsigned long SWIGSTDCALL CSharp_switch_xml_parse_section_string(char } -SWIGEXPORT int SWIGSTDCALL CSharp_switch_xml_std_datetime_check(void * jarg1) { +SWIGEXPORT int SWIGSTDCALL CSharp_switch_xml_std_datetime_check(void * jarg1, void * jarg2) { int jresult ; switch_xml_t arg1 = (switch_xml_t) 0 ; + int *arg2 = (int *) 0 ; int result; arg1 = (switch_xml_t)jarg1; - result = (int)switch_xml_std_datetime_check(arg1); + arg2 = (int *)jarg2; + result = (int)switch_xml_std_datetime_check(arg1,arg2); jresult = result; return jresult; } diff --git a/src/mod/languages/mod_managed/freeswitch_wrap.cxx b/src/mod/languages/mod_managed/freeswitch_wrap.cxx index c7a4635e6c..51c63207f6 100644 --- a/src/mod/languages/mod_managed/freeswitch_wrap.cxx +++ b/src/mod/languages/mod_managed/freeswitch_wrap.cxx @@ -12958,6 +12958,22 @@ SWIGEXPORT int SWIGSTDCALL CSharp_switch_is_number(char * jarg1) { } +SWIGEXPORT char * SWIGSTDCALL CSharp_switch_find_parameter(char * jarg1, char * jarg2, void * jarg3) { + char * jresult ; + char *arg1 = (char *) 0 ; + char *arg2 = (char *) 0 ; + switch_memory_pool_t *arg3 = (switch_memory_pool_t *) 0 ; + char *result = 0 ; + + arg1 = (char *)jarg1; + arg2 = (char *)jarg2; + arg3 = (switch_memory_pool_t *)jarg3; + result = (char *)switch_find_parameter((char const *)arg1,(char const *)arg2,arg3); + jresult = SWIG_csharp_string_callback((const char *)result); + return jresult; +} + + SWIGEXPORT int SWIGSTDCALL CSharp_switch_true(char * jarg1) { int jresult ; char *arg1 = (char *) 0 ; @@ -32936,13 +32952,15 @@ SWIGEXPORT unsigned long SWIGSTDCALL CSharp_switch_xml_parse_section_string(char } -SWIGEXPORT int SWIGSTDCALL CSharp_switch_xml_std_datetime_check(void * jarg1) { +SWIGEXPORT int SWIGSTDCALL CSharp_switch_xml_std_datetime_check(void * jarg1, void * jarg2) { int jresult ; switch_xml_t arg1 = (switch_xml_t) 0 ; + int *arg2 = (int *) 0 ; int result; arg1 = (switch_xml_t)jarg1; - result = (int)switch_xml_std_datetime_check(arg1); + arg2 = (int *)jarg2; + result = (int)switch_xml_std_datetime_check(arg1,arg2); jresult = result; return jresult; } diff --git a/src/mod/languages/mod_managed/managed/swig.2010.cs b/src/mod/languages/mod_managed/managed/swig.2010.cs index 6e5cb6fe7e..cc5f2a87ec 100644 --- a/src/mod/languages/mod_managed/managed/swig.2010.cs +++ b/src/mod/languages/mod_managed/managed/swig.2010.cs @@ -2996,6 +2996,11 @@ public class freeswitch { return ret; } + public static string switch_find_parameter(string str, string param, SWIGTYPE_p_apr_pool_t pool) { + string ret = freeswitchPINVOKE.switch_find_parameter(str, param, SWIGTYPE_p_apr_pool_t.getCPtr(pool)); + return ret; + } + public static int switch_true(string expr) { int ret = freeswitchPINVOKE.switch_true(expr); return ret; @@ -3565,6 +3570,11 @@ public class freeswitch { return ret; } + public static uint switch_channel_del_variable_prefix(SWIGTYPE_p_switch_channel channel, string prefix) { + uint ret = freeswitchPINVOKE.switch_channel_del_variable_prefix(SWIGTYPE_p_switch_channel.getCPtr(channel), prefix); + return ret; + } + public static switch_status_t switch_channel_export_variable_var_check(SWIGTYPE_p_switch_channel channel, string varname, string val, string export_varname, switch_bool_t var_check) { switch_status_t ret = (switch_status_t)freeswitchPINVOKE.switch_channel_export_variable_var_check(SWIGTYPE_p_switch_channel.getCPtr(channel), varname, val, export_varname, (int)var_check); return ret; @@ -4937,6 +4947,11 @@ public class freeswitch { return ret; } + public static switch_status_t switch_ivr_kill_uuid(string uuid, switch_call_cause_t cause) { + switch_status_t ret = (switch_status_t)freeswitchPINVOKE.switch_ivr_kill_uuid(uuid, (int)cause); + return ret; + } + public static switch_status_t switch_rtp_add_crypto_key(SWIGTYPE_p_switch_rtp rtp_session, switch_rtp_crypto_direction_t direction, uint index, switch_rtp_crypto_key_type_t type, SWIGTYPE_p_unsigned_char key, SWIGTYPE_p_switch_size_t keylen) { switch_status_t ret = (switch_status_t)freeswitchPINVOKE.switch_rtp_add_crypto_key(SWIGTYPE_p_switch_rtp.getCPtr(rtp_session), (int)direction, index, (int)type, SWIGTYPE_p_unsigned_char.getCPtr(key), SWIGTYPE_p_switch_size_t.getCPtr(keylen)); if (freeswitchPINVOKE.SWIGPendingException.Pending) throw freeswitchPINVOKE.SWIGPendingException.Retrieve(); @@ -5543,8 +5558,8 @@ public class freeswitch { return ret; } - public static int switch_xml_std_datetime_check(switch_xml xcond) { - int ret = freeswitchPINVOKE.switch_xml_std_datetime_check(switch_xml.getCPtr(xcond)); + public static int switch_xml_std_datetime_check(switch_xml xcond, SWIGTYPE_p_int offset) { + int ret = freeswitchPINVOKE.switch_xml_std_datetime_check(switch_xml.getCPtr(xcond), SWIGTYPE_p_int.getCPtr(offset)); return ret; } @@ -9198,6 +9213,9 @@ class freeswitchPINVOKE { [DllImport("mod_managed", EntryPoint="CSharp_switch_is_number")] public static extern int switch_is_number(string jarg1); + [DllImport("mod_managed", EntryPoint="CSharp_switch_find_parameter")] + public static extern string switch_find_parameter(string jarg1, string jarg2, HandleRef jarg3); + [DllImport("mod_managed", EntryPoint="CSharp_switch_true")] public static extern int switch_true(string jarg1); @@ -12129,6 +12147,9 @@ class freeswitchPINVOKE { [DllImport("mod_managed", EntryPoint="CSharp_switch_channel_get_hold_music_partner")] public static extern string switch_channel_get_hold_music_partner(HandleRef jarg1); + [DllImport("mod_managed", EntryPoint="CSharp_switch_channel_del_variable_prefix")] + public static extern uint switch_channel_del_variable_prefix(HandleRef jarg1, string jarg2); + [DllImport("mod_managed", EntryPoint="CSharp_switch_channel_export_variable_var_check")] public static extern int switch_channel_export_variable_var_check(HandleRef jarg1, string jarg2, string jarg3, string jarg4, int jarg5); @@ -13248,6 +13269,9 @@ class freeswitchPINVOKE { [DllImport("mod_managed", EntryPoint="CSharp_switch_ivr_check_presence_mapping")] public static extern string switch_ivr_check_presence_mapping(string jarg1, string jarg2); + [DllImport("mod_managed", EntryPoint="CSharp_switch_ivr_kill_uuid")] + public static extern int switch_ivr_kill_uuid(string jarg1, int jarg2); + [DllImport("mod_managed", EntryPoint="CSharp_SWITCH_RTP_MAX_BUF_LEN_get")] public static extern int SWITCH_RTP_MAX_BUF_LEN_get(); @@ -13810,7 +13834,7 @@ class freeswitchPINVOKE { public static extern uint switch_xml_parse_section_string(string jarg1); [DllImport("mod_managed", EntryPoint="CSharp_switch_xml_std_datetime_check")] - public static extern int switch_xml_std_datetime_check(HandleRef jarg1); + public static extern int switch_xml_std_datetime_check(HandleRef jarg1, HandleRef jarg2); [DllImport("mod_managed", EntryPoint="CSharp_switch_xml_locate_language")] public static extern int switch_xml_locate_language(HandleRef jarg1, HandleRef jarg2, HandleRef jarg3, HandleRef jarg4, HandleRef jarg5, HandleRef jarg6, string jarg7); @@ -22803,6 +22827,8 @@ public enum switch_channel_flag_t { CF_SIGNAL_DATA, CF_SIMPLIFY, CF_ZOMBIE_EXEC, + CF_INTERCEPT, + CF_INTERCEPTED, CF_FLAG_MAX } diff --git a/src/mod/languages/mod_managed/managed/swig.cs b/src/mod/languages/mod_managed/managed/swig.cs index ac5de415c9..f047d4cbca 100644 --- a/src/mod/languages/mod_managed/managed/swig.cs +++ b/src/mod/languages/mod_managed/managed/swig.cs @@ -542,136 +542,6 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; -public class EventConsumer : IDisposable { - private HandleRef swigCPtr; - protected bool swigCMemOwn; - - internal EventConsumer(IntPtr cPtr, bool cMemoryOwn) { - swigCMemOwn = cMemoryOwn; - swigCPtr = new HandleRef(this, cPtr); - } - - internal static HandleRef getCPtr(EventConsumer obj) { - return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; - } - - ~EventConsumer() { - Dispose(); - } - - public virtual void Dispose() { - lock(this) { - if(swigCPtr.Handle != IntPtr.Zero && swigCMemOwn) { - swigCMemOwn = false; - freeswitchPINVOKE.delete_EventConsumer(swigCPtr); - } - swigCPtr = new HandleRef(null, IntPtr.Zero); - GC.SuppressFinalize(this); - } - } - - public SWIGTYPE_p_switch_queue_t events { - set { - freeswitchPINVOKE.EventConsumer_events_set(swigCPtr, SWIGTYPE_p_switch_queue_t.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.EventConsumer_events_get(swigCPtr); - SWIGTYPE_p_switch_queue_t ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_switch_queue_t(cPtr, false); - return ret; - } - } - - public switch_event_types_t e_event_id { - set { - freeswitchPINVOKE.EventConsumer_e_event_id_set(swigCPtr, (int)value); - } - get { - switch_event_types_t ret = (switch_event_types_t)freeswitchPINVOKE.EventConsumer_e_event_id_get(swigCPtr); - return ret; - } - } - - public string e_callback { - set { - freeswitchPINVOKE.EventConsumer_e_callback_set(swigCPtr, value); - } - get { - string ret = freeswitchPINVOKE.EventConsumer_e_callback_get(swigCPtr); - return ret; - } - } - - public string e_subclass_name { - set { - freeswitchPINVOKE.EventConsumer_e_subclass_name_set(swigCPtr, value); - } - get { - string ret = freeswitchPINVOKE.EventConsumer_e_subclass_name_get(swigCPtr); - return ret; - } - } - - public string e_cb_arg { - set { - freeswitchPINVOKE.EventConsumer_e_cb_arg_set(swigCPtr, value); - } - get { - string ret = freeswitchPINVOKE.EventConsumer_e_cb_arg_get(swigCPtr); - return ret; - } - } - - public SWIGTYPE_p_p_switch_event_node enodes { - set { - freeswitchPINVOKE.EventConsumer_enodes_set(swigCPtr, SWIGTYPE_p_p_switch_event_node.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.EventConsumer_enodes_get(swigCPtr); - SWIGTYPE_p_p_switch_event_node ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_p_switch_event_node(cPtr, false); - return ret; - } - } - - public uint node_index { - set { - freeswitchPINVOKE.EventConsumer_node_index_set(swigCPtr, value); - } - get { - uint ret = freeswitchPINVOKE.EventConsumer_node_index_get(swigCPtr); - return ret; - } - } - - public EventConsumer(string event_name, string subclass_name) : this(freeswitchPINVOKE.new_EventConsumer(event_name, subclass_name), true) { - } - - public int bind(string event_name, string subclass_name) { - int ret = freeswitchPINVOKE.EventConsumer_bind(swigCPtr, event_name, subclass_name); - return ret; - } - - public Event pop(int block) { - IntPtr cPtr = freeswitchPINVOKE.EventConsumer_pop(swigCPtr, block); - Event ret = (cPtr == IntPtr.Zero) ? null : new Event(cPtr, true); - return ret; - } - -} - -} -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.35 - * - * Do not make changes to this file unless you know what you are doing--modify - * the SWIG interface file instead. - * ----------------------------------------------------------------------------- */ - -namespace FreeSWITCH.Native { - -using System; -using System.Runtime.InteropServices; - public partial class Event : IDisposable { private HandleRef swigCPtr; protected bool swigCMemOwn; @@ -808,6 +678,136 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; +public class EventConsumer : IDisposable { + private HandleRef swigCPtr; + protected bool swigCMemOwn; + + internal EventConsumer(IntPtr cPtr, bool cMemoryOwn) { + swigCMemOwn = cMemoryOwn; + swigCPtr = new HandleRef(this, cPtr); + } + + internal static HandleRef getCPtr(EventConsumer obj) { + return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; + } + + ~EventConsumer() { + Dispose(); + } + + public virtual void Dispose() { + lock(this) { + if(swigCPtr.Handle != IntPtr.Zero && swigCMemOwn) { + swigCMemOwn = false; + freeswitchPINVOKE.delete_EventConsumer(swigCPtr); + } + swigCPtr = new HandleRef(null, IntPtr.Zero); + GC.SuppressFinalize(this); + } + } + + public SWIGTYPE_p_switch_queue_t events { + set { + freeswitchPINVOKE.EventConsumer_events_set(swigCPtr, SWIGTYPE_p_switch_queue_t.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.EventConsumer_events_get(swigCPtr); + SWIGTYPE_p_switch_queue_t ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_switch_queue_t(cPtr, false); + return ret; + } + } + + public switch_event_types_t e_event_id { + set { + freeswitchPINVOKE.EventConsumer_e_event_id_set(swigCPtr, (int)value); + } + get { + switch_event_types_t ret = (switch_event_types_t)freeswitchPINVOKE.EventConsumer_e_event_id_get(swigCPtr); + return ret; + } + } + + public string e_callback { + set { + freeswitchPINVOKE.EventConsumer_e_callback_set(swigCPtr, value); + } + get { + string ret = freeswitchPINVOKE.EventConsumer_e_callback_get(swigCPtr); + return ret; + } + } + + public string e_subclass_name { + set { + freeswitchPINVOKE.EventConsumer_e_subclass_name_set(swigCPtr, value); + } + get { + string ret = freeswitchPINVOKE.EventConsumer_e_subclass_name_get(swigCPtr); + return ret; + } + } + + public string e_cb_arg { + set { + freeswitchPINVOKE.EventConsumer_e_cb_arg_set(swigCPtr, value); + } + get { + string ret = freeswitchPINVOKE.EventConsumer_e_cb_arg_get(swigCPtr); + return ret; + } + } + + public SWIGTYPE_p_p_switch_event_node enodes { + set { + freeswitchPINVOKE.EventConsumer_enodes_set(swigCPtr, SWIGTYPE_p_p_switch_event_node.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.EventConsumer_enodes_get(swigCPtr); + SWIGTYPE_p_p_switch_event_node ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_p_switch_event_node(cPtr, false); + return ret; + } + } + + public uint node_index { + set { + freeswitchPINVOKE.EventConsumer_node_index_set(swigCPtr, value); + } + get { + uint ret = freeswitchPINVOKE.EventConsumer_node_index_get(swigCPtr); + return ret; + } + } + + public EventConsumer(string event_name, string subclass_name) : this(freeswitchPINVOKE.new_EventConsumer(event_name, subclass_name), true) { + } + + public int bind(string event_name, string subclass_name) { + int ret = freeswitchPINVOKE.EventConsumer_bind(swigCPtr, event_name, subclass_name); + return ret; + } + + public Event pop(int block) { + IntPtr cPtr = freeswitchPINVOKE.EventConsumer_pop(swigCPtr, block); + Event ret = (cPtr == IntPtr.Zero) ? null : new Event(cPtr, true); + return ret; + } + +} + +} +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 1.3.35 + * + * Do not make changes to this file unless you know what you are doing--modify + * the SWIG interface file instead. + * ----------------------------------------------------------------------------- */ + +namespace FreeSWITCH.Native { + +using System; +using System.Runtime.InteropServices; + public class freeswitch { public static switch_directories SWITCH_GLOBAL_dirs { set { @@ -2986,6 +2986,11 @@ public class freeswitch { return ret; } + public static string switch_find_parameter(string str, string param, SWIGTYPE_p_apr_pool_t pool) { + string ret = freeswitchPINVOKE.switch_find_parameter(str, param, SWIGTYPE_p_apr_pool_t.getCPtr(pool)); + return ret; + } + public static int switch_true(string expr) { int ret = freeswitchPINVOKE.switch_true(expr); return ret; @@ -5543,8 +5548,8 @@ public class freeswitch { return ret; } - public static int switch_xml_std_datetime_check(switch_xml xcond) { - int ret = freeswitchPINVOKE.switch_xml_std_datetime_check(switch_xml.getCPtr(xcond)); + public static int switch_xml_std_datetime_check(switch_xml xcond, SWIGTYPE_p_int offset) { + int ret = freeswitchPINVOKE.switch_xml_std_datetime_check(switch_xml.getCPtr(xcond), SWIGTYPE_p_int.getCPtr(offset)); return ret; } @@ -9194,6 +9199,9 @@ class freeswitchPINVOKE { [DllImport("mod_managed", EntryPoint="CSharp_switch_is_number")] public static extern int switch_is_number(string jarg1); + [DllImport("mod_managed", EntryPoint="CSharp_switch_find_parameter")] + public static extern string switch_find_parameter(string jarg1, string jarg2, HandleRef jarg3); + [DllImport("mod_managed", EntryPoint="CSharp_switch_true")] public static extern int switch_true(string jarg1); @@ -13812,7 +13820,7 @@ class freeswitchPINVOKE { public static extern uint switch_xml_parse_section_string(string jarg1); [DllImport("mod_managed", EntryPoint="CSharp_switch_xml_std_datetime_check")] - public static extern int switch_xml_std_datetime_check(HandleRef jarg1); + public static extern int switch_xml_std_datetime_check(HandleRef jarg1, HandleRef jarg2); [DllImport("mod_managed", EntryPoint="CSharp_switch_xml_locate_language")] public static extern int switch_xml_locate_language(HandleRef jarg1, HandleRef jarg2, HandleRef jarg3, HandleRef jarg4, HandleRef jarg5, HandleRef jarg6, string jarg7); @@ -16031,18 +16039,18 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; -public class SWIGTYPE_p_f_p_switch_codec__switch_status_t { +public class SWIGTYPE_p_f_p_switch_codec_unsigned_long_p_q_const__switch_codec_settings__switch_status_t { private HandleRef swigCPtr; - internal SWIGTYPE_p_f_p_switch_codec__switch_status_t(IntPtr cPtr, bool futureUse) { + internal SWIGTYPE_p_f_p_switch_codec_unsigned_long_p_q_const__switch_codec_settings__switch_status_t(IntPtr cPtr, bool futureUse) { swigCPtr = new HandleRef(this, cPtr); } - protected SWIGTYPE_p_f_p_switch_codec__switch_status_t() { + protected SWIGTYPE_p_f_p_switch_codec_unsigned_long_p_q_const__switch_codec_settings__switch_status_t() { swigCPtr = new HandleRef(null, IntPtr.Zero); } - internal static HandleRef getCPtr(SWIGTYPE_p_f_p_switch_codec__switch_status_t obj) { + internal static HandleRef getCPtr(SWIGTYPE_p_f_p_switch_codec_unsigned_long_p_q_const__switch_codec_settings__switch_status_t obj) { return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; } } @@ -16061,18 +16069,18 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; -public class SWIGTYPE_p_f_p_switch_codec_unsigned_long_p_q_const__switch_codec_settings__switch_status_t { +public class SWIGTYPE_p_f_p_switch_codec__switch_status_t { private HandleRef swigCPtr; - internal SWIGTYPE_p_f_p_switch_codec_unsigned_long_p_q_const__switch_codec_settings__switch_status_t(IntPtr cPtr, bool futureUse) { + internal SWIGTYPE_p_f_p_switch_codec__switch_status_t(IntPtr cPtr, bool futureUse) { swigCPtr = new HandleRef(this, cPtr); } - protected SWIGTYPE_p_f_p_switch_codec_unsigned_long_p_q_const__switch_codec_settings__switch_status_t() { + protected SWIGTYPE_p_f_p_switch_codec__switch_status_t() { swigCPtr = new HandleRef(null, IntPtr.Zero); } - internal static HandleRef getCPtr(SWIGTYPE_p_f_p_switch_codec_unsigned_long_p_q_const__switch_codec_settings__switch_status_t obj) { + internal static HandleRef getCPtr(SWIGTYPE_p_f_p_switch_codec__switch_status_t obj) { return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; } } @@ -16601,18 +16609,18 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; -public class SWIGTYPE_p_f_p_switch_core_session__switch_status_t { +public class SWIGTYPE_p_f_p_switch_core_session_t_p_void_p_switch_caller_profile_t__p_switch_caller_extension { private HandleRef swigCPtr; - internal SWIGTYPE_p_f_p_switch_core_session__switch_status_t(IntPtr cPtr, bool futureUse) { + internal SWIGTYPE_p_f_p_switch_core_session_t_p_void_p_switch_caller_profile_t__p_switch_caller_extension(IntPtr cPtr, bool futureUse) { swigCPtr = new HandleRef(this, cPtr); } - protected SWIGTYPE_p_f_p_switch_core_session__switch_status_t() { + protected SWIGTYPE_p_f_p_switch_core_session_t_p_void_p_switch_caller_profile_t__p_switch_caller_extension() { swigCPtr = new HandleRef(null, IntPtr.Zero); } - internal static HandleRef getCPtr(SWIGTYPE_p_f_p_switch_core_session__switch_status_t obj) { + internal static HandleRef getCPtr(SWIGTYPE_p_f_p_switch_core_session_t_p_void_p_switch_caller_profile_t__p_switch_caller_extension obj) { return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; } } @@ -16631,18 +16639,18 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; -public class SWIGTYPE_p_f_p_switch_core_session_t_p_void_p_switch_caller_profile_t__p_switch_caller_extension { +public class SWIGTYPE_p_f_p_switch_core_session__switch_status_t { private HandleRef swigCPtr; - internal SWIGTYPE_p_f_p_switch_core_session_t_p_void_p_switch_caller_profile_t__p_switch_caller_extension(IntPtr cPtr, bool futureUse) { + internal SWIGTYPE_p_f_p_switch_core_session__switch_status_t(IntPtr cPtr, bool futureUse) { swigCPtr = new HandleRef(this, cPtr); } - protected SWIGTYPE_p_f_p_switch_core_session_t_p_void_p_switch_caller_profile_t__p_switch_caller_extension() { + protected SWIGTYPE_p_f_p_switch_core_session__switch_status_t() { swigCPtr = new HandleRef(null, IntPtr.Zero); } - internal static HandleRef getCPtr(SWIGTYPE_p_f_p_switch_core_session_t_p_void_p_switch_caller_profile_t__p_switch_caller_extension obj) { + internal static HandleRef getCPtr(SWIGTYPE_p_f_p_switch_core_session__switch_status_t obj) { return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; } } @@ -18821,18 +18829,18 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; -public class SWIGTYPE_p_p_switch_xml_binding { +public class SWIGTYPE_p_p_switch_xml { private HandleRef swigCPtr; - internal SWIGTYPE_p_p_switch_xml_binding(IntPtr cPtr, bool futureUse) { + internal SWIGTYPE_p_p_switch_xml(IntPtr cPtr, bool futureUse) { swigCPtr = new HandleRef(this, cPtr); } - protected SWIGTYPE_p_p_switch_xml_binding() { + protected SWIGTYPE_p_p_switch_xml() { swigCPtr = new HandleRef(null, IntPtr.Zero); } - internal static HandleRef getCPtr(SWIGTYPE_p_p_switch_xml_binding obj) { + internal static HandleRef getCPtr(SWIGTYPE_p_p_switch_xml obj) { return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; } } @@ -18851,18 +18859,18 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; -public class SWIGTYPE_p_p_switch_xml { +public class SWIGTYPE_p_p_switch_xml_binding { private HandleRef swigCPtr; - internal SWIGTYPE_p_p_switch_xml(IntPtr cPtr, bool futureUse) { + internal SWIGTYPE_p_p_switch_xml_binding(IntPtr cPtr, bool futureUse) { swigCPtr = new HandleRef(this, cPtr); } - protected SWIGTYPE_p_p_switch_xml() { + protected SWIGTYPE_p_p_switch_xml_binding() { swigCPtr = new HandleRef(null, IntPtr.Zero); } - internal static HandleRef getCPtr(SWIGTYPE_p_p_switch_xml obj) { + internal static HandleRef getCPtr(SWIGTYPE_p_p_switch_xml_binding obj) { return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; } } @@ -19541,18 +19549,18 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; -public class SWIGTYPE_p_switch_ivr_menu_action_function_t { +public class SWIGTYPE_p_switch_ivr_menu { private HandleRef swigCPtr; - internal SWIGTYPE_p_switch_ivr_menu_action_function_t(IntPtr cPtr, bool futureUse) { + internal SWIGTYPE_p_switch_ivr_menu(IntPtr cPtr, bool futureUse) { swigCPtr = new HandleRef(this, cPtr); } - protected SWIGTYPE_p_switch_ivr_menu_action_function_t() { + protected SWIGTYPE_p_switch_ivr_menu() { swigCPtr = new HandleRef(null, IntPtr.Zero); } - internal static HandleRef getCPtr(SWIGTYPE_p_switch_ivr_menu_action_function_t obj) { + internal static HandleRef getCPtr(SWIGTYPE_p_switch_ivr_menu obj) { return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; } } @@ -19571,18 +19579,18 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; -public class SWIGTYPE_p_switch_ivr_menu { +public class SWIGTYPE_p_switch_ivr_menu_action_function_t { private HandleRef swigCPtr; - internal SWIGTYPE_p_switch_ivr_menu(IntPtr cPtr, bool futureUse) { + internal SWIGTYPE_p_switch_ivr_menu_action_function_t(IntPtr cPtr, bool futureUse) { swigCPtr = new HandleRef(this, cPtr); } - protected SWIGTYPE_p_switch_ivr_menu() { + protected SWIGTYPE_p_switch_ivr_menu_action_function_t() { swigCPtr = new HandleRef(null, IntPtr.Zero); } - internal static HandleRef getCPtr(SWIGTYPE_p_switch_ivr_menu obj) { + internal static HandleRef getCPtr(SWIGTYPE_p_switch_ivr_menu_action_function_t obj) { return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; } } @@ -21880,100 +21888,6 @@ public class switch_cache_db_odbc_options_t : IDisposable { namespace FreeSWITCH.Native { -public enum switch_call_cause_t { - SWITCH_CAUSE_NONE = 0, - SWITCH_CAUSE_UNALLOCATED_NUMBER = 1, - SWITCH_CAUSE_NO_ROUTE_TRANSIT_NET = 2, - SWITCH_CAUSE_NO_ROUTE_DESTINATION = 3, - SWITCH_CAUSE_CHANNEL_UNACCEPTABLE = 6, - SWITCH_CAUSE_CALL_AWARDED_DELIVERED = 7, - SWITCH_CAUSE_NORMAL_CLEARING = 16, - SWITCH_CAUSE_USER_BUSY = 17, - SWITCH_CAUSE_NO_USER_RESPONSE = 18, - SWITCH_CAUSE_NO_ANSWER = 19, - SWITCH_CAUSE_SUBSCRIBER_ABSENT = 20, - SWITCH_CAUSE_CALL_REJECTED = 21, - SWITCH_CAUSE_NUMBER_CHANGED = 22, - SWITCH_CAUSE_REDIRECTION_TO_NEW_DESTINATION = 23, - SWITCH_CAUSE_EXCHANGE_ROUTING_ERROR = 25, - SWITCH_CAUSE_DESTINATION_OUT_OF_ORDER = 27, - SWITCH_CAUSE_INVALID_NUMBER_FORMAT = 28, - SWITCH_CAUSE_FACILITY_REJECTED = 29, - SWITCH_CAUSE_RESPONSE_TO_STATUS_ENQUIRY = 30, - SWITCH_CAUSE_NORMAL_UNSPECIFIED = 31, - SWITCH_CAUSE_NORMAL_CIRCUIT_CONGESTION = 34, - SWITCH_CAUSE_NETWORK_OUT_OF_ORDER = 38, - SWITCH_CAUSE_NORMAL_TEMPORARY_FAILURE = 41, - SWITCH_CAUSE_SWITCH_CONGESTION = 42, - SWITCH_CAUSE_ACCESS_INFO_DISCARDED = 43, - SWITCH_CAUSE_REQUESTED_CHAN_UNAVAIL = 44, - SWITCH_CAUSE_PRE_EMPTED = 45, - SWITCH_CAUSE_FACILITY_NOT_SUBSCRIBED = 50, - SWITCH_CAUSE_OUTGOING_CALL_BARRED = 52, - SWITCH_CAUSE_INCOMING_CALL_BARRED = 54, - SWITCH_CAUSE_BEARERCAPABILITY_NOTAUTH = 57, - SWITCH_CAUSE_BEARERCAPABILITY_NOTAVAIL = 58, - SWITCH_CAUSE_SERVICE_UNAVAILABLE = 63, - SWITCH_CAUSE_BEARERCAPABILITY_NOTIMPL = 65, - SWITCH_CAUSE_CHAN_NOT_IMPLEMENTED = 66, - SWITCH_CAUSE_FACILITY_NOT_IMPLEMENTED = 69, - SWITCH_CAUSE_SERVICE_NOT_IMPLEMENTED = 79, - SWITCH_CAUSE_INVALID_CALL_REFERENCE = 81, - SWITCH_CAUSE_INCOMPATIBLE_DESTINATION = 88, - SWITCH_CAUSE_INVALID_MSG_UNSPECIFIED = 95, - SWITCH_CAUSE_MANDATORY_IE_MISSING = 96, - SWITCH_CAUSE_MESSAGE_TYPE_NONEXIST = 97, - SWITCH_CAUSE_WRONG_MESSAGE = 98, - SWITCH_CAUSE_IE_NONEXIST = 99, - SWITCH_CAUSE_INVALID_IE_CONTENTS = 100, - SWITCH_CAUSE_WRONG_CALL_STATE = 101, - SWITCH_CAUSE_RECOVERY_ON_TIMER_EXPIRE = 102, - SWITCH_CAUSE_MANDATORY_IE_LENGTH_ERROR = 103, - SWITCH_CAUSE_PROTOCOL_ERROR = 111, - SWITCH_CAUSE_INTERWORKING = 127, - SWITCH_CAUSE_SUCCESS = 142, - SWITCH_CAUSE_ORIGINATOR_CANCEL = 487, - SWITCH_CAUSE_CRASH = 500, - SWITCH_CAUSE_SYSTEM_SHUTDOWN = 501, - SWITCH_CAUSE_LOSE_RACE = 502, - SWITCH_CAUSE_MANAGER_REQUEST = 503, - SWITCH_CAUSE_BLIND_TRANSFER = 600, - SWITCH_CAUSE_ATTENDED_TRANSFER = 601, - SWITCH_CAUSE_ALLOTTED_TIMEOUT = 602, - SWITCH_CAUSE_USER_CHALLENGE = 603, - SWITCH_CAUSE_MEDIA_TIMEOUT = 604, - SWITCH_CAUSE_PICKED_OFF = 605, - SWITCH_CAUSE_USER_NOT_REGISTERED = 606, - SWITCH_CAUSE_PROGRESS_TIMEOUT = 607 -} - -} -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.35 - * - * Do not make changes to this file unless you know what you are doing--modify - * the SWIG interface file instead. - * ----------------------------------------------------------------------------- */ - -namespace FreeSWITCH.Native { - -public enum switch_call_direction_t { - SWITCH_CALL_DIRECTION_INBOUND, - SWITCH_CALL_DIRECTION_OUTBOUND -} - -} -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.35 - * - * Do not make changes to this file unless you know what you are doing--modify - * the SWIG interface file instead. - * ----------------------------------------------------------------------------- */ - -namespace FreeSWITCH.Native { - using System; using System.Runtime.InteropServices; @@ -22639,6 +22553,100 @@ namespace FreeSWITCH.Native { namespace FreeSWITCH.Native { +public enum switch_call_cause_t { + SWITCH_CAUSE_NONE = 0, + SWITCH_CAUSE_UNALLOCATED_NUMBER = 1, + SWITCH_CAUSE_NO_ROUTE_TRANSIT_NET = 2, + SWITCH_CAUSE_NO_ROUTE_DESTINATION = 3, + SWITCH_CAUSE_CHANNEL_UNACCEPTABLE = 6, + SWITCH_CAUSE_CALL_AWARDED_DELIVERED = 7, + SWITCH_CAUSE_NORMAL_CLEARING = 16, + SWITCH_CAUSE_USER_BUSY = 17, + SWITCH_CAUSE_NO_USER_RESPONSE = 18, + SWITCH_CAUSE_NO_ANSWER = 19, + SWITCH_CAUSE_SUBSCRIBER_ABSENT = 20, + SWITCH_CAUSE_CALL_REJECTED = 21, + SWITCH_CAUSE_NUMBER_CHANGED = 22, + SWITCH_CAUSE_REDIRECTION_TO_NEW_DESTINATION = 23, + SWITCH_CAUSE_EXCHANGE_ROUTING_ERROR = 25, + SWITCH_CAUSE_DESTINATION_OUT_OF_ORDER = 27, + SWITCH_CAUSE_INVALID_NUMBER_FORMAT = 28, + SWITCH_CAUSE_FACILITY_REJECTED = 29, + SWITCH_CAUSE_RESPONSE_TO_STATUS_ENQUIRY = 30, + SWITCH_CAUSE_NORMAL_UNSPECIFIED = 31, + SWITCH_CAUSE_NORMAL_CIRCUIT_CONGESTION = 34, + SWITCH_CAUSE_NETWORK_OUT_OF_ORDER = 38, + SWITCH_CAUSE_NORMAL_TEMPORARY_FAILURE = 41, + SWITCH_CAUSE_SWITCH_CONGESTION = 42, + SWITCH_CAUSE_ACCESS_INFO_DISCARDED = 43, + SWITCH_CAUSE_REQUESTED_CHAN_UNAVAIL = 44, + SWITCH_CAUSE_PRE_EMPTED = 45, + SWITCH_CAUSE_FACILITY_NOT_SUBSCRIBED = 50, + SWITCH_CAUSE_OUTGOING_CALL_BARRED = 52, + SWITCH_CAUSE_INCOMING_CALL_BARRED = 54, + SWITCH_CAUSE_BEARERCAPABILITY_NOTAUTH = 57, + SWITCH_CAUSE_BEARERCAPABILITY_NOTAVAIL = 58, + SWITCH_CAUSE_SERVICE_UNAVAILABLE = 63, + SWITCH_CAUSE_BEARERCAPABILITY_NOTIMPL = 65, + SWITCH_CAUSE_CHAN_NOT_IMPLEMENTED = 66, + SWITCH_CAUSE_FACILITY_NOT_IMPLEMENTED = 69, + SWITCH_CAUSE_SERVICE_NOT_IMPLEMENTED = 79, + SWITCH_CAUSE_INVALID_CALL_REFERENCE = 81, + SWITCH_CAUSE_INCOMPATIBLE_DESTINATION = 88, + SWITCH_CAUSE_INVALID_MSG_UNSPECIFIED = 95, + SWITCH_CAUSE_MANDATORY_IE_MISSING = 96, + SWITCH_CAUSE_MESSAGE_TYPE_NONEXIST = 97, + SWITCH_CAUSE_WRONG_MESSAGE = 98, + SWITCH_CAUSE_IE_NONEXIST = 99, + SWITCH_CAUSE_INVALID_IE_CONTENTS = 100, + SWITCH_CAUSE_WRONG_CALL_STATE = 101, + SWITCH_CAUSE_RECOVERY_ON_TIMER_EXPIRE = 102, + SWITCH_CAUSE_MANDATORY_IE_LENGTH_ERROR = 103, + SWITCH_CAUSE_PROTOCOL_ERROR = 111, + SWITCH_CAUSE_INTERWORKING = 127, + SWITCH_CAUSE_SUCCESS = 142, + SWITCH_CAUSE_ORIGINATOR_CANCEL = 487, + SWITCH_CAUSE_CRASH = 500, + SWITCH_CAUSE_SYSTEM_SHUTDOWN = 501, + SWITCH_CAUSE_LOSE_RACE = 502, + SWITCH_CAUSE_MANAGER_REQUEST = 503, + SWITCH_CAUSE_BLIND_TRANSFER = 600, + SWITCH_CAUSE_ATTENDED_TRANSFER = 601, + SWITCH_CAUSE_ALLOTTED_TIMEOUT = 602, + SWITCH_CAUSE_USER_CHALLENGE = 603, + SWITCH_CAUSE_MEDIA_TIMEOUT = 604, + SWITCH_CAUSE_PICKED_OFF = 605, + SWITCH_CAUSE_USER_NOT_REGISTERED = 606, + SWITCH_CAUSE_PROGRESS_TIMEOUT = 607 +} + +} +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 1.3.35 + * + * Do not make changes to this file unless you know what you are doing--modify + * the SWIG interface file instead. + * ----------------------------------------------------------------------------- */ + +namespace FreeSWITCH.Native { + +public enum switch_call_direction_t { + SWITCH_CALL_DIRECTION_INBOUND, + SWITCH_CALL_DIRECTION_OUTBOUND +} + +} +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 1.3.35 + * + * Do not make changes to this file unless you know what you are doing--modify + * the SWIG interface file instead. + * ----------------------------------------------------------------------------- */ + +namespace FreeSWITCH.Native { + public enum switch_channel_app_flag_t { CF_APP_TAGGED = (1 << 0), CF_APP_T38 = (1 << 1), @@ -27215,6 +27223,196 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; +public class switch_io_event_hooks : IDisposable { + private HandleRef swigCPtr; + protected bool swigCMemOwn; + + internal switch_io_event_hooks(IntPtr cPtr, bool cMemoryOwn) { + swigCMemOwn = cMemoryOwn; + swigCPtr = new HandleRef(this, cPtr); + } + + internal static HandleRef getCPtr(switch_io_event_hooks obj) { + return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; + } + + ~switch_io_event_hooks() { + Dispose(); + } + + public virtual void Dispose() { + lock(this) { + if(swigCPtr.Handle != IntPtr.Zero && swigCMemOwn) { + swigCMemOwn = false; + freeswitchPINVOKE.delete_switch_io_event_hooks(swigCPtr); + } + swigCPtr = new HandleRef(null, IntPtr.Zero); + GC.SuppressFinalize(this); + } + } + + public switch_io_event_hook_outgoing_channel outgoing_channel { + set { + freeswitchPINVOKE.switch_io_event_hooks_outgoing_channel_set(swigCPtr, switch_io_event_hook_outgoing_channel.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_outgoing_channel_get(swigCPtr); + switch_io_event_hook_outgoing_channel ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_outgoing_channel(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_receive_message receive_message { + set { + freeswitchPINVOKE.switch_io_event_hooks_receive_message_set(swigCPtr, switch_io_event_hook_receive_message.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_receive_message_get(swigCPtr); + switch_io_event_hook_receive_message ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_receive_message(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_receive_event receive_event { + set { + freeswitchPINVOKE.switch_io_event_hooks_receive_event_set(swigCPtr, switch_io_event_hook_receive_event.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_receive_event_get(swigCPtr); + switch_io_event_hook_receive_event ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_receive_event(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_read_frame read_frame { + set { + freeswitchPINVOKE.switch_io_event_hooks_read_frame_set(swigCPtr, switch_io_event_hook_read_frame.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_read_frame_get(swigCPtr); + switch_io_event_hook_read_frame ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_read_frame(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_video_read_frame video_read_frame { + set { + freeswitchPINVOKE.switch_io_event_hooks_video_read_frame_set(swigCPtr, switch_io_event_hook_video_read_frame.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_video_read_frame_get(swigCPtr); + switch_io_event_hook_video_read_frame ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_video_read_frame(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_write_frame write_frame { + set { + freeswitchPINVOKE.switch_io_event_hooks_write_frame_set(swigCPtr, switch_io_event_hook_write_frame.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_write_frame_get(swigCPtr); + switch_io_event_hook_write_frame ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_write_frame(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_video_write_frame video_write_frame { + set { + freeswitchPINVOKE.switch_io_event_hooks_video_write_frame_set(swigCPtr, switch_io_event_hook_video_write_frame.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_video_write_frame_get(swigCPtr); + switch_io_event_hook_video_write_frame ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_video_write_frame(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_kill_channel kill_channel { + set { + freeswitchPINVOKE.switch_io_event_hooks_kill_channel_set(swigCPtr, switch_io_event_hook_kill_channel.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_kill_channel_get(swigCPtr); + switch_io_event_hook_kill_channel ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_kill_channel(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_send_dtmf send_dtmf { + set { + freeswitchPINVOKE.switch_io_event_hooks_send_dtmf_set(swigCPtr, switch_io_event_hook_send_dtmf.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_send_dtmf_get(swigCPtr); + switch_io_event_hook_send_dtmf ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_send_dtmf(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_recv_dtmf recv_dtmf { + set { + freeswitchPINVOKE.switch_io_event_hooks_recv_dtmf_set(swigCPtr, switch_io_event_hook_recv_dtmf.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_recv_dtmf_get(swigCPtr); + switch_io_event_hook_recv_dtmf ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_recv_dtmf(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_state_change state_change { + set { + freeswitchPINVOKE.switch_io_event_hooks_state_change_set(swigCPtr, switch_io_event_hook_state_change.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_state_change_get(swigCPtr); + switch_io_event_hook_state_change ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_state_change(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_state_run state_run { + set { + freeswitchPINVOKE.switch_io_event_hooks_state_run_set(swigCPtr, switch_io_event_hook_state_run.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_state_run_get(swigCPtr); + switch_io_event_hook_state_run ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_state_run(cPtr, false); + return ret; + } + } + + public switch_io_event_hook_resurrect_session resurrect_session { + set { + freeswitchPINVOKE.switch_io_event_hooks_resurrect_session_set(swigCPtr, switch_io_event_hook_resurrect_session.getCPtr(value)); + } + get { + IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_resurrect_session_get(swigCPtr); + switch_io_event_hook_resurrect_session ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_resurrect_session(cPtr, false); + return ret; + } + } + + public switch_io_event_hooks() : this(freeswitchPINVOKE.new_switch_io_event_hooks(), true) { + } + +} + +} +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 1.3.35 + * + * Do not make changes to this file unless you know what you are doing--modify + * the SWIG interface file instead. + * ----------------------------------------------------------------------------- */ + +namespace FreeSWITCH.Native { + +using System; +using System.Runtime.InteropServices; + public class switch_io_event_hook_kill_channel : IDisposable { private HandleRef swigCPtr; protected bool swigCMemOwn; @@ -27698,196 +27896,6 @@ namespace FreeSWITCH.Native { using System; using System.Runtime.InteropServices; -public class switch_io_event_hooks : IDisposable { - private HandleRef swigCPtr; - protected bool swigCMemOwn; - - internal switch_io_event_hooks(IntPtr cPtr, bool cMemoryOwn) { - swigCMemOwn = cMemoryOwn; - swigCPtr = new HandleRef(this, cPtr); - } - - internal static HandleRef getCPtr(switch_io_event_hooks obj) { - return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; - } - - ~switch_io_event_hooks() { - Dispose(); - } - - public virtual void Dispose() { - lock(this) { - if(swigCPtr.Handle != IntPtr.Zero && swigCMemOwn) { - swigCMemOwn = false; - freeswitchPINVOKE.delete_switch_io_event_hooks(swigCPtr); - } - swigCPtr = new HandleRef(null, IntPtr.Zero); - GC.SuppressFinalize(this); - } - } - - public switch_io_event_hook_outgoing_channel outgoing_channel { - set { - freeswitchPINVOKE.switch_io_event_hooks_outgoing_channel_set(swigCPtr, switch_io_event_hook_outgoing_channel.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_outgoing_channel_get(swigCPtr); - switch_io_event_hook_outgoing_channel ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_outgoing_channel(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_receive_message receive_message { - set { - freeswitchPINVOKE.switch_io_event_hooks_receive_message_set(swigCPtr, switch_io_event_hook_receive_message.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_receive_message_get(swigCPtr); - switch_io_event_hook_receive_message ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_receive_message(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_receive_event receive_event { - set { - freeswitchPINVOKE.switch_io_event_hooks_receive_event_set(swigCPtr, switch_io_event_hook_receive_event.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_receive_event_get(swigCPtr); - switch_io_event_hook_receive_event ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_receive_event(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_read_frame read_frame { - set { - freeswitchPINVOKE.switch_io_event_hooks_read_frame_set(swigCPtr, switch_io_event_hook_read_frame.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_read_frame_get(swigCPtr); - switch_io_event_hook_read_frame ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_read_frame(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_video_read_frame video_read_frame { - set { - freeswitchPINVOKE.switch_io_event_hooks_video_read_frame_set(swigCPtr, switch_io_event_hook_video_read_frame.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_video_read_frame_get(swigCPtr); - switch_io_event_hook_video_read_frame ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_video_read_frame(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_write_frame write_frame { - set { - freeswitchPINVOKE.switch_io_event_hooks_write_frame_set(swigCPtr, switch_io_event_hook_write_frame.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_write_frame_get(swigCPtr); - switch_io_event_hook_write_frame ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_write_frame(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_video_write_frame video_write_frame { - set { - freeswitchPINVOKE.switch_io_event_hooks_video_write_frame_set(swigCPtr, switch_io_event_hook_video_write_frame.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_video_write_frame_get(swigCPtr); - switch_io_event_hook_video_write_frame ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_video_write_frame(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_kill_channel kill_channel { - set { - freeswitchPINVOKE.switch_io_event_hooks_kill_channel_set(swigCPtr, switch_io_event_hook_kill_channel.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_kill_channel_get(swigCPtr); - switch_io_event_hook_kill_channel ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_kill_channel(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_send_dtmf send_dtmf { - set { - freeswitchPINVOKE.switch_io_event_hooks_send_dtmf_set(swigCPtr, switch_io_event_hook_send_dtmf.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_send_dtmf_get(swigCPtr); - switch_io_event_hook_send_dtmf ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_send_dtmf(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_recv_dtmf recv_dtmf { - set { - freeswitchPINVOKE.switch_io_event_hooks_recv_dtmf_set(swigCPtr, switch_io_event_hook_recv_dtmf.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_recv_dtmf_get(swigCPtr); - switch_io_event_hook_recv_dtmf ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_recv_dtmf(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_state_change state_change { - set { - freeswitchPINVOKE.switch_io_event_hooks_state_change_set(swigCPtr, switch_io_event_hook_state_change.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_state_change_get(swigCPtr); - switch_io_event_hook_state_change ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_state_change(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_state_run state_run { - set { - freeswitchPINVOKE.switch_io_event_hooks_state_run_set(swigCPtr, switch_io_event_hook_state_run.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_state_run_get(swigCPtr); - switch_io_event_hook_state_run ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_state_run(cPtr, false); - return ret; - } - } - - public switch_io_event_hook_resurrect_session resurrect_session { - set { - freeswitchPINVOKE.switch_io_event_hooks_resurrect_session_set(swigCPtr, switch_io_event_hook_resurrect_session.getCPtr(value)); - } - get { - IntPtr cPtr = freeswitchPINVOKE.switch_io_event_hooks_resurrect_session_get(swigCPtr); - switch_io_event_hook_resurrect_session ret = (cPtr == IntPtr.Zero) ? null : new switch_io_event_hook_resurrect_session(cPtr, false); - return ret; - } - } - - public switch_io_event_hooks() : this(freeswitchPINVOKE.new_switch_io_event_hooks(), true) { - } - -} - -} -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.35 - * - * Do not make changes to this file unless you know what you are doing--modify - * the SWIG interface file instead. - * ----------------------------------------------------------------------------- */ - -namespace FreeSWITCH.Native { - -using System; -using System.Runtime.InteropServices; - public class switch_io_event_hook_send_dtmf : IDisposable { private HandleRef swigCPtr; protected bool swigCMemOwn; @@ -28316,31 +28324,6 @@ namespace FreeSWITCH.Native { namespace FreeSWITCH.Native { -public enum switch_io_routine_name_t { - SWITCH_IO_OUTGOING_CHANNEL, - SWITCH_IO_READ_FRAME, - SWITCH_IO_WRITE_FRAME, - SWITCH_IO_KILL_CHANNEL, - SWITCH_IO_SEND_DTMF, - SWITCH_IO_RECEIVE_MESSAGE, - SWITCH_IO_RECEIVE_EVENT, - SWITCH_IO_STATE_CHANGE, - SWITCH_IO_READ_VIDEO_FRAME, - SWITCH_IO_WRITE_VIDEO_FRAME, - SWITCH_IO_RESURRECT_SESSION -} - -} -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.35 - * - * Do not make changes to this file unless you know what you are doing--modify - * the SWIG interface file instead. - * ----------------------------------------------------------------------------- */ - -namespace FreeSWITCH.Native { - using System; using System.Runtime.InteropServices; @@ -28531,6 +28514,31 @@ public class switch_io_routines : IDisposable { namespace FreeSWITCH.Native { +public enum switch_io_routine_name_t { + SWITCH_IO_OUTGOING_CHANNEL, + SWITCH_IO_READ_FRAME, + SWITCH_IO_WRITE_FRAME, + SWITCH_IO_KILL_CHANNEL, + SWITCH_IO_SEND_DTMF, + SWITCH_IO_RECEIVE_MESSAGE, + SWITCH_IO_RECEIVE_EVENT, + SWITCH_IO_STATE_CHANGE, + SWITCH_IO_READ_VIDEO_FRAME, + SWITCH_IO_WRITE_VIDEO_FRAME, + SWITCH_IO_RESURRECT_SESSION +} + +} +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 1.3.35 + * + * Do not make changes to this file unless you know what you are doing--modify + * the SWIG interface file instead. + * ----------------------------------------------------------------------------- */ + +namespace FreeSWITCH.Native { + public enum switch_ivr_action_t { SWITCH_IVR_ACTION_DIE, SWITCH_IVR_ACTION_EXECMENU, diff --git a/src/switch_core_io.c b/src/switch_core_io.c index e27bf86d0f..d8a519a294 100644 --- a/src/switch_core_io.c +++ b/src/switch_core_io.c @@ -369,7 +369,7 @@ SWITCH_DECLARE(switch_status_t) switch_core_session_read_frame(switch_core_sessi } if (status == SWITCH_STATUS_SUCCESS) { - if ((switch_channel_test_flag(session->channel, CF_JITTERBUFFER) || switch_channel_test_flag(session->channel, CF_CNG_PLC)) + if ((switch_channel_test_flag(session->channel, CF_JITTERBUFFER_PLC) || switch_channel_test_flag(session->channel, CF_CNG_PLC)) && !session->plc) { session->plc = plc_init(NULL); } diff --git a/src/switch_core_session.c b/src/switch_core_session.c index 54a4cd11c4..2c7928061b 100644 --- a/src/switch_core_session.c +++ b/src/switch_core_session.c @@ -1611,6 +1611,7 @@ SWITCH_DECLARE(switch_core_session_t *) switch_core_session_request_xml(switch_e flags[CF_BRIDGE_NOWRITE] = 0; flags[CF_RECOVERED] = 0; flags[CF_JITTERBUFFER] = 0; + flags[CF_JITTERBUFFER_PLC] = 0; flags[CF_DIALPLAN] = 0; flags[CF_BLOCK_BROADCAST_UNTIL_MEDIA] = 0; flags[CF_CNG_PLC] = 0; diff --git a/src/switch_xml.c b/src/switch_xml.c index d4d7c3f12d..7790c17612 100644 --- a/src/switch_xml.c +++ b/src/switch_xml.c @@ -2783,7 +2783,8 @@ SWITCH_DECLARE(switch_xml_t) switch_xml_cut(switch_xml_t xml) return xml; } -SWITCH_DECLARE(int) switch_xml_std_datetime_check(switch_xml_t xcond) { +SWITCH_DECLARE(int) switch_xml_std_datetime_check(switch_xml_t xcond, int *offset) +{ const char *xdt = switch_xml_attr(xcond, "date-time"); const char *xyear = switch_xml_attr(xcond, "year"); @@ -2797,12 +2798,24 @@ SWITCH_DECLARE(int) switch_xml_std_datetime_check(switch_xml_t xcond) { const char *xminute = switch_xml_attr(xcond, "minute"); const char *xminday = switch_xml_attr(xcond, "minute-of-day"); const char *xtod = switch_xml_attr(xcond, "time-of-day"); + const char *tzoff = switch_xml_attr(xcond, "tz-offset"); + int loffset = 0; switch_time_t ts = switch_micro_time_now(); int time_match = -1; switch_time_exp_t tm; - switch_time_exp_lt(&tm, ts); + if (!zstr(tzoff) && switch_is_number(tzoff)) { + loffset = atoi(tzoff); + offset = &loffset; + } + + + if (offset) { + switch_time_exp_tz(&tm, ts, *offset); + } else { + switch_time_exp_lt(&tm, ts); + } if (time_match && xdt) { char tmpdate[80];