ext/cproton/cproton.c in qpid_proton-0.24.0 vs ext/cproton/cproton.c in qpid_proton-0.25.0

- old
+ new

@@ -1858,31 +1858,29 @@ #define SWIGTYPE_p_pn_ssl_hash_alg swig_types[55] #define SWIGTYPE_p_pn_ssl_mode_t swig_types[56] #define SWIGTYPE_p_pn_ssl_resume_status_t swig_types[57] #define SWIGTYPE_p_pn_ssl_t swig_types[58] #define SWIGTYPE_p_pn_ssl_verify_mode_t swig_types[59] -#define SWIGTYPE_p_pn_status_t swig_types[60] -#define SWIGTYPE_p_pn_string_t swig_types[61] -#define SWIGTYPE_p_pn_subscription_t swig_types[62] -#define SWIGTYPE_p_pn_task_t swig_types[63] -#define SWIGTYPE_p_pn_terminus_t swig_types[64] -#define SWIGTYPE_p_pn_terminus_type_t swig_types[65] -#define SWIGTYPE_p_pn_timer_t swig_types[66] -#define SWIGTYPE_p_pn_transport_t swig_types[67] -#define SWIGTYPE_p_pn_type_t swig_types[68] -#define SWIGTYPE_p_pn_url_t swig_types[69] -#define SWIGTYPE_p_pn_uuid_t swig_types[70] -#define SWIGTYPE_p_short swig_types[71] -#define SWIGTYPE_p_signed_char swig_types[72] -#define SWIGTYPE_p_unsigned_char swig_types[73] -#define SWIGTYPE_p_unsigned_int swig_types[74] -#define SWIGTYPE_p_unsigned_long swig_types[75] -#define SWIGTYPE_p_unsigned_long_long swig_types[76] -#define SWIGTYPE_p_unsigned_short swig_types[77] -#define SWIGTYPE_p_void swig_types[78] -static swig_type_info *swig_types[80]; -static swig_module_info swig_module = {swig_types, 79, 0, 0, 0, 0}; +#define SWIGTYPE_p_pn_string_t swig_types[60] +#define SWIGTYPE_p_pn_task_t swig_types[61] +#define SWIGTYPE_p_pn_terminus_t swig_types[62] +#define SWIGTYPE_p_pn_terminus_type_t swig_types[63] +#define SWIGTYPE_p_pn_timer_t swig_types[64] +#define SWIGTYPE_p_pn_transport_t swig_types[65] +#define SWIGTYPE_p_pn_type_t swig_types[66] +#define SWIGTYPE_p_pn_url_t swig_types[67] +#define SWIGTYPE_p_pn_uuid_t swig_types[68] +#define SWIGTYPE_p_short swig_types[69] +#define SWIGTYPE_p_signed_char swig_types[70] +#define SWIGTYPE_p_unsigned_char swig_types[71] +#define SWIGTYPE_p_unsigned_int swig_types[72] +#define SWIGTYPE_p_unsigned_long swig_types[73] +#define SWIGTYPE_p_unsigned_long_long swig_types[74] +#define SWIGTYPE_p_unsigned_short swig_types[75] +#define SWIGTYPE_p_void swig_types[76] +static swig_type_info *swig_types[78]; +static swig_module_info swig_module = {swig_types, 77, 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) /* -------- TYPES TABLE (END) -------- */ @@ -1901,10 +1899,12 @@ #define SWIG_as_voidptr(a) (void *)((const void *)(a)) #define SWIG_as_voidptrptr(a) ((void)SWIG_as_voidptr(*a),(void**)(a)) +#define PN_USE_DEPRECATED_API 1 + #include <proton/connection_driver.h> #include <proton/engine.h> #include <proton/handlers.h> #include <proton/message.h> #include <proton/messenger.h> @@ -14567,11 +14567,11 @@ } arg1 = (pn_message_t *)(argp1); SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); result = (pn_sequence_t)pn_message_get_group_sequence(arg1); - vresult = SWIG_From_long((long)(result)); + vresult = SWIG_From_unsigned_SS_long((unsigned long)(result)); return vresult; fail: return Qnil; } @@ -14580,11 +14580,11 @@ _wrap_pn_message_set_group_sequence(int argc, VALUE *argv, VALUE self) { pn_message_t *arg1 = (pn_message_t *) 0 ; pn_sequence_t arg2 ; void *argp1 = 0 ; int res1 = 0 ; - long val2 ; + unsigned long val2 ; int ecode2 = 0 ; int result; VALUE vresult = Qnil; if ((argc < 2) || (argc > 2)) { @@ -14593,11 +14593,11 @@ res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_message_t, 0 | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_message_t *","pn_message_set_group_sequence", 1, argv[0] )); } arg1 = (pn_message_t *)(argp1); - ecode2 = SWIG_AsVal_long(argv[1], &val2); + ecode2 = SWIG_AsVal_unsigned_SS_long(argv[1], &val2); if (!SWIG_IsOK(ecode2)) { SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "pn_sequence_t","pn_message_set_group_sequence", 2, argv[1] )); } arg2 = (pn_sequence_t)(val2); SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); @@ -15183,1781 +15183,10 @@ return Qnil; } SWIGINTERN VALUE -_wrap_pn_messenger(int argc, VALUE *argv, VALUE self) { - char *arg1 = (char *) 0 ; - int res1 ; - char *buf1 = 0 ; - int alloc1 = 0 ; - pn_messenger_t *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_AsCharPtrAndSize(argv[0], &buf1, NULL, &alloc1); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "char const *","pn_messenger", 1, argv[0] )); - } - arg1 = (char *)(buf1); - result = (pn_messenger_t *)pn_messenger((char const *)arg1); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - return vresult; -fail: - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_name(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_name", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); - - result = (char *)pn_messenger_name(arg1); - SWIG_contract_assert((result!=NULL), "Contract violation: ensure: (result!=NULL)"); - - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_certificate(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_certificate", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_messenger_set_certificate", 2, argv[1] )); - } - arg2 = (char *)(buf2); - result = (int)pn_messenger_set_certificate(arg1,(char const *)arg2); - vresult = SWIG_From_int((int)(result)); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return vresult; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_get_certificate(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_get_certificate", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (char *)pn_messenger_get_certificate(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_private_key(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_private_key", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_messenger_set_private_key", 2, argv[1] )); - } - arg2 = (char *)(buf2); - result = (int)pn_messenger_set_private_key(arg1,(char const *)arg2); - vresult = SWIG_From_int((int)(result)); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return vresult; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_get_private_key(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_get_private_key", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (char *)pn_messenger_get_private_key(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_password(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_password", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_messenger_set_password", 2, argv[1] )); - } - arg2 = (char *)(buf2); - result = (int)pn_messenger_set_password(arg1,(char const *)arg2); - vresult = SWIG_From_int((int)(result)); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return vresult; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_get_password(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_get_password", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (char *)pn_messenger_get_password(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_trusted_certificates(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_trusted_certificates", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_messenger_set_trusted_certificates", 2, argv[1] )); - } - arg2 = (char *)(buf2); - result = (int)pn_messenger_set_trusted_certificates(arg1,(char const *)arg2); - vresult = SWIG_From_int((int)(result)); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return vresult; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_get_trusted_certificates(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_get_trusted_certificates", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (char *)pn_messenger_get_trusted_certificates(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_timeout(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - int arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - int val2 ; - int ecode2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_timeout", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_int(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int","pn_messenger_set_timeout", 2, argv[1] )); - } - arg2 = (int)(val2); - SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); - - result = (int)pn_messenger_set_timeout(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_get_timeout(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_get_timeout", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); - - result = (int)pn_messenger_get_timeout(arg1); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_is_blocking(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - bool result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_is_blocking", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (bool)pn_messenger_is_blocking(arg1); - vresult = SWIG_From_bool((bool)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_blocking(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - bool arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - bool val2 ; - int ecode2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_blocking", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_bool(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "bool","pn_messenger_set_blocking", 2, argv[1] )); - } - arg2 = (bool)(val2); - result = (int)pn_messenger_set_blocking(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_is_passive(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - bool result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_is_passive", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (bool)pn_messenger_is_passive(arg1); - vresult = SWIG_From_bool((bool)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_passive(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - bool arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - bool val2 ; - int ecode2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_passive", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_bool(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "bool","pn_messenger_set_passive", 2, argv[1] )); - } - arg2 = (bool)(val2); - result = (int)pn_messenger_set_passive(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_free(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_free", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); - - pn_messenger_free(arg1); - return Qnil; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_errno(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_errno", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); - - result = (int)pn_messenger_errno(arg1); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_error(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - pn_error_t *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_error", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); - - result = (pn_error_t *)pn_messenger_error(arg1); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_error_t, 0 | 0 ); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_get_outgoing_window(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_get_outgoing_window", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (int)pn_messenger_get_outgoing_window(arg1); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_outgoing_window(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - int arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - int val2 ; - int ecode2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_outgoing_window", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_int(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int","pn_messenger_set_outgoing_window", 2, argv[1] )); - } - arg2 = (int)(val2); - result = (int)pn_messenger_set_outgoing_window(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_get_incoming_window(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_get_incoming_window", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (int)pn_messenger_get_incoming_window(arg1); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_incoming_window(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - int arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - int val2 ; - int ecode2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_incoming_window", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_int(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int","pn_messenger_set_incoming_window", 2, argv[1] )); - } - arg2 = (int)(val2); - result = (int)pn_messenger_set_incoming_window(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_start(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_start", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); - - result = (int)pn_messenger_start(arg1); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_stop(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_stop", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); - - result = (int)pn_messenger_stop(arg1); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_stopped(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - bool result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_stopped", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (bool)pn_messenger_stopped(arg1); - vresult = SWIG_From_bool((bool)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_subscribe(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - pn_subscription_t *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_subscribe", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_messenger_subscribe", 2, argv[1] )); - } - arg2 = (char *)(buf2); - SWIG_contract_assert((arg1!=NULL)&&(arg2!=NULL), "Contract violation: require: (arg1!=NULL)&&(arg2!=NULL)"); - - result = (pn_subscription_t *)pn_messenger_subscribe(arg1,(char const *)arg2); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_subscription_t, 0 | 0 ); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return vresult; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_subscribe_ttl(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - char *arg2 = (char *) 0 ; - pn_seconds_t arg3 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - unsigned long val3 ; - int ecode3 = 0 ; - pn_subscription_t *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 3) || (argc > 3)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_subscribe_ttl", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_messenger_subscribe_ttl", 2, argv[1] )); - } - arg2 = (char *)(buf2); - ecode3 = SWIG_AsVal_unsigned_SS_long(argv[2], &val3); - if (!SWIG_IsOK(ecode3)) { - SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "pn_seconds_t","pn_messenger_subscribe_ttl", 3, argv[2] )); - } - arg3 = (pn_seconds_t)(val3); - result = (pn_subscription_t *)pn_messenger_subscribe_ttl(arg1,(char const *)arg2,arg3); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_subscription_t, 0 | 0 ); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return vresult; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_get_link(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - char *arg2 = (char *) 0 ; - bool arg3 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - bool val3 ; - int ecode3 = 0 ; - pn_link_t *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 3) || (argc > 3)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_get_link", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_messenger_get_link", 2, argv[1] )); - } - arg2 = (char *)(buf2); - ecode3 = SWIG_AsVal_bool(argv[2], &val3); - if (!SWIG_IsOK(ecode3)) { - SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "bool","pn_messenger_get_link", 3, argv[2] )); - } - arg3 = (bool)(val3); - result = (pn_link_t *)pn_messenger_get_link(arg1,(char const *)arg2,arg3); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_link_t, 0 | 0 ); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return vresult; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_subscription_get_context(int argc, VALUE *argv, VALUE self) { - pn_subscription_t *arg1 = (pn_subscription_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - void *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_subscription_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_subscription_t *","pn_subscription_get_context", 1, argv[0] )); - } - arg1 = (pn_subscription_t *)(argp1); - result = (void *)pn_subscription_get_context(arg1); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_void, 0 | 0 ); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_subscription_set_context(int argc, VALUE *argv, VALUE self) { - pn_subscription_t *arg1 = (pn_subscription_t *) 0 ; - void *arg2 = (void *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_subscription_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_subscription_t *","pn_subscription_set_context", 1, argv[0] )); - } - arg1 = (pn_subscription_t *)(argp1); - res2 = SWIG_ConvertPtr(argv[1],SWIG_as_voidptrptr(&arg2), 0, 0); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "void *","pn_subscription_set_context", 2, argv[1] )); - } - pn_subscription_set_context(arg1,arg2); - return Qnil; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_subscription_address(int argc, VALUE *argv, VALUE self) { - pn_subscription_t *arg1 = (pn_subscription_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_subscription_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_subscription_t *","pn_subscription_address", 1, argv[0] )); - } - arg1 = (pn_subscription_t *)(argp1); - result = (char *)pn_subscription_address(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_put(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_message_t *arg2 = (pn_message_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - void *argp2 = 0 ; - int res2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_put", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_pn_message_t, 0 | 0 ); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "pn_message_t *","pn_messenger_put", 2, argv[1] )); - } - arg2 = (pn_message_t *)(argp2); - SWIG_contract_assert((arg1!=NULL)&&(arg2!=NULL), "Contract violation: require: (arg1!=NULL)&&(arg2!=NULL)"); - - result = (int)pn_messenger_put(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_status(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_tracker_t arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - long long val2 ; - int ecode2 = 0 ; - pn_status_t result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_status", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_long_SS_long(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "pn_tracker_t","pn_messenger_status", 2, argv[1] )); - } - arg2 = (pn_tracker_t)(val2); - result = (pn_status_t)pn_messenger_status(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_delivery(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_tracker_t arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - long long val2 ; - int ecode2 = 0 ; - pn_delivery_t *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_delivery", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_long_SS_long(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "pn_tracker_t","pn_messenger_delivery", 2, argv[1] )); - } - arg2 = (pn_tracker_t)(val2); - result = (pn_delivery_t *)pn_messenger_delivery(arg1,arg2); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_delivery_t, 0 | 0 ); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_buffered(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_tracker_t arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - long long val2 ; - int ecode2 = 0 ; - bool result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_buffered", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_long_SS_long(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "pn_tracker_t","pn_messenger_buffered", 2, argv[1] )); - } - arg2 = (pn_tracker_t)(val2); - result = (bool)pn_messenger_buffered(arg1,arg2); - vresult = SWIG_From_bool((bool)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_settle(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_tracker_t arg2 ; - int arg3 ; - void *argp1 = 0 ; - int res1 = 0 ; - long long val2 ; - int ecode2 = 0 ; - int val3 ; - int ecode3 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 3) || (argc > 3)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_settle", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_long_SS_long(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "pn_tracker_t","pn_messenger_settle", 2, argv[1] )); - } - arg2 = (pn_tracker_t)(val2); - ecode3 = SWIG_AsVal_int(argv[2], &val3); - if (!SWIG_IsOK(ecode3)) { - SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "int","pn_messenger_settle", 3, argv[2] )); - } - arg3 = (int)(val3); - result = (int)pn_messenger_settle(arg1,arg2,arg3); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_outgoing_tracker(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - pn_tracker_t result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_outgoing_tracker", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (pn_tracker_t)pn_messenger_outgoing_tracker(arg1); - vresult = SWIG_From_long_SS_long((long long)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_interrupt(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_interrupt", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (int)pn_messenger_interrupt(arg1); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_receiving(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_receiving", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (int)pn_messenger_receiving(arg1); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_get(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_message_t *arg2 = (pn_message_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - void *argp2 = 0 ; - int res2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_get", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_pn_message_t, 0 | 0 ); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "pn_message_t *","pn_messenger_get", 2, argv[1] )); - } - arg2 = (pn_message_t *)(argp2); - SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); - - result = (int)pn_messenger_get(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_incoming_tracker(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - pn_tracker_t result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_incoming_tracker", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (pn_tracker_t)pn_messenger_incoming_tracker(arg1); - vresult = SWIG_From_long_SS_long((long long)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_incoming_subscription(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - pn_subscription_t *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_incoming_subscription", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (pn_subscription_t *)pn_messenger_incoming_subscription(arg1); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_subscription_t, 0 | 0 ); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_accept(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_tracker_t arg2 ; - int arg3 ; - void *argp1 = 0 ; - int res1 = 0 ; - long long val2 ; - int ecode2 = 0 ; - int val3 ; - int ecode3 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 3) || (argc > 3)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_accept", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_long_SS_long(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "pn_tracker_t","pn_messenger_accept", 2, argv[1] )); - } - arg2 = (pn_tracker_t)(val2); - ecode3 = SWIG_AsVal_int(argv[2], &val3); - if (!SWIG_IsOK(ecode3)) { - SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "int","pn_messenger_accept", 3, argv[2] )); - } - arg3 = (int)(val3); - result = (int)pn_messenger_accept(arg1,arg2,arg3); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_reject(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_tracker_t arg2 ; - int arg3 ; - void *argp1 = 0 ; - int res1 = 0 ; - long long val2 ; - int ecode2 = 0 ; - int val3 ; - int ecode3 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 3) || (argc > 3)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_reject", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_long_SS_long(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "pn_tracker_t","pn_messenger_reject", 2, argv[1] )); - } - arg2 = (pn_tracker_t)(val2); - ecode3 = SWIG_AsVal_int(argv[2], &val3); - if (!SWIG_IsOK(ecode3)) { - SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "int","pn_messenger_reject", 3, argv[2] )); - } - arg3 = (int)(val3); - result = (int)pn_messenger_reject(arg1,arg2,arg3); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_tracker_link(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_tracker_t arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - long long val2 ; - int ecode2 = 0 ; - pn_link_t *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_tracker_link", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_long_SS_long(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "pn_tracker_t","pn_messenger_tracker_link", 2, argv[1] )); - } - arg2 = (pn_tracker_t)(val2); - result = (pn_link_t *)pn_messenger_tracker_link(arg1,arg2); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_link_t, 0 | 0 ); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_outgoing(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_outgoing", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); - - result = (int)pn_messenger_outgoing(arg1); - SWIG_contract_assert((result>=0), "Contract violation: ensure: (result>=0)"); - - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_incoming(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_incoming", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - SWIG_contract_assert((arg1!=NULL), "Contract violation: require: (arg1!=NULL)"); - - result = (int)pn_messenger_incoming(arg1); - SWIG_contract_assert((result>=0), "Contract violation: ensure: (result>=0)"); - - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_route(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - char *arg2 = (char *) 0 ; - char *arg3 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - int res3 ; - char *buf3 = 0 ; - int alloc3 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 3) || (argc > 3)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_route", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_messenger_route", 2, argv[1] )); - } - arg2 = (char *)(buf2); - res3 = SWIG_AsCharPtrAndSize(argv[2], &buf3, NULL, &alloc3); - if (!SWIG_IsOK(res3)) { - SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "char const *","pn_messenger_route", 3, argv[2] )); - } - arg3 = (char *)(buf3); - result = (int)pn_messenger_route(arg1,(char const *)arg2,(char const *)arg3); - vresult = SWIG_From_int((int)(result)); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - if (alloc3 == SWIG_NEWOBJ) free((char*)buf3); - return vresult; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - if (alloc3 == SWIG_NEWOBJ) free((char*)buf3); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_rewrite(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - char *arg2 = (char *) 0 ; - char *arg3 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - int res3 ; - char *buf3 = 0 ; - int alloc3 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 3) || (argc > 3)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_rewrite", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_messenger_rewrite", 2, argv[1] )); - } - arg2 = (char *)(buf2); - res3 = SWIG_AsCharPtrAndSize(argv[2], &buf3, NULL, &alloc3); - if (!SWIG_IsOK(res3)) { - SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "char const *","pn_messenger_rewrite", 3, argv[2] )); - } - arg3 = (char *)(buf3); - result = (int)pn_messenger_rewrite(arg1,(char const *)arg2,(char const *)arg3); - vresult = SWIG_From_int((int)(result)); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - if (alloc3 == SWIG_NEWOBJ) free((char*)buf3); - return vresult; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - if (alloc3 == SWIG_NEWOBJ) free((char*)buf3); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_selectable(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - pn_selectable_t *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_selectable", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (pn_selectable_t *)pn_messenger_selectable(arg1); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_selectable_t, 0 | 0 ); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_deadline(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - pn_timestamp_t result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_deadline", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (pn_timestamp_t)pn_messenger_deadline(arg1); - vresult = SWIG_From_long_SS_long((long long)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_flags(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - int arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - int val2 ; - int ecode2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_flags", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_int(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int","pn_messenger_set_flags", 2, argv[1] )); - } - arg2 = (int)(val2); - result = (int)pn_messenger_set_flags(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_get_flags(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_get_flags", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - result = (int)pn_messenger_get_flags(arg1); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_snd_settle_mode(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_snd_settle_mode_t arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - int val2 ; - int ecode2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_snd_settle_mode", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_int(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "pn_snd_settle_mode_t","pn_messenger_set_snd_settle_mode", 2, argv[1] )); - } - arg2 = (pn_snd_settle_mode_t)(val2); - result = (int)pn_messenger_set_snd_settle_mode(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_rcv_settle_mode(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_rcv_settle_mode_t arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - int val2 ; - int ecode2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_rcv_settle_mode", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_int(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "pn_rcv_settle_mode_t","pn_messenger_set_rcv_settle_mode", 2, argv[1] )); - } - arg2 = (pn_rcv_settle_mode_t)(val2); - result = (int)pn_messenger_set_rcv_settle_mode(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_tracer(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_tracer_t arg2 = (pn_tracer_t) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_tracer", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - { - int res = SWIG_ConvertFunctionPtr(argv[1], (void**)(&arg2), SWIGTYPE_p_f_p_struct_pn_transport_t_p_q_const__char__void); - if (!SWIG_IsOK(res)) { - SWIG_exception_fail(SWIG_ArgError(res), Ruby_Format_TypeError( "", "pn_tracer_t","pn_messenger_set_tracer", 2, argv[1] )); - } - } - pn_messenger_set_tracer(arg1,arg2); - return Qnil; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_get_remote_idle_timeout(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - pn_millis_t result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_get_remote_idle_timeout", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_messenger_get_remote_idle_timeout", 2, argv[1] )); - } - arg2 = (char *)(buf2); - result = (pn_millis_t)pn_messenger_get_remote_idle_timeout(arg1,(char const *)arg2); - vresult = SWIG_From_unsigned_SS_long((unsigned long)(result)); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return vresult; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_messenger_set_ssl_peer_authentication_mode(int argc, VALUE *argv, VALUE self) { - pn_messenger_t *arg1 = (pn_messenger_t *) 0 ; - pn_ssl_verify_mode_t arg2 ; - void *argp1 = 0 ; - int res1 = 0 ; - int val2 ; - int ecode2 = 0 ; - int result; - VALUE vresult = Qnil; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_messenger_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_messenger_t *","pn_messenger_set_ssl_peer_authentication_mode", 1, argv[0] )); - } - arg1 = (pn_messenger_t *)(argp1); - ecode2 = SWIG_AsVal_int(argv[1], &val2); - if (!SWIG_IsOK(ecode2)) { - SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "pn_ssl_verify_mode_t","pn_messenger_set_ssl_peer_authentication_mode", 2, argv[1] )); - } - arg2 = (pn_ssl_verify_mode_t)(val2); - result = (int)pn_messenger_set_ssl_peer_authentication_mode(arg1,arg2); - vresult = SWIG_From_int((int)(result)); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE _wrap_pn_selectables(int argc, VALUE *argv, VALUE self) { pn_selectables_t *result = 0 ; VALUE vresult = Qnil; if ((argc < 0) || (argc > 0)) { @@ -21232,455 +19461,10 @@ return Qnil; } SWIGINTERN VALUE -_wrap_pn_url(int argc, VALUE *argv, VALUE self) { - pn_url_t *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 0) || (argc > 0)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail; - } - result = (pn_url_t *)pn_url(); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_url_t, 0 | 0 ); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_parse(int argc, VALUE *argv, VALUE self) { - char *arg1 = (char *) 0 ; - int res1 ; - char *buf1 = 0 ; - int alloc1 = 0 ; - pn_url_t *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_AsCharPtrAndSize(argv[0], &buf1, NULL, &alloc1); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "char const *","pn_url_parse", 1, argv[0] )); - } - arg1 = (char *)(buf1); - result = (pn_url_t *)pn_url_parse((char const *)arg1); - vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - return vresult; -fail: - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_free(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_free", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - pn_url_free(arg1); - return Qnil; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_clear(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_clear", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - pn_url_clear(arg1); - return Qnil; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_str(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_str", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - result = (char *)pn_url_str(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_get_scheme(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_scheme", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - result = (char *)pn_url_get_scheme(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_get_username(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_username", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - result = (char *)pn_url_get_username(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_get_password(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_password", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - result = (char *)pn_url_get_password(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_get_host(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_host", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - result = (char *)pn_url_get_host(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_get_port(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_port", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - result = (char *)pn_url_get_port(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_get_path(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - char *result = 0 ; - VALUE vresult = Qnil; - - if ((argc < 1) || (argc > 1)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_path", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - result = (char *)pn_url_get_path(arg1); - vresult = SWIG_FromCharPtr((const char *)result); - return vresult; -fail: - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_set_scheme(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_scheme", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_scheme", 2, argv[1] )); - } - arg2 = (char *)(buf2); - pn_url_set_scheme(arg1,(char const *)arg2); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_set_username(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_username", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_username", 2, argv[1] )); - } - arg2 = (char *)(buf2); - pn_url_set_username(arg1,(char const *)arg2); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_set_password(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_password", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_password", 2, argv[1] )); - } - arg2 = (char *)(buf2); - pn_url_set_password(arg1,(char const *)arg2); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_set_host(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_host", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_host", 2, argv[1] )); - } - arg2 = (char *)(buf2); - pn_url_set_host(arg1,(char const *)arg2); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_set_port(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_port", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_port", 2, argv[1] )); - } - arg2 = (char *)(buf2); - pn_url_set_port(arg1,(char const *)arg2); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE -_wrap_pn_url_set_path(int argc, VALUE *argv, VALUE self) { - pn_url_t *arg1 = (pn_url_t *) 0 ; - char *arg2 = (char *) 0 ; - void *argp1 = 0 ; - int res1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - - if ((argc < 2) || (argc > 2)) { - rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; - } - res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_path", 1, argv[0] )); - } - arg1 = (pn_url_t *)(argp1); - res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_path", 2, argv[1] )); - } - arg2 = (char *)(buf2); - pn_url_set_path(arg1,(char const *)arg2); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -fail: - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - return Qnil; -} - - -SWIGINTERN VALUE _wrap_pn_handler(int argc, VALUE *argv, VALUE self) { void (*arg1)(pn_handler_t *,pn_event_t *,pn_event_type_t) = (void (*)(pn_handler_t *,pn_event_t *,pn_event_type_t)) 0 ; pn_handler_t *result = 0 ; VALUE vresult = Qnil; @@ -23142,11 +20926,456 @@ fail: return Qnil; } +SWIGINTERN VALUE +_wrap_pn_url(int argc, VALUE *argv, VALUE self) { + pn_url_t *result = 0 ; + VALUE vresult = Qnil; + + if ((argc < 0) || (argc > 0)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail; + } + result = (pn_url_t *)pn_url(); + vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_url_t, 0 | 0 ); + return vresult; +fail: + return Qnil; +} + +SWIGINTERN VALUE +_wrap_pn_url_parse(int argc, VALUE *argv, VALUE self) { + char *arg1 = (char *) 0 ; + int res1 ; + char *buf1 = 0 ; + int alloc1 = 0 ; + pn_url_t *result = 0 ; + VALUE vresult = Qnil; + + if ((argc < 1) || (argc > 1)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; + } + res1 = SWIG_AsCharPtrAndSize(argv[0], &buf1, NULL, &alloc1); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "char const *","pn_url_parse", 1, argv[0] )); + } + arg1 = (char *)(buf1); + result = (pn_url_t *)pn_url_parse((char const *)arg1); + vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + return vresult; +fail: + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_free(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + + if ((argc < 1) || (argc > 1)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_free", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + pn_url_free(arg1); + return Qnil; +fail: + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_clear(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + + if ((argc < 1) || (argc > 1)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_clear", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + pn_url_clear(arg1); + return Qnil; +fail: + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_str(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + char *result = 0 ; + VALUE vresult = Qnil; + + if ((argc < 1) || (argc > 1)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_str", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + result = (char *)pn_url_str(arg1); + vresult = SWIG_FromCharPtr((const char *)result); + return vresult; +fail: + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_get_scheme(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + char *result = 0 ; + VALUE vresult = Qnil; + + if ((argc < 1) || (argc > 1)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_scheme", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + result = (char *)pn_url_get_scheme(arg1); + vresult = SWIG_FromCharPtr((const char *)result); + return vresult; +fail: + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_get_username(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + char *result = 0 ; + VALUE vresult = Qnil; + + if ((argc < 1) || (argc > 1)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_username", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + result = (char *)pn_url_get_username(arg1); + vresult = SWIG_FromCharPtr((const char *)result); + return vresult; +fail: + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_get_password(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + char *result = 0 ; + VALUE vresult = Qnil; + + if ((argc < 1) || (argc > 1)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_password", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + result = (char *)pn_url_get_password(arg1); + vresult = SWIG_FromCharPtr((const char *)result); + return vresult; +fail: + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_get_host(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + char *result = 0 ; + VALUE vresult = Qnil; + + if ((argc < 1) || (argc > 1)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_host", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + result = (char *)pn_url_get_host(arg1); + vresult = SWIG_FromCharPtr((const char *)result); + return vresult; +fail: + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_get_port(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + char *result = 0 ; + VALUE vresult = Qnil; + + if ((argc < 1) || (argc > 1)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_port", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + result = (char *)pn_url_get_port(arg1); + vresult = SWIG_FromCharPtr((const char *)result); + return vresult; +fail: + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_get_path(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + char *result = 0 ; + VALUE vresult = Qnil; + + if ((argc < 1) || (argc > 1)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_get_path", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + result = (char *)pn_url_get_path(arg1); + vresult = SWIG_FromCharPtr((const char *)result); + return vresult; +fail: + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_set_scheme(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + char *arg2 = (char *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + int res2 ; + char *buf2 = 0 ; + int alloc2 = 0 ; + + if ((argc < 2) || (argc > 2)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_scheme", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); + if (!SWIG_IsOK(res2)) { + SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_scheme", 2, argv[1] )); + } + arg2 = (char *)(buf2); + pn_url_set_scheme(arg1,(char const *)arg2); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +fail: + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_set_username(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + char *arg2 = (char *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + int res2 ; + char *buf2 = 0 ; + int alloc2 = 0 ; + + if ((argc < 2) || (argc > 2)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_username", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); + if (!SWIG_IsOK(res2)) { + SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_username", 2, argv[1] )); + } + arg2 = (char *)(buf2); + pn_url_set_username(arg1,(char const *)arg2); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +fail: + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_set_password(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + char *arg2 = (char *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + int res2 ; + char *buf2 = 0 ; + int alloc2 = 0 ; + + if ((argc < 2) || (argc > 2)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_password", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); + if (!SWIG_IsOK(res2)) { + SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_password", 2, argv[1] )); + } + arg2 = (char *)(buf2); + pn_url_set_password(arg1,(char const *)arg2); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +fail: + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_set_host(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + char *arg2 = (char *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + int res2 ; + char *buf2 = 0 ; + int alloc2 = 0 ; + + if ((argc < 2) || (argc > 2)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_host", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); + if (!SWIG_IsOK(res2)) { + SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_host", 2, argv[1] )); + } + arg2 = (char *)(buf2); + pn_url_set_host(arg1,(char const *)arg2); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +fail: + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_set_port(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + char *arg2 = (char *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + int res2 ; + char *buf2 = 0 ; + int alloc2 = 0 ; + + if ((argc < 2) || (argc > 2)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_port", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); + if (!SWIG_IsOK(res2)) { + SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_port", 2, argv[1] )); + } + arg2 = (char *)(buf2); + pn_url_set_port(arg1,(char const *)arg2); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +fail: + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +} + + +SWIGINTERN VALUE +_wrap_pn_url_set_path(int argc, VALUE *argv, VALUE self) { + pn_url_t *arg1 = (pn_url_t *) 0 ; + char *arg2 = (char *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + int res2 ; + char *buf2 = 0 ; + int alloc2 = 0 ; + + if ((argc < 2) || (argc > 2)) { + rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail; + } + res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_pn_url_t, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "pn_url_t *","pn_url_set_path", 1, argv[0] )); + } + arg1 = (pn_url_t *)(argp1); + res2 = SWIG_AsCharPtrAndSize(argv[1], &buf2, NULL, &alloc2); + if (!SWIG_IsOK(res2)) { + SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","pn_url_set_path", 2, argv[1] )); + } + arg2 = (char *)(buf2); + pn_url_set_path(arg1,(char const *)arg2); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +fail: + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + return Qnil; +} + + + /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */ static swig_type_info _swigt__p_Pn_rbkey_t = {"_p_Pn_rbkey_t", "Pn_rbkey_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_Pni_rbhandler_t = {"_p_Pni_rbhandler_t", "Pni_rbhandler_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0}; @@ -23155,12 +21384,12 @@ static swig_type_info _swigt__p_f_p_struct_pn_selectable_t__void = {"_p_f_p_struct_pn_selectable_t__void", "void (*)(struct pn_selectable_t *)|void (*)(pn_selectable_t *)", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_f_p_struct_pn_transport_t_p_q_const__char__void = {"_p_f_p_struct_pn_transport_t_p_q_const__char__void", "void (*)(struct pn_transport_t *,char const *)|pn_tracer_t", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_f_p_void__p_void = {"_p_f_p_void__p_void", "void *(*)(void *)|pn_iterator_next_t", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_int = {"_p_int", "int *|ssize_t *|pn_state_t *|pn_trace_t *|pn_socket_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_intptr_t = {"_p_intptr_t", "intptr_t *|pn_shandle_t *", 0, 0, (void*)0, 0}; -static swig_type_info _swigt__p_long = {"_p_long", "int32_t *|long *|pn_sequence_t *", 0, 0, (void*)0, 0}; -static swig_type_info _swigt__p_long_long = {"_p_long_long", "int64_t *|long long *|pn_tracker_t *|pn_timestamp_t *", 0, 0, (void*)0, 0}; +static swig_type_info _swigt__p_long = {"_p_long", "int32_t *|long *", 0, 0, (void*)0, 0}; +static swig_type_info _swigt__p_long_long = {"_p_long_long", "int64_t *|long long *|pn_timestamp_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_p_char = {"_p_p_char", "char **", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_p_pn_connection_driver_t = {"_p_p_pn_connection_driver_t", "struct pn_connection_driver_t **|pn_connection_driver_t **", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_acceptor_t = {"_p_pn_acceptor_t", "struct pn_acceptor_t *|pn_acceptor_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_atom_t = {"_p_pn_atom_t", "pn_atom_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_bytes_t = {"_p_pn_bytes_t", "struct pn_bytes_t *|pn_bytes_t *", 0, 0, (void*)0, 0}; @@ -23187,11 +21416,11 @@ static swig_type_info _swigt__p_pn_link_t = {"_p_pn_link_t", "struct pn_link_t *|pn_link_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_list_t = {"_p_pn_list_t", "struct pn_list_t *|pn_list_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_listener_t = {"_p_pn_listener_t", "struct pn_listener_t *|pn_listener_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_map_t = {"_p_pn_map_t", "struct pn_map_t *|pn_map_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_message_t = {"_p_pn_message_t", "struct pn_message_t *|pn_message_t *", 0, 0, (void*)0, 0}; -static swig_type_info _swigt__p_pn_messenger_t = {"_p_pn_messenger_t", "struct pn_messenger_t *|pn_messenger_t *", 0, 0, (void*)0, 0}; +static swig_type_info _swigt__p_pn_messenger_t = {"_p_pn_messenger_t", "pn_messenger_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_proactor_t = {"_p_pn_proactor_t", "struct pn_proactor_t *|pn_proactor_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_rcv_settle_mode_t = {"_p_pn_rcv_settle_mode_t", "enum pn_rcv_settle_mode_t *|pn_rcv_settle_mode_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_reactor_t = {"_p_pn_reactor_t", "struct pn_reactor_t *|pn_reactor_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_record_t = {"_p_pn_record_t", "struct pn_record_t *|pn_record_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_rwbytes_t = {"_p_pn_rwbytes_t", "struct pn_rwbytes_t *|pn_rwbytes_t *", 0, 0, (void*)0, 0}; @@ -23205,13 +21434,11 @@ static swig_type_info _swigt__p_pn_ssl_hash_alg = {"_p_pn_ssl_hash_alg", "enum pn_ssl_hash_alg *|pn_ssl_hash_alg *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_ssl_mode_t = {"_p_pn_ssl_mode_t", "enum pn_ssl_mode_t *|pn_ssl_mode_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_ssl_resume_status_t = {"_p_pn_ssl_resume_status_t", "enum pn_ssl_resume_status_t *|pn_ssl_resume_status_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_ssl_t = {"_p_pn_ssl_t", "struct pn_ssl_t *|pn_ssl_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_ssl_verify_mode_t = {"_p_pn_ssl_verify_mode_t", "enum pn_ssl_verify_mode_t *|pn_ssl_verify_mode_t *", 0, 0, (void*)0, 0}; -static swig_type_info _swigt__p_pn_status_t = {"_p_pn_status_t", "enum pn_status_t *|pn_status_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_string_t = {"_p_pn_string_t", "struct pn_string_t *|pn_string_t *", 0, 0, (void*)0, 0}; -static swig_type_info _swigt__p_pn_subscription_t = {"_p_pn_subscription_t", "struct pn_subscription_t *|pn_subscription_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_task_t = {"_p_pn_task_t", "struct pn_task_t *|pn_task_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_terminus_t = {"_p_pn_terminus_t", "struct pn_terminus_t *|pn_terminus_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_terminus_type_t = {"_p_pn_terminus_type_t", "enum pn_terminus_type_t *|pn_terminus_type_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_timer_t = {"_p_pn_timer_t", "struct pn_timer_t *|pn_timer_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_pn_transport_t = {"_p_pn_transport_t", "struct pn_transport_t *|pn_transport_t *", 0, 0, (void*)0, 0}; @@ -23220,11 +21447,11 @@ static swig_type_info _swigt__p_pn_uuid_t = {"_p_pn_uuid_t", "pn_uuid_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_short = {"_p_short", "short *|int16_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_signed_char = {"_p_signed_char", "signed char *|int8_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_unsigned_char = {"_p_unsigned_char", "unsigned char *|uint8_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_unsigned_int = {"_p_unsigned_int", "size_t *|unsigned int *", 0, 0, (void*)0, 0}; -static swig_type_info _swigt__p_unsigned_long = {"_p_unsigned_long", "pn_seconds_t *|pn_decimal32_t *|uint32_t *|unsigned long *|pn_millis_t *|pn_char_t *", 0, 0, (void*)0, 0}; +static swig_type_info _swigt__p_unsigned_long = {"_p_unsigned_long", "pn_seconds_t *|pn_decimal32_t *|uint32_t *|unsigned long *|pn_millis_t *|pn_char_t *|pn_sequence_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_unsigned_long_long = {"_p_unsigned_long_long", "uintptr_t *|pn_decimal64_t *|uint64_t *|unsigned long long *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_unsigned_short = {"_p_unsigned_short", "unsigned short *|uint16_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_void = {"_p_void", "void *", 0, 0, (void*)0, 0}; static swig_type_info *swig_type_initial[] = { @@ -23286,13 +21513,11 @@ &_swigt__p_pn_ssl_hash_alg, &_swigt__p_pn_ssl_mode_t, &_swigt__p_pn_ssl_resume_status_t, &_swigt__p_pn_ssl_t, &_swigt__p_pn_ssl_verify_mode_t, - &_swigt__p_pn_status_t, &_swigt__p_pn_string_t, - &_swigt__p_pn_subscription_t, &_swigt__p_pn_task_t, &_swigt__p_pn_terminus_t, &_swigt__p_pn_terminus_type_t, &_swigt__p_pn_timer_t, &_swigt__p_pn_transport_t, @@ -23367,13 +21592,11 @@ static swig_cast_info _swigc__p_pn_ssl_hash_alg[] = { {&_swigt__p_pn_ssl_hash_alg, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_pn_ssl_mode_t[] = { {&_swigt__p_pn_ssl_mode_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_pn_ssl_resume_status_t[] = { {&_swigt__p_pn_ssl_resume_status_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_pn_ssl_t[] = { {&_swigt__p_pn_ssl_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_pn_ssl_verify_mode_t[] = { {&_swigt__p_pn_ssl_verify_mode_t, 0, 0, 0},{0, 0, 0, 0}}; -static swig_cast_info _swigc__p_pn_status_t[] = { {&_swigt__p_pn_status_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_pn_string_t[] = { {&_swigt__p_pn_string_t, 0, 0, 0},{0, 0, 0, 0}}; -static swig_cast_info _swigc__p_pn_subscription_t[] = { {&_swigt__p_pn_subscription_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_pn_task_t[] = { {&_swigt__p_pn_task_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_pn_terminus_t[] = { {&_swigt__p_pn_terminus_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_pn_terminus_type_t[] = { {&_swigt__p_pn_terminus_type_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_pn_timer_t[] = { {&_swigt__p_pn_timer_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_pn_transport_t[] = { {&_swigt__p_pn_transport_t, 0, 0, 0},{0, 0, 0, 0}}; @@ -23448,13 +21671,11 @@ _swigc__p_pn_ssl_hash_alg, _swigc__p_pn_ssl_mode_t, _swigc__p_pn_ssl_resume_status_t, _swigc__p_pn_ssl_t, _swigc__p_pn_ssl_verify_mode_t, - _swigc__p_pn_status_t, _swigc__p_pn_string_t, - _swigc__p_pn_subscription_t, _swigc__p_pn_task_t, _swigc__p_pn_terminus_t, _swigc__p_pn_terminus_type_t, _swigc__p_pn_timer_t, _swigc__p_pn_transport_t, @@ -23773,11 +21994,11 @@ rb_define_module_function(mCproton, "pni_connection_driver_transport", _wrap_pni_connection_driver_transport, -1); rb_define_module_function(mCproton, "pni_connection_driver_read_copy", _wrap_pni_connection_driver_read_copy, -1); rb_define_module_function(mCproton, "pni_connection_driver", _wrap_pni_connection_driver, -1); rb_define_const(mCproton, "PROTON_IMPORT_EXPORT_H", SWIG_From_int((int)(1))); rb_define_const(mCproton, "PN_VERSION_MAJOR", SWIG_From_int((int)(0))); - rb_define_const(mCproton, "PN_VERSION_MINOR", SWIG_From_int((int)(24))); + rb_define_const(mCproton, "PN_VERSION_MINOR", SWIG_From_int((int)(25))); rb_define_const(mCproton, "PN_VERSION_POINT", SWIG_From_int((int)(0))); rb_define_const(mCproton, "PROTON_TYPES_H", SWIG_From_int((int)(1))); rb_define_const(mCproton, "PN_MILLIS_MAX", SWIG_From_unsigned_SS_int((unsigned int)((~0U)))); rb_define_module_function(mCproton, "pn_bytes", _wrap_pn_bytes, -1); rb_define_singleton_method(mCproton, "pn_bytes_null", _wrap_pn_bytes_null_get, 0); @@ -24304,81 +22525,10 @@ rb_define_module_function(mCproton, "pn_sasl_allowed_mechs", _wrap_pn_sasl_allowed_mechs, -1); rb_define_module_function(mCproton, "pn_sasl_set_allow_insecure_mechs", _wrap_pn_sasl_set_allow_insecure_mechs, -1); rb_define_module_function(mCproton, "pn_sasl_get_allow_insecure_mechs", _wrap_pn_sasl_get_allow_insecure_mechs, -1); rb_define_module_function(mCproton, "pn_sasl_config_name", _wrap_pn_sasl_config_name, -1); rb_define_module_function(mCproton, "pn_sasl_config_path", _wrap_pn_sasl_config_path, -1); - rb_define_const(mCproton, "PROTON_MESSENGER_H", SWIG_From_int((int)(1))); - rb_define_const(mCproton, "PN_STATUS_UNKNOWN", SWIG_From_int((int)(PN_STATUS_UNKNOWN))); - rb_define_const(mCproton, "PN_STATUS_PENDING", SWIG_From_int((int)(PN_STATUS_PENDING))); - rb_define_const(mCproton, "PN_STATUS_ACCEPTED", SWIG_From_int((int)(PN_STATUS_ACCEPTED))); - rb_define_const(mCproton, "PN_STATUS_REJECTED", SWIG_From_int((int)(PN_STATUS_REJECTED))); - rb_define_const(mCproton, "PN_STATUS_RELEASED", SWIG_From_int((int)(PN_STATUS_RELEASED))); - rb_define_const(mCproton, "PN_STATUS_MODIFIED", SWIG_From_int((int)(PN_STATUS_MODIFIED))); - rb_define_const(mCproton, "PN_STATUS_ABORTED", SWIG_From_int((int)(PN_STATUS_ABORTED))); - rb_define_const(mCproton, "PN_STATUS_SETTLED", SWIG_From_int((int)(PN_STATUS_SETTLED))); - rb_define_module_function(mCproton, "pn_messenger", _wrap_pn_messenger, -1); - rb_define_module_function(mCproton, "pn_messenger_name", _wrap_pn_messenger_name, -1); - rb_define_module_function(mCproton, "pn_messenger_set_certificate", _wrap_pn_messenger_set_certificate, -1); - rb_define_module_function(mCproton, "pn_messenger_get_certificate", _wrap_pn_messenger_get_certificate, -1); - rb_define_module_function(mCproton, "pn_messenger_set_private_key", _wrap_pn_messenger_set_private_key, -1); - rb_define_module_function(mCproton, "pn_messenger_get_private_key", _wrap_pn_messenger_get_private_key, -1); - rb_define_module_function(mCproton, "pn_messenger_set_password", _wrap_pn_messenger_set_password, -1); - rb_define_module_function(mCproton, "pn_messenger_get_password", _wrap_pn_messenger_get_password, -1); - rb_define_module_function(mCproton, "pn_messenger_set_trusted_certificates", _wrap_pn_messenger_set_trusted_certificates, -1); - rb_define_module_function(mCproton, "pn_messenger_get_trusted_certificates", _wrap_pn_messenger_get_trusted_certificates, -1); - rb_define_module_function(mCproton, "pn_messenger_set_timeout", _wrap_pn_messenger_set_timeout, -1); - rb_define_module_function(mCproton, "pn_messenger_get_timeout", _wrap_pn_messenger_get_timeout, -1); - rb_define_module_function(mCproton, "pn_messenger_is_blocking", _wrap_pn_messenger_is_blocking, -1); - rb_define_module_function(mCproton, "pn_messenger_set_blocking", _wrap_pn_messenger_set_blocking, -1); - rb_define_module_function(mCproton, "pn_messenger_is_passive", _wrap_pn_messenger_is_passive, -1); - rb_define_module_function(mCproton, "pn_messenger_set_passive", _wrap_pn_messenger_set_passive, -1); - rb_define_module_function(mCproton, "pn_messenger_free", _wrap_pn_messenger_free, -1); - rb_define_module_function(mCproton, "pn_messenger_errno", _wrap_pn_messenger_errno, -1); - rb_define_module_function(mCproton, "pn_messenger_error", _wrap_pn_messenger_error, -1); - rb_define_module_function(mCproton, "pn_messenger_get_outgoing_window", _wrap_pn_messenger_get_outgoing_window, -1); - rb_define_module_function(mCproton, "pn_messenger_set_outgoing_window", _wrap_pn_messenger_set_outgoing_window, -1); - rb_define_module_function(mCproton, "pn_messenger_get_incoming_window", _wrap_pn_messenger_get_incoming_window, -1); - rb_define_module_function(mCproton, "pn_messenger_set_incoming_window", _wrap_pn_messenger_set_incoming_window, -1); - rb_define_module_function(mCproton, "pn_messenger_start", _wrap_pn_messenger_start, -1); - rb_define_module_function(mCproton, "pn_messenger_stop", _wrap_pn_messenger_stop, -1); - rb_define_module_function(mCproton, "pn_messenger_stopped", _wrap_pn_messenger_stopped, -1); - rb_define_module_function(mCproton, "pn_messenger_subscribe", _wrap_pn_messenger_subscribe, -1); - rb_define_module_function(mCproton, "pn_messenger_subscribe_ttl", _wrap_pn_messenger_subscribe_ttl, -1); - rb_define_module_function(mCproton, "pn_messenger_get_link", _wrap_pn_messenger_get_link, -1); - rb_define_module_function(mCproton, "pn_subscription_get_context", _wrap_pn_subscription_get_context, -1); - rb_define_module_function(mCproton, "pn_subscription_set_context", _wrap_pn_subscription_set_context, -1); - rb_define_module_function(mCproton, "pn_subscription_address", _wrap_pn_subscription_address, -1); - rb_define_module_function(mCproton, "pn_messenger_put", _wrap_pn_messenger_put, -1); - rb_define_module_function(mCproton, "pn_messenger_status", _wrap_pn_messenger_status, -1); - rb_define_module_function(mCproton, "pn_messenger_delivery", _wrap_pn_messenger_delivery, -1); - rb_define_module_function(mCproton, "pn_messenger_buffered", _wrap_pn_messenger_buffered, -1); - rb_define_module_function(mCproton, "pn_messenger_settle", _wrap_pn_messenger_settle, -1); - rb_define_module_function(mCproton, "pn_messenger_outgoing_tracker", _wrap_pn_messenger_outgoing_tracker, -1); - rb_define_module_function(mCproton, "pn_messenger_interrupt", _wrap_pn_messenger_interrupt, -1); - rb_define_module_function(mCproton, "pn_messenger_receiving", _wrap_pn_messenger_receiving, -1); - rb_define_module_function(mCproton, "pn_messenger_get", _wrap_pn_messenger_get, -1); - rb_define_module_function(mCproton, "pn_messenger_incoming_tracker", _wrap_pn_messenger_incoming_tracker, -1); - rb_define_module_function(mCproton, "pn_messenger_incoming_subscription", _wrap_pn_messenger_incoming_subscription, -1); - rb_define_const(mCproton, "PN_CUMULATIVE", SWIG_From_int((int)((0x1)))); - rb_define_module_function(mCproton, "pn_messenger_accept", _wrap_pn_messenger_accept, -1); - rb_define_module_function(mCproton, "pn_messenger_reject", _wrap_pn_messenger_reject, -1); - rb_define_module_function(mCproton, "pn_messenger_tracker_link", _wrap_pn_messenger_tracker_link, -1); - rb_define_module_function(mCproton, "pn_messenger_outgoing", _wrap_pn_messenger_outgoing, -1); - rb_define_module_function(mCproton, "pn_messenger_incoming", _wrap_pn_messenger_incoming, -1); - rb_define_module_function(mCproton, "pn_messenger_route", _wrap_pn_messenger_route, -1); - rb_define_module_function(mCproton, "pn_messenger_rewrite", _wrap_pn_messenger_rewrite, -1); - rb_define_module_function(mCproton, "pn_messenger_selectable", _wrap_pn_messenger_selectable, -1); - rb_define_module_function(mCproton, "pn_messenger_deadline", _wrap_pn_messenger_deadline, -1); - rb_define_const(mCproton, "PN_FLAGS_CHECK_ROUTES", SWIG_From_int((int)((0x1)))); - rb_define_const(mCproton, "PN_FLAGS_ALLOW_INSECURE_MECHS", SWIG_From_int((int)((0x2)))); - rb_define_module_function(mCproton, "pn_messenger_set_flags", _wrap_pn_messenger_set_flags, -1); - rb_define_module_function(mCproton, "pn_messenger_get_flags", _wrap_pn_messenger_get_flags, -1); - rb_define_module_function(mCproton, "pn_messenger_set_snd_settle_mode", _wrap_pn_messenger_set_snd_settle_mode, -1); - rb_define_module_function(mCproton, "pn_messenger_set_rcv_settle_mode", _wrap_pn_messenger_set_rcv_settle_mode, -1); - rb_define_module_function(mCproton, "pn_messenger_set_tracer", _wrap_pn_messenger_set_tracer, -1); - rb_define_module_function(mCproton, "pn_messenger_get_remote_idle_timeout", _wrap_pn_messenger_get_remote_idle_timeout, -1); - rb_define_module_function(mCproton, "pn_messenger_set_ssl_peer_authentication_mode", _wrap_pn_messenger_set_ssl_peer_authentication_mode, -1); rb_define_const(mCproton, "PROTON_SELECTABLE_H", SWIG_From_int((int)(1))); rb_define_const(mCproton, "PN_INVALID_SOCKET", SWIG_From_int((int)((-1)))); rb_define_module_function(mCproton, "pn_selectables", _wrap_pn_selectables, -1); rb_define_module_function(mCproton, "pn_selectables_next", _wrap_pn_selectables_next, -1); rb_define_module_function(mCproton, "pn_selectables_free", _wrap_pn_selectables_free, -1); @@ -24582,28 +22732,10 @@ rb_define_module_function(mCproton, "pn_connection_driver_finished", _wrap_pn_connection_driver_finished, -1); rb_define_module_function(mCproton, "pn_connection_driver_errorf", _wrap_pn_connection_driver_errorf, -1); rb_define_module_function(mCproton, "pn_event_batch_connection_driver", _wrap_pn_event_batch_connection_driver, -1); rb_define_module_function(mCproton, "pn_connection_driver_log", _wrap_pn_connection_driver_log, -1); rb_define_module_function(mCproton, "pn_connection_driver_ptr", _wrap_pn_connection_driver_ptr, -1); - rb_define_const(mCproton, "PROTON_URL_H", SWIG_From_int((int)(1))); - rb_define_module_function(mCproton, "pn_url", _wrap_pn_url, -1); - rb_define_module_function(mCproton, "pn_url_parse", _wrap_pn_url_parse, -1); - rb_define_module_function(mCproton, "pn_url_free", _wrap_pn_url_free, -1); - rb_define_module_function(mCproton, "pn_url_clear", _wrap_pn_url_clear, -1); - rb_define_module_function(mCproton, "pn_url_str", _wrap_pn_url_str, -1); - rb_define_module_function(mCproton, "pn_url_get_scheme", _wrap_pn_url_get_scheme, -1); - rb_define_module_function(mCproton, "pn_url_get_username", _wrap_pn_url_get_username, -1); - rb_define_module_function(mCproton, "pn_url_get_password", _wrap_pn_url_get_password, -1); - rb_define_module_function(mCproton, "pn_url_get_host", _wrap_pn_url_get_host, -1); - rb_define_module_function(mCproton, "pn_url_get_port", _wrap_pn_url_get_port, -1); - rb_define_module_function(mCproton, "pn_url_get_path", _wrap_pn_url_get_path, -1); - rb_define_module_function(mCproton, "pn_url_set_scheme", _wrap_pn_url_set_scheme, -1); - rb_define_module_function(mCproton, "pn_url_set_username", _wrap_pn_url_set_username, -1); - rb_define_module_function(mCproton, "pn_url_set_password", _wrap_pn_url_set_password, -1); - rb_define_module_function(mCproton, "pn_url_set_host", _wrap_pn_url_set_host, -1); - rb_define_module_function(mCproton, "pn_url_set_port", _wrap_pn_url_set_port, -1); - rb_define_module_function(mCproton, "pn_url_set_path", _wrap_pn_url_set_path, -1); rb_define_const(mCproton, "PROTON_REACTOR_H", SWIG_From_int((int)(1))); rb_define_module_function(mCproton, "pn_handler", _wrap_pn_handler, -1); rb_define_module_function(mCproton, "pn_handler_new", _wrap_pn_handler_new, -1); rb_define_module_function(mCproton, "pn_handler_free", _wrap_pn_handler_free, -1); rb_define_module_function(mCproton, "pn_handler_mem", _wrap_pn_handler_mem, -1); @@ -24688,7 +22820,25 @@ rb_define_const(mCproton, "CID_pn_selectable", SWIG_From_int((int)(CID_pn_selectable))); rb_define_const(mCproton, "CID_pn_url", SWIG_From_int((int)(CID_pn_url))); rb_define_const(mCproton, "CID_pn_listener", SWIG_From_int((int)(CID_pn_listener))); rb_define_const(mCproton, "CID_pn_proactor", SWIG_From_int((int)(CID_pn_proactor))); rb_define_const(mCproton, "CID_pn_listener_socket", SWIG_From_int((int)(CID_pn_listener_socket))); + rb_define_const(mCproton, "PROTON_URL_H", SWIG_From_int((int)(1))); + rb_define_module_function(mCproton, "pn_url", _wrap_pn_url, -1); + rb_define_module_function(mCproton, "pn_url_parse", _wrap_pn_url_parse, -1); + rb_define_module_function(mCproton, "pn_url_free", _wrap_pn_url_free, -1); + rb_define_module_function(mCproton, "pn_url_clear", _wrap_pn_url_clear, -1); + rb_define_module_function(mCproton, "pn_url_str", _wrap_pn_url_str, -1); + rb_define_module_function(mCproton, "pn_url_get_scheme", _wrap_pn_url_get_scheme, -1); + rb_define_module_function(mCproton, "pn_url_get_username", _wrap_pn_url_get_username, -1); + rb_define_module_function(mCproton, "pn_url_get_password", _wrap_pn_url_get_password, -1); + rb_define_module_function(mCproton, "pn_url_get_host", _wrap_pn_url_get_host, -1); + rb_define_module_function(mCproton, "pn_url_get_port", _wrap_pn_url_get_port, -1); + rb_define_module_function(mCproton, "pn_url_get_path", _wrap_pn_url_get_path, -1); + rb_define_module_function(mCproton, "pn_url_set_scheme", _wrap_pn_url_set_scheme, -1); + rb_define_module_function(mCproton, "pn_url_set_username", _wrap_pn_url_set_username, -1); + rb_define_module_function(mCproton, "pn_url_set_password", _wrap_pn_url_set_password, -1); + rb_define_module_function(mCproton, "pn_url_set_host", _wrap_pn_url_set_host, -1); + rb_define_module_function(mCproton, "pn_url_set_port", _wrap_pn_url_set_port, -1); + rb_define_module_function(mCproton, "pn_url_set_path", _wrap_pn_url_set_path, -1); }