mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-10-18 09:14:14 +00:00
add session.hangupCause()
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@14912 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
1 parent
3aeeda1d69
commit
c54f0c3945
12 files changed
+668
-58
No files matched your search
@@ -938,6 +938,17 @@ SWIGEXPORT char * SWIGSTDCALL CSharp_SWITCH_URL_SEPARATOR_get() {
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT char * SWIGSTDCALL CSharp_SWITCH_AUDIO_SPOOL_PATH_VARIABLE_get() {
|
||||
char * jresult ;
|
||||
char *result = 0 ;
|
||||
|
||||
result = (char *) "audio_spool_path";
|
||||
|
||||
jresult = SWIG_csharp_string_callback((const char *)result);
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT char * SWIGSTDCALL CSharp_SWITCH_BRIDGE_HANGUP_CAUSE_VARIABLE_get() {
|
||||
char * jresult ;
|
||||
char *result = 0 ;
|
||||
@@ -9450,6 +9461,18 @@ SWIGEXPORT char * SWIGSTDCALL CSharp_switch_find_end_paren(char * jarg1, char ja
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT int SWIGSTDCALL CSharp_switch_is_file_path(char * jarg1) {
|
||||
int jresult ;
|
||||
char *arg1 = (char *) 0 ;
|
||||
switch_bool_t result;
|
||||
|
||||
arg1 = (char *)jarg1;
|
||||
result = (switch_bool_t)switch_is_file_path((char const *)arg1);
|
||||
jresult = result;
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT int SWIGSTDCALL CSharp_switch_parse_cidr(char * jarg1, void * jarg2, void * jarg3, void * jarg4) {
|
||||
int jresult ;
|
||||
char *arg1 = (char *) 0 ;
|
||||
@@ -14250,6 +14273,66 @@ SWIGEXPORT int SWIGSTDCALL CSharp_switch_file_handle_line_get(void * jarg1) {
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void SWIGSTDCALL CSharp_switch_file_handle_file_path_set(void * jarg1, char * jarg2) {
|
||||
switch_file_handle *arg1 = (switch_file_handle *) 0 ;
|
||||
char *arg2 = (char *) 0 ;
|
||||
|
||||
arg1 = (switch_file_handle *)jarg1;
|
||||
arg2 = (char *)jarg2;
|
||||
{
|
||||
if (arg1->file_path) delete [] arg1->file_path;
|
||||
if (arg2) {
|
||||
arg1->file_path = (char *) (new char[strlen((const char *)arg2)+1]);
|
||||
strcpy((char *)arg1->file_path, (const char *)arg2);
|
||||
} else {
|
||||
arg1->file_path = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT char * SWIGSTDCALL CSharp_switch_file_handle_file_path_get(void * jarg1) {
|
||||
char * jresult ;
|
||||
switch_file_handle *arg1 = (switch_file_handle *) 0 ;
|
||||
char *result = 0 ;
|
||||
|
||||
arg1 = (switch_file_handle *)jarg1;
|
||||
result = (char *) ((arg1)->file_path);
|
||||
jresult = SWIG_csharp_string_callback((const char *)result);
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void SWIGSTDCALL CSharp_switch_file_handle_spool_path_set(void * jarg1, char * jarg2) {
|
||||
switch_file_handle *arg1 = (switch_file_handle *) 0 ;
|
||||
char *arg2 = (char *) 0 ;
|
||||
|
||||
arg1 = (switch_file_handle *)jarg1;
|
||||
arg2 = (char *)jarg2;
|
||||
{
|
||||
if (arg1->spool_path) delete [] arg1->spool_path;
|
||||
if (arg2) {
|
||||
arg1->spool_path = (char *) (new char[strlen((const char *)arg2)+1]);
|
||||
strcpy((char *)arg1->spool_path, (const char *)arg2);
|
||||
} else {
|
||||
arg1->spool_path = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT char * SWIGSTDCALL CSharp_switch_file_handle_spool_path_get(void * jarg1) {
|
||||
char * jresult ;
|
||||
switch_file_handle *arg1 = (switch_file_handle *) 0 ;
|
||||
char *result = 0 ;
|
||||
|
||||
arg1 = (switch_file_handle *)jarg1;
|
||||
result = (char *) ((arg1)->spool_path);
|
||||
jresult = SWIG_csharp_string_callback((const char *)result);
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_new_switch_file_handle() {
|
||||
void * jresult ;
|
||||
switch_file_handle *result = 0 ;
|
||||
@@ -20599,6 +20682,29 @@ SWIGEXPORT void * SWIGSTDCALL CSharp_switch_event_next_get(void * jarg1) {
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void SWIGSTDCALL CSharp_switch_event_flags_set(void * jarg1, int jarg2) {
|
||||
switch_event *arg1 = (switch_event *) 0 ;
|
||||
int arg2 ;
|
||||
|
||||
arg1 = (switch_event *)jarg1;
|
||||
arg2 = (int)jarg2;
|
||||
if (arg1) (arg1)->flags = arg2;
|
||||
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT int SWIGSTDCALL CSharp_switch_event_flags_get(void * jarg1) {
|
||||
int jresult ;
|
||||
switch_event *arg1 = (switch_event *) 0 ;
|
||||
int result;
|
||||
|
||||
arg1 = (switch_event *)jarg1;
|
||||
result = (int) ((arg1)->flags);
|
||||
jresult = result;
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void * SWIGSTDCALL CSharp_new_switch_event() {
|
||||
void * jresult ;
|
||||
switch_event *result = 0 ;
|
||||
@@ -28441,6 +28547,29 @@ SWIGEXPORT int SWIGSTDCALL CSharp_CoreSession_HookState_get(void * jarg1) {
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void SWIGSTDCALL CSharp_CoreSession_cause_set(void * jarg1, int jarg2) {
|
||||
CoreSession *arg1 = (CoreSession *) 0 ;
|
||||
switch_call_cause_t arg2 ;
|
||||
|
||||
arg1 = (CoreSession *)jarg1;
|
||||
arg2 = (switch_call_cause_t)jarg2;
|
||||
if (arg1) (arg1)->cause = arg2;
|
||||
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT int SWIGSTDCALL CSharp_CoreSession_cause_get(void * jarg1) {
|
||||
int jresult ;
|
||||
CoreSession *arg1 = (CoreSession *) 0 ;
|
||||
switch_call_cause_t result;
|
||||
|
||||
arg1 = (CoreSession *)jarg1;
|
||||
result = (switch_call_cause_t) ((arg1)->cause);
|
||||
jresult = result;
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT void SWIGSTDCALL CSharp_CoreSession_uuid_set(void * jarg1, char * jarg2) {
|
||||
CoreSession *arg1 = (CoreSession *) 0 ;
|
||||
char *arg2 = (char *) 0 ;
|
||||
@@ -28647,6 +28776,18 @@ SWIGEXPORT void SWIGSTDCALL CSharp_CoreSession_SayPhrase(void * jarg1, char * ja
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT char * SWIGSTDCALL CSharp_CoreSession_hangupCause(void * jarg1) {
|
||||
char * jresult ;
|
||||
CoreSession *arg1 = (CoreSession *) 0 ;
|
||||
char *result = 0 ;
|
||||
|
||||
arg1 = (CoreSession *)jarg1;
|
||||
result = (char *)(arg1)->hangupCause();
|
||||
jresult = SWIG_csharp_string_callback((const char *)result);
|
||||
return jresult;
|
||||
}
|
||||
|
||||
|
||||
SWIGEXPORT int SWIGSTDCALL CSharp_CoreSession_RecordFile(void * jarg1, char * jarg2, int jarg3, int jarg4, int jarg5) {
|
||||
int jresult ;
|
||||
CoreSession *arg1 = (CoreSession *) 0 ;
|
||||
|
||||
@@ -164,6 +164,16 @@ public class CoreSession : IDisposable {
|
||||
}
|
||||
}
|
||||
|
||||
public switch_call_cause_t cause {
|
||||
set {
|
||||
freeswitchPINVOKE.CoreSession_cause_set(swigCPtr, (int)value);
|
||||
}
|
||||
get {
|
||||
switch_call_cause_t ret = (switch_call_cause_t)freeswitchPINVOKE.CoreSession_cause_get(swigCPtr);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
public string uuid {
|
||||
set {
|
||||
freeswitchPINVOKE.CoreSession_uuid_set(swigCPtr, value);
|
||||
@@ -235,6 +245,11 @@ public class CoreSession : IDisposable {
|
||||
freeswitchPINVOKE.CoreSession_SayPhrase(swigCPtr, phrase_name, phrase_data, phrase_lang);
|
||||
}
|
||||
|
||||
public string hangupCause() {
|
||||
string ret = freeswitchPINVOKE.CoreSession_hangupCause(swigCPtr);
|
||||
return ret;
|
||||
}
|
||||
|
||||
public int RecordFile(string file_name, int time_limit, int silence_threshold, int silence_hits) {
|
||||
int ret = freeswitchPINVOKE.CoreSession_RecordFile(swigCPtr, file_name, time_limit, silence_threshold, silence_hits);
|
||||
return ret;
|
||||
@@ -2348,6 +2363,11 @@ public class freeswitch {
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static switch_bool_t switch_is_file_path(string file) {
|
||||
switch_bool_t ret = (switch_bool_t)freeswitchPINVOKE.switch_is_file_path(file);
|
||||
return ret;
|
||||
}
|
||||
|
||||
public static int switch_parse_cidr(string arg0, SWIGTYPE_p_unsigned_long ip, SWIGTYPE_p_unsigned_long mask, SWIGTYPE_p_unsigned_long bitp) {
|
||||
int ret = freeswitchPINVOKE.switch_parse_cidr(arg0, SWIGTYPE_p_unsigned_long.getCPtr(ip), SWIGTYPE_p_unsigned_long.getCPtr(mask), SWIGTYPE_p_unsigned_long.getCPtr(bitp));
|
||||
return ret;
|
||||
@@ -4309,6 +4329,7 @@ public class freeswitch {
|
||||
public static readonly int SWITCH_MAX_DTMF_DURATION = freeswitchPINVOKE.SWITCH_MAX_DTMF_DURATION_get();
|
||||
public static readonly string SWITCH_PATH_SEPARATOR = freeswitchPINVOKE.SWITCH_PATH_SEPARATOR_get();
|
||||
public static readonly string SWITCH_URL_SEPARATOR = freeswitchPINVOKE.SWITCH_URL_SEPARATOR_get();
|
||||
public static readonly string SWITCH_AUDIO_SPOOL_PATH_VARIABLE = freeswitchPINVOKE.SWITCH_AUDIO_SPOOL_PATH_VARIABLE_get();
|
||||
public static readonly string SWITCH_BRIDGE_HANGUP_CAUSE_VARIABLE = freeswitchPINVOKE.SWITCH_BRIDGE_HANGUP_CAUSE_VARIABLE_get();
|
||||
public static readonly string SWITCH_READ_TERMINATOR_USED_VARIABLE = freeswitchPINVOKE.SWITCH_READ_TERMINATOR_USED_VARIABLE_get();
|
||||
public static readonly string SWITCH_SEND_SILENCE_WHEN_IDLE_VARIABLE = freeswitchPINVOKE.SWITCH_SEND_SILENCE_WHEN_IDLE_VARIABLE_get();
|
||||
@@ -4791,6 +4812,9 @@ class freeswitchPINVOKE {
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_SWITCH_URL_SEPARATOR_get")]
|
||||
public static extern string SWITCH_URL_SEPARATOR_get();
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_SWITCH_AUDIO_SPOOL_PATH_VARIABLE_get")]
|
||||
public static extern string SWITCH_AUDIO_SPOOL_PATH_VARIABLE_get();
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_SWITCH_BRIDGE_HANGUP_CAUSE_VARIABLE_get")]
|
||||
public static extern string SWITCH_BRIDGE_HANGUP_CAUSE_VARIABLE_get();
|
||||
|
||||
@@ -6780,6 +6804,9 @@ class freeswitchPINVOKE {
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_switch_find_end_paren")]
|
||||
public static extern string switch_find_end_paren(string jarg1, char jarg2, char jarg3);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_switch_is_file_path")]
|
||||
public static extern int switch_is_file_path(string jarg1);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_switch_parse_cidr")]
|
||||
public static extern int switch_parse_cidr(string jarg1, HandleRef jarg2, HandleRef jarg3, HandleRef jarg4);
|
||||
|
||||
@@ -7962,6 +7989,18 @@ class freeswitchPINVOKE {
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_switch_file_handle_line_get")]
|
||||
public static extern int switch_file_handle_line_get(HandleRef jarg1);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_switch_file_handle_file_path_set")]
|
||||
public static extern void switch_file_handle_file_path_set(HandleRef jarg1, string jarg2);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_switch_file_handle_file_path_get")]
|
||||
public static extern string switch_file_handle_file_path_get(HandleRef jarg1);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_switch_file_handle_spool_path_set")]
|
||||
public static extern void switch_file_handle_spool_path_set(HandleRef jarg1, string jarg2);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_switch_file_handle_spool_path_get")]
|
||||
public static extern string switch_file_handle_spool_path_get(HandleRef jarg1);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_new_switch_file_handle")]
|
||||
public static extern IntPtr new_switch_file_handle();
|
||||
|
||||
@@ -9519,6 +9558,12 @@ class freeswitchPINVOKE {
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_switch_event_next_get")]
|
||||
public static extern IntPtr switch_event_next_get(HandleRef jarg1);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_switch_event_flags_set")]
|
||||
public static extern void switch_event_flags_set(HandleRef jarg1, int jarg2);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_switch_event_flags_get")]
|
||||
public static extern int switch_event_flags_get(HandleRef jarg1);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_new_switch_event")]
|
||||
public static extern IntPtr new_switch_event();
|
||||
|
||||
@@ -11289,6 +11334,12 @@ class freeswitchPINVOKE {
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_CoreSession_HookState_get")]
|
||||
public static extern int CoreSession_HookState_get(HandleRef jarg1);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_CoreSession_cause_set")]
|
||||
public static extern void CoreSession_cause_set(HandleRef jarg1, int jarg2);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_CoreSession_cause_get")]
|
||||
public static extern int CoreSession_cause_get(HandleRef jarg1);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_CoreSession_uuid_set")]
|
||||
public static extern void CoreSession_uuid_set(HandleRef jarg1, string jarg2);
|
||||
|
||||
@@ -11334,6 +11385,9 @@ class freeswitchPINVOKE {
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_CoreSession_SayPhrase")]
|
||||
public static extern void CoreSession_SayPhrase(HandleRef jarg1, string jarg2, string jarg3, string jarg4);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_CoreSession_hangupCause")]
|
||||
public static extern string CoreSession_hangupCause(HandleRef jarg1);
|
||||
|
||||
[DllImport("mod_managed", EntryPoint="CSharp_CoreSession_RecordFile")]
|
||||
public static extern int CoreSession_RecordFile(HandleRef jarg1, string jarg2, int jarg3, int jarg4, int jarg5);
|
||||
|
||||
@@ -16167,7 +16221,8 @@ namespace FreeSWITCH.Native {
|
||||
|
||||
[System.Flags] public enum switch_application_flag_enum_t {
|
||||
SAF_NONE = 0,
|
||||
SAF_SUPPORT_NOMEDIA = (1 << 0)
|
||||
SAF_SUPPORT_NOMEDIA = (1 << 0),
|
||||
SAF_ROUTING_EXEC = (1 << 1)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -20627,6 +20682,16 @@ public class switch_event : IDisposable {
|
||||
}
|
||||
}
|
||||
|
||||
public int flags {
|
||||
set {
|
||||
freeswitchPINVOKE.switch_event_flags_set(swigCPtr, value);
|
||||
}
|
||||
get {
|
||||
int ret = freeswitchPINVOKE.switch_event_flags_get(swigCPtr);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
public switch_event() : this(freeswitchPINVOKE.new_switch_event(), true) {
|
||||
}
|
||||
|
||||
@@ -20643,6 +20708,21 @@ public class switch_event : IDisposable {
|
||||
|
||||
namespace FreeSWITCH.Native {
|
||||
|
||||
public enum switch_event_flag_t {
|
||||
EF_UNIQ_HEADERS = (1 << 0)
|
||||
}
|
||||
|
||||
}
|
||||
/* ----------------------------------------------------------------------------
|
||||
* 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;
|
||||
|
||||
@@ -21257,6 +21337,26 @@ public class switch_file_handle : IDisposable {
|
||||
}
|
||||
}
|
||||
|
||||
public string file_path {
|
||||
set {
|
||||
freeswitchPINVOKE.switch_file_handle_file_path_set(swigCPtr, value);
|
||||
}
|
||||
get {
|
||||
string ret = freeswitchPINVOKE.switch_file_handle_file_path_get(swigCPtr);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
public string spool_path {
|
||||
set {
|
||||
freeswitchPINVOKE.switch_file_handle_spool_path_set(swigCPtr, value);
|
||||
}
|
||||
get {
|
||||
string ret = freeswitchPINVOKE.switch_file_handle_spool_path_get(swigCPtr);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
public switch_file_handle() : this(freeswitchPINVOKE.new_switch_file_handle(), true) {
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user