all: esl.jar
esl_wrap.cpp:
- swig -module esl -java -c++ $(LOCAL_CFLAGS) -package org.freeswitch.esl -outdir org/freeswitch/esl -o esl_wrap.cpp ../ESL.i
+ swig2.0 -module esl -java -c++ $(LOCAL_CFLAGS) -package org.freeswitch.esl -outdir org/freeswitch/esl -o esl_wrap.cpp ../ESL.i
esl_wrap.o: esl_wrap.cpp
$(CXX) $(CXX_CFLAGS) $(LOCAL_CFLAGS) $(CXXFLAGS) $(GCC_WARNING_JUNK) $(PERL_INC) -c esl_wrap.cpp -o esl_wrap.o
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
- *
- * This file is not intended to be easily readable and contains a number of
+ * Version 2.0.12
+ *
+ * This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
- * changes to this file unless you know what you are doing--modify the SWIG
- * interface file instead.
+ * changes to this file unless you know what you are doing--modify the SWIG
+ * interface file instead.
* ----------------------------------------------------------------------------- */
+#define SWIGJAVA
+
#ifdef __cplusplus
+/* SwigValueWrapper is described in swig.swg */
template<typename T> class SwigValueWrapper {
- T *tt;
+ struct SwigMovePointer {
+ T *ptr;
+ SwigMovePointer(T *p) : ptr(p) { }
+ ~SwigMovePointer() { delete ptr; }
+ SwigMovePointer& operator=(SwigMovePointer& rhs) { T* oldptr = ptr; ptr = 0; delete oldptr; ptr = rhs.ptr; rhs.ptr = 0; return *this; }
+ } pointer;
+ SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
+ SwigValueWrapper(const SwigValueWrapper<T>& rhs);
public:
- SwigValueWrapper() : tt(0) { }
- SwigValueWrapper(const SwigValueWrapper<T>& rhs) : tt(new T(*rhs.tt)) { }
- SwigValueWrapper(const T& t) : tt(new T(t)) { }
- ~SwigValueWrapper() { delete tt; }
- SwigValueWrapper& operator=(const T& t) { delete tt; tt = new T(t); return *this; }
- operator T&() const { return *tt; }
- T *operator&() { return tt; }
-private:
- SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
+ SwigValueWrapper() : pointer(0) { }
+ SwigValueWrapper& operator=(const T& t) { SwigMovePointer tmp(new T(t)); pointer = tmp; return *this; }
+ operator T&() const { return *pointer.ptr; }
+ T *operator&() { return pointer.ptr; }
};
template <typename T> T SwigValueInit() {
#ifndef SWIGUNUSED
# if defined(__GNUC__)
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
# elif defined(__ICC)
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
-# define SWIGUNUSED
+# define SWIGUNUSED
+# endif
+#endif
+
+#ifndef SWIG_MSC_UNSUPPRESS_4505
+# if defined(_MSC_VER)
+# pragma warning(disable : 4505) /* unreferenced local function has been removed */
# endif
#endif
# ifdef __cplusplus
# define SWIGUNUSEDPARM(p)
# else
-# define SWIGUNUSEDPARM(p) p SWIGUNUSED
+# define SWIGUNUSEDPARM(p) p SWIGUNUSED
# endif
#endif
# define SWIGSTDCALL __stdcall
# else
# define SWIGSTDCALL
-# endif
+# endif
#endif
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
/* Fix for jlong on some versions of gcc on Windows */
-#if defined(__GNUC__) && !defined(__INTELC__)
+#if defined(__GNUC__) && !defined(__INTEL_COMPILER)
typedef long long __int64;
#endif
{ SWIG_JavaNullPointerException, "java/lang/NullPointerException" },
{ SWIG_JavaDirectorPureVirtual, "java/lang/RuntimeException" },
{ SWIG_JavaUnknownError, "java/lang/UnknownError" },
- { (SWIG_JavaExceptionCodes)0, "java/lang/UnknownError" } };
+ { (SWIG_JavaExceptionCodes)0, "java/lang/UnknownError" }
+ };
const SWIG_JavaExceptions_t *except_ptr = java_exceptions;
while (except_ptr->code != code && except_ptr->code)
arg1 = *(ESLevent **)&jarg1;
arg2 = *(esl_event_t **)&jarg2;
if (arg1) (arg1)->event = arg2;
-
}
if (!arg2) return ;
}
{
- if (arg1->serialized_string) delete [] arg1->serialized_string;
+ delete [] arg1->serialized_string;
if (arg2) {
arg1->serialized_string = (char *) (new char[strlen((const char *)arg2)+1]);
strcpy((char *)arg1->serialized_string, (const char *)arg2);
(void)jarg1_;
arg1 = *(ESLevent **)&jarg1;
result = (char *) ((arg1)->serialized_string);
- if(result) jresult = jenv->NewStringUTF((const char *)result);
+ if (result) jresult = jenv->NewStringUTF((const char *)result);
return jresult;
}
arg1 = *(ESLevent **)&jarg1;
arg2 = (int)jarg2;
if (arg1) (arg1)->mine = arg2;
-
}
(void)jcls;
arg1 = *(ESLevent **)&jarg1;
delete arg1;
-
}
if (!arg2) return 0;
}
result = (char *)(arg1)->serialize((char const *)arg2);
- if(result) jresult = jenv->NewStringUTF((const char *)result);
+ if (result) jresult = jenv->NewStringUTF((const char *)result);
if (arg2) jenv->ReleaseStringUTFChars(jarg2, (const char *)arg2);
return jresult;
}
jboolean jresult = 0 ;
ESLevent *arg1 = (ESLevent *) 0 ;
esl_priority_t arg2 = (esl_priority_t) ESL_PRIORITY_NORMAL ;
- bool result;
esl_priority_t *argp2 ;
+ bool result;
(void)jenv;
(void)jcls;
}
arg3 = (int)jarg3;
result = (char *)(arg1)->getHeader((char const *)arg2,arg3);
- if(result) jresult = jenv->NewStringUTF((const char *)result);
+ if (result) jresult = jenv->NewStringUTF((const char *)result);
if (arg2) jenv->ReleaseStringUTFChars(jarg2, (const char *)arg2);
return jresult;
}
(void)jarg1_;
arg1 = *(ESLevent **)&jarg1;
result = (char *)(arg1)->getBody();
- if(result) jresult = jenv->NewStringUTF((const char *)result);
+ if (result) jresult = jenv->NewStringUTF((const char *)result);
return jresult;
}
(void)jarg1_;
arg1 = *(ESLevent **)&jarg1;
result = (char *)(arg1)->getType();
- if(result) jresult = jenv->NewStringUTF((const char *)result);
+ if (result) jresult = jenv->NewStringUTF((const char *)result);
return jresult;
}
(void)jarg1_;
arg1 = *(ESLevent **)&jarg1;
result = (char *)(arg1)->firstHeader();
- if(result) jresult = jenv->NewStringUTF((const char *)result);
+ if (result) jresult = jenv->NewStringUTF((const char *)result);
return jresult;
}
(void)jarg1_;
arg1 = *(ESLevent **)&jarg1;
result = (char *)(arg1)->nextHeader();
- if(result) jresult = jenv->NewStringUTF((const char *)result);
+ if (result) jresult = jenv->NewStringUTF((const char *)result);
return jresult;
}
(void)jcls;
arg1 = *(ESLconnection **)&jarg1;
delete arg1;
-
}
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
}
public synchronized void delete() {
- if(swigCPtr != 0 && swigCMemOwn) {
- swigCMemOwn = false;
- eslJNI.delete_ESLconnection(swigCPtr);
+ if (swigCPtr != 0) {
+ if (swigCMemOwn) {
+ swigCMemOwn = false;
+ eslJNI.delete_ESLconnection(swigCPtr);
+ }
+ swigCPtr = 0;
}
- swigCPtr = 0;
}
public ESLconnection(String host, int port, String user, String password) {
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
}
public synchronized void delete() {
- if(swigCPtr != 0 && swigCMemOwn) {
- swigCMemOwn = false;
- eslJNI.delete_ESLevent(swigCPtr);
+ if (swigCPtr != 0) {
+ if (swigCMemOwn) {
+ swigCMemOwn = false;
+ eslJNI.delete_ESLevent(swigCPtr);
+ }
+ swigCPtr = 0;
}
- swigCPtr = 0;
}
public void setEvent(SWIGTYPE_p_esl_event_t value) {
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
package org.freeswitch.esl;
-class eslJNI {
+public class eslJNI {
public final static native void ESLevent_event_set(long jarg1, ESLevent jarg1_, long jarg2);
public final static native long ESLevent_event_get(long jarg1, ESLevent jarg1_);
public final static native void ESLevent_serialized_string_set(long jarg1, ESLevent jarg1_, String jarg2);
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.7
- *
- * This file is not intended to be easily readable and contains a number of
+ * Version 2.0.12
+ *
+ * This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
- * changes to this file unless you know what you are doing--modify the SWIG
- * interface file instead.
+ * changes to this file unless you know what you are doing--modify the SWIG
+ * interface file instead.
* ----------------------------------------------------------------------------- */
#define SWIGLUA
#ifndef SWIGUNUSED
# if defined(__GNUC__)
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
# elif defined(__ICC)
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
-# define SWIGUNUSED
+# define SWIGUNUSED
# endif
#endif
#ifndef SWIG_MSC_UNSUPPRESS_4505
# if defined(_MSC_VER)
# pragma warning(disable : 4505) /* unreferenced local function has been removed */
-# endif
+# endif
#endif
#ifndef SWIGUNUSEDPARM
# ifdef __cplusplus
# define SWIGUNUSEDPARM(p)
# else
-# define SWIGUNUSEDPARM(p) p SWIGUNUSED
+# define SWIGUNUSEDPARM(p) p SWIGUNUSED
# endif
#endif
# define SWIGSTDCALL __stdcall
# else
# define SWIGSTDCALL
-# endif
+# endif
#endif
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
creating a static or dynamic library from the SWIG runtime code.
In 99.9% of the cases, SWIG just needs to declare them as 'static'.
-
+
But only do this if strictly necessary, ie, if you have problems
with your compiler or suchlike.
*/
#define SWIG_POINTER_OWN 0x1
-/*
+/*
Flags/methods for returning states.
-
- The SWIG conversion methods, as ConvertPtr, return an integer
+
+ The SWIG conversion methods, as ConvertPtr, return an integer
that tells if the conversion was successful or not. And if not,
an error code can be returned (see swigerrors.swg for the codes).
-
+
Use the following macros/flags to set or process the returning
states.
-
+
In old versions of SWIG, code such as the following was usually written:
if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
} else {
// fail code
}
-
+
I.e., now SWIG_ConvertPtr can return new objects and you can
identify the case and take care of the deallocation. Of course that
also requires SWIG_ConvertPtr to return new result values, such as
- int SWIG_ConvertPtr(obj, ptr,...) {
- if (<obj is ok>) {
- if (<need new object>) {
- *ptr = <ptr to new allocated object>;
- return SWIG_NEWOBJ;
- } else {
- *ptr = <ptr to old object>;
- return SWIG_OLDOBJ;
- }
- } else {
- return SWIG_BADOBJ;
- }
+ int SWIG_ConvertPtr(obj, ptr,...) {
+ if (<obj is ok>) {
+ if (<need new object>) {
+ *ptr = <ptr to new allocated object>;
+ return SWIG_NEWOBJ;
+ } else {
+ *ptr = <ptr to old object>;
+ return SWIG_OLDOBJ;
+ }
+ } else {
+ return SWIG_BADOBJ;
+ }
}
Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
int fooi(int);
and you call
-
+
food(1) // cast rank '1' (1 -> 1.0)
fooi(1) // cast rank '0'
just use the SWIG_AddCast()/SWIG_CheckState()
*/
-#define SWIG_OK (0)
+#define SWIG_OK (0)
#define SWIG_ERROR (-1)
#define SWIG_IsOK(r) (r >= 0)
-#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
+#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
/* The CastRankLimit says how many bits are used for the cast rank */
#define SWIG_CASTRANKLIMIT (1 << 8)
# endif
# define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
# define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
-SWIGINTERNINLINE int SWIG_AddCast(int r) {
+SWIGINTERNINLINE int SWIG_AddCast(int r) {
return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
}
-SWIGINTERNINLINE int SWIG_CheckState(int r) {
- return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
+SWIGINTERNINLINE int SWIG_CheckState(int r) {
+ return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
}
#else /* no cast-rank mode */
-# define SWIG_AddCast
+# define SWIG_AddCast(r) (r)
# define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
#endif
void *clientdata; /* Language specific module data */
} swig_module_info;
-/*
+/*
Compare two type names skipping the space characters, therefore
"char*" == "char *" and "Class<int>" == "Class<int >", etc.
/*
Check type equivalence in a name list like <name1>|<name2>|...
- Return 0 if not equal, 1 if equal
+ Return 0 if equal, -1 if nb < tb, 1 if nb > tb
*/
SWIGRUNTIME int
-SWIG_TypeEquiv(const char *nb, const char *tb) {
- int equiv = 0;
+SWIG_TypeCmp(const char *nb, const char *tb) {
+ int equiv = 1;
const char* te = tb + strlen(tb);
const char* ne = nb;
- while (!equiv && *ne) {
+ while (equiv != 0 && *ne) {
for (nb = ne; *ne; ++ne) {
if (*ne == '|') break;
}
- equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
+ equiv = SWIG_TypeNameComp(nb, ne, tb, te);
if (*ne) ++ne;
}
return equiv;
/*
Check type equivalence in a name list like <name1>|<name2>|...
- Return 0 if equal, -1 if nb < tb, 1 if nb > tb
+ Return 0 if not equal, 1 if equal
*/
SWIGRUNTIME int
-SWIG_TypeCompare(const char *nb, const char *tb) {
- int equiv = 0;
- const char* te = tb + strlen(tb);
- const char* ne = nb;
- while (!equiv && *ne) {
- for (nb = ne; *ne; ++ne) {
- if (*ne == '|') break;
- }
- equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
- if (*ne) ++ne;
- }
- return equiv;
+SWIG_TypeEquiv(const char *nb, const char *tb) {
+ return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
}
-
/*
Check the typename
*/
return 0;
}
-/*
+/*
Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
*/
SWIGRUNTIME swig_cast_info *
return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
}
-/*
+/*
Dynamic pointer casting. Down an inheritance hierarchy
*/
SWIGRUNTIME swig_type_info *
return type->name;
}
-/*
+/*
Set the clientdata field for a type
*/
SWIGRUNTIME void
swig_cast_info *cast = ti->cast;
/* if (ti->clientdata == clientdata) return; */
ti->clientdata = clientdata;
-
+
while (cast) {
if (!cast->converter) {
swig_type_info *tc = cast->type;
if (!tc->clientdata) {
SWIG_TypeClientData(tc, clientdata);
}
- }
+ }
cast = cast->next;
}
}
SWIG_TypeClientData(ti, clientdata);
ti->owndata = 1;
}
-
+
/*
Search for a swig_type_info structure only by mangled name
Search is a O(log #types)
-
- We start searching at module start, and finish searching when start == end.
+
+ We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
-SWIG_MangledTypeQueryModule(swig_module_info *start,
- swig_module_info *end,
+SWIG_MangledTypeQueryModule(swig_module_info *start,
+ swig_module_info *end,
const char *name) {
swig_module_info *iter = start;
do {
register size_t r = iter->size - 1;
do {
/* since l+r >= 0, we can (>> 1) instead (/ 2) */
- register size_t i = (l + r) >> 1;
+ register size_t i = (l + r) >> 1;
const char *iname = iter->types[i]->name;
if (iname) {
register int compare = strcmp(name, iname);
- if (compare == 0) {
+ if (compare == 0) {
return iter->types[i];
} else if (compare < 0) {
if (i) {
Search for a swig_type_info structure for either a mangled name or a human readable name.
It first searches the mangled names of the types, which is a O(log #types)
If a type is not found it then searches the human readable names, which is O(#types).
-
- We start searching at module start, and finish searching when start == end.
+
+ We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
-SWIG_TypeQueryModule(swig_module_info *start,
- swig_module_info *end,
+SWIG_TypeQueryModule(swig_module_info *start,
+ swig_module_info *end,
const char *name) {
/* STEP 1: Search the name field using binary search */
swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
iter = iter->next;
} while (iter != end);
}
-
+
/* neither found a match */
return 0;
}
-/*
+/*
Pack binary data into a string
*/
SWIGRUNTIME char *
return c;
}
-/*
+/*
Unpack binary data from a string
*/
SWIGRUNTIME const char *
uu = ((d - '0') << 4);
else if ((d >= 'a') && (d <= 'f'))
uu = ((d - ('a'-10)) << 4);
- else
+ else
return (char *) 0;
d = *(c++);
if ((d >= '0') && (d <= '9'))
uu |= (d - '0');
else if ((d >= 'a') && (d <= 'f'))
uu |= (d - ('a'-10));
- else
+ else
return (char *) 0;
*u = uu;
}
return c;
}
-/*
+/*
Pack 'void *' into a string buffer.
*/
SWIGRUNTIME char *
#endif
+/* --------------------------------------------------------------------------
+ * Helper functions for error handling
+ * -------------------------------------------------------------------------- */
+
+/* Push the string STR on the Lua stack, like lua_pushstring, but
+ prefixed with the the location of the innermost Lua call-point
+ (as formated by luaL_where). */
+SWIGRUNTIME void
+SWIG_Lua_pusherrstring (lua_State *L, const char *str)
+{
+ luaL_where (L, 1);
+ lua_pushstring (L, str);
+ lua_concat (L, 2);
+}
+
+/* Push a formatted string generated from FMT and following args on
+ the Lua stack, like lua_pushfstring, but prefixed with the the
+ location of the innermost Lua call-point (as formated by luaL_where). */
+SWIGRUNTIME void
+SWIG_Lua_pushferrstring (lua_State *L, const char *fmt, ...)
+{
+ va_list argp;
+ va_start(argp, fmt);
+ luaL_where(L, 1);
+ lua_pushvfstring(L, fmt, argp);
+ va_end(argp);
+ lua_concat(L, 2);
+}
+
+
/* -----------------------------------------------------------------------------
* global swig types
* ----------------------------------------------------------------------------- */
lua_CFunction setmethod;
} swig_lua_attribute;
+// Can be used to create namespaces. Currently used to
+// wrap class static methods/variables/constants
+typedef struct {
+ const char *name;
+ swig_lua_method *ns_methods;
+ swig_lua_attribute *ns_attributes;
+ swig_lua_const_info *ns_constants;
+} swig_lua_namespace;
+
typedef struct swig_lua_class {
const char *name;
swig_type_info **type;
void (*destructor)(void *);
swig_lua_method *methods;
swig_lua_attribute *attributes;
+ swig_lua_namespace cls_static;
struct swig_lua_class **bases;
const char **base_names;
} swig_lua_class;
-/* this is the struct for wrappering all pointers in SwigLua
+/* this is the struct for wrapping all pointers in SwigLua
*/
typedef struct {
swig_type_info *type;
void *ptr;
} swig_lua_userdata;
-/* this is the struct for wrapping arbitary packed binary data
+/* this is the struct for wrapping arbitrary packed binary data
(currently it is only used for member function pointers)
the data ordering is similar to swig_lua_userdata, but it is currently not possible
to tell the two structures apart within SWIG, other than by looking at the type
/* Contract support */
#define SWIG_contract_assert(expr, msg) \
- if (!(expr)) { lua_pushstring(L, (char *) msg); goto fail; } else
+ if (!(expr)) { SWIG_Lua_pusherrstring(L, (char *) msg); goto fail; } else
+
/* helper #defines */
#define SWIG_fail {goto fail;}
#define SWIG_fail_arg(func_name,argnum,type) \
- {lua_pushfstring(L,"Error in %s (arg %d), expected '%s' got '%s'",\
+ {SWIG_Lua_pushferrstring(L,"Error in %s (arg %d), expected '%s' got '%s'",\
func_name,argnum,type,SWIG_Lua_typename(L,argnum));\
goto fail;}
#define SWIG_fail_ptr(func_name,argnum,type) \
SWIG_fail_arg(func_name,argnum,(type && type->str)?type->str:"void*")
#define SWIG_check_num_args(func_name,a,b) \
if (lua_gettop(L)<a || lua_gettop(L)>b) \
- {lua_pushfstring(L,"Error in %s expected %d..%d args, got %d",func_name,a,b,lua_gettop(L));\
+ {SWIG_Lua_pushferrstring(L,"Error in %s expected %d..%d args, got %d",func_name,a,b,lua_gettop(L));\
goto fail;}
* ----------------------------------------------------------------------------- */
/* this function is called when trying to set an immutable.
-default value is to print an error.
+default action is to print an error.
This can removed with a compile flag SWIGLUA_IGNORE_SET_IMMUTABLE */
SWIGINTERN int SWIG_Lua_set_immutable(lua_State* L)
{
/* there should be 1 param passed in: the new value */
#ifndef SWIGLUA_IGNORE_SET_IMMUTABLE
lua_pop(L,1); /* remove it */
- lua_pushstring(L,"This variable is immutable");
- lua_error(L);
+ luaL_error(L,"This variable is immutable");
#endif
return 0; /* should not return anything */
}
SWIG_Lua_add_function(L,name,fn);
}
+/* -----------------------------------------------------------------------------
+ * global variable support code: namespaces
+ * ----------------------------------------------------------------------------- */
+
+SWIGINTERN int SWIG_Lua_namespace_get(lua_State* L)
+{
+/* there should be 2 params passed in
+ (1) table (not the meta table)
+ (2) string name of the attribute
+*/
+ assert(lua_istable(L,-2)); /* just in case */
+ lua_getmetatable(L,-2);
+ assert(lua_istable(L,-1));
+ SWIG_Lua_get_table(L,".get"); /* find the .get table */
+ assert(lua_istable(L,-1));
+ /* look for the key in the .get table */
+ lua_pushvalue(L,2); /* key */
+ lua_rawget(L,-2);
+ lua_remove(L,-2); /* stack tidy, remove .get table */
+ if (lua_iscfunction(L,-1))
+ { /* found it so call the fn & return its value */
+ lua_call(L,0,1); /* 1 value in (userdata),1 out (result) */
+ lua_remove(L,-2); /* stack tidy, remove metatable */
+ return 1;
+ }
+ lua_pop(L,1); /* remove whatever was there */
+ /* ok, so try the .fn table */
+ SWIG_Lua_get_table(L,".fn"); /* find the .get table */
+ assert(lua_istable(L,-1)); /* just in case */
+ lua_pushvalue(L,2); /* key */
+ lua_rawget(L,-2); /* look for the fn */
+ lua_remove(L,-2); /* stack tidy, remove .fn table */
+ if (lua_isfunction(L,-1)) /* note: whether it's a C function or lua function */
+ { /* found it so return the fn & let lua call it */
+ lua_remove(L,-2); /* stack tidy, remove metatable */
+ return 1;
+ }
+ lua_pop(L,1); /* remove whatever was there */
+ return 0;
+}
+
+SWIGINTERN int SWIG_Lua_namespace_set(lua_State* L)
+{
+/* there should be 3 params passed in
+ (1) table (not the meta table)
+ (2) string name of the attribute
+ (3) any for the new value
+*/
+
+ assert(lua_istable(L,1));
+ lua_getmetatable(L,1); /* get the meta table */
+ assert(lua_istable(L,-1));
+
+ SWIG_Lua_get_table(L,".set"); /* find the .set table */
+ if (lua_istable(L,-1))
+ {
+ /* look for the key in the .set table */
+ lua_pushvalue(L,2); /* key */
+ lua_rawget(L,-2);
+ if (lua_iscfunction(L,-1))
+ { /* found it so call the fn & return its value */
+ lua_pushvalue(L,3); /* value */
+ lua_call(L,1,0);
+ return 0;
+ }
+ lua_pop(L,1); /* remove the value */
+ }
+ lua_pop(L,1); /* remove the value .set table */
+ return 0;
+}
+
+SWIGINTERN void SWIG_Lua_InstallConstants(lua_State* L, swig_lua_const_info constants[]); // forward declaration
+SWIGINTERN void SWIG_Lua_add_class_variable(lua_State* L,const char* name,lua_CFunction getFn,lua_CFunction setFn); // forward declaration
+
+/* helper function - register namespace methods and attributes into namespace */
+SWIGINTERN int SWIG_Lua_add_namespace_details(lua_State* L, swig_lua_namespace* ns)
+{
+ int i = 0;
+ assert(lua_istable(L,-1));
+ /* There must be table at the top of the stack */
+ SWIG_Lua_InstallConstants(L, ns->ns_constants);
+
+ lua_getmetatable(L,-1);
+
+ /* add fns */
+ for(i=0;ns->ns_attributes[i].name;i++){
+ SWIG_Lua_add_class_variable(L,ns->ns_attributes[i].name,ns->ns_attributes[i].getmethod,ns->ns_attributes[i].setmethod);
+ }
+
+ /* add methods to the metatable */
+ SWIG_Lua_get_table(L,".fn"); /* find the .fn table */
+ assert(lua_istable(L,-1)); /* just in case */
+ for(i=0;ns->ns_methods[i].name;i++){
+ SWIG_Lua_add_function(L,ns->ns_methods[i].name,ns->ns_methods[i].method);
+ }
+ lua_pop(L,1);
+
+ /* clear stack - remove metatble */
+ lua_pop(L,1);
+ return 0;
+}
+
+/* helper function. creates namespace table and add it to module table */
+SWIGINTERN int SWIG_Lua_namespace_register(lua_State* L, swig_lua_namespace* ns)
+{
+ assert(lua_istable(L,-1)); /* just in case. This is supposed to be module table */
+ lua_checkstack(L,5);
+ lua_pushstring(L, ns->name);
+ lua_newtable(L); /* namespace itself */
+ lua_newtable(L); /* metatable for namespace */
+
+ /* add a table called ".get" */
+ lua_pushstring(L,".get");
+ lua_newtable(L);
+ lua_rawset(L,-3);
+ /* add a table called ".set" */
+ lua_pushstring(L,".set");
+ lua_newtable(L);
+ lua_rawset(L,-3);
+ /* add a table called ".fn" */
+ lua_pushstring(L,".fn");
+ lua_newtable(L);
+ lua_rawset(L,-3);
+
+ /* add accessor fns for using the .get,.set&.fn */
+ SWIG_Lua_add_function(L,"__index",SWIG_Lua_namespace_get);
+ SWIG_Lua_add_function(L,"__newindex",SWIG_Lua_namespace_set);
+
+ lua_setmetatable(L,-2); /* set metatable */
+ lua_rawset(L,-3); /* add namespace to module table */
+ return 0;
+}
/* -----------------------------------------------------------------------------
* global variable support code: classes
* ----------------------------------------------------------------------------- */
return 0;
}
+/* Constructor proxy. Used when class name entry in module is not class constructor,
+but special table instead. */
+SWIGINTERN int SWIG_Lua_constructor_proxy(lua_State* L)
+{
+ /* unlimited number of parameters
+ First one is our proxy table and we should remove it
+ Other we should pass to real constructor
+ */
+ assert(lua_istable(L,1));
+ lua_pushstring(L,".constructor");
+ lua_rawget(L,1);
+ assert(!lua_isnil(L,-1));
+ lua_replace(L,1); /* replace our table with real constructor */
+ lua_call(L,lua_gettop(L)-1,1);
+ return 1;
+}
+
/* gets the swig class registry (or creates it) */
SWIGINTERN void SWIG_Lua_get_class_registry(lua_State* L)
{
}
}
+/* helper to recursively add class static details (static attributes, operations and constants) */
+SWIGINTERN void SWIG_Lua_add_class_static_details(lua_State* L, swig_lua_class* clss)
+{
+ int i = 0;
+ /* The class namespace table must be on the top of the stack */
+ assert(lua_istable(L,-1));
+ /* call all the base classes first: we can then override these later: */
+ for(i=0;clss->bases[i];i++)
+ {
+ SWIG_Lua_add_class_static_details(L,clss->bases[i]);
+ }
+
+ SWIG_Lua_add_namespace_details(L, &clss->cls_static);
+}
+
/* helper to recursively add class details (attributes & operations) */
SWIGINTERN void SWIG_Lua_add_class_details(lua_State* L,swig_lua_class* clss)
{
swig_type_info *info = SWIG_TypeQueryModule(module,module,clss->base_names[i]);
if (info) clss->bases[i] = (swig_lua_class *) info->clientdata;
}
- }
+ }
}
-/* performs the entire class registration process */
-SWIGINTERN void SWIG_Lua_class_register(lua_State* L,swig_lua_class* clss)
+/* Register class static methods,attributes etc as well as constructor proxy */
+SWIGINTERN void SWIG_Lua_class_register_static(lua_State* L, swig_lua_class* clss)
{
+ lua_checkstack(L,5); /* just in case */
+ assert(lua_istable(L,-1)); /* just in case */
+ assert(strcmp(clss->name, clss->cls_static.name) == 0); /* in class those 2 must be equal */
+
+ SWIG_Lua_namespace_register(L,&clss->cls_static);
+
+ SWIG_Lua_get_table(L,clss->name); // Get namespace table back
+ assert(lua_istable(L,-1)); /* just in case */
+
/* add its constructor to module with the name of the class
so you can do MyClass(...) as well as new_MyClass(...)
BUT only if a constructor is defined
(this overcomes the problem of pure virtual classes without constructors)*/
if (clss->constructor)
- SWIG_Lua_add_function(L,clss->name,clss->constructor);
+ {
+ SWIG_Lua_add_function(L,".constructor", clss->constructor);
+ lua_getmetatable(L,-1);
+ assert(lua_istable(L,-1)); /* just in case */
+ SWIG_Lua_add_function(L,"__call", SWIG_Lua_constructor_proxy);
+ lua_pop(L,1);
+ }
+
+ assert(lua_istable(L,-1)); /* just in case */
+ SWIG_Lua_add_class_static_details(L, clss);
+
+ /* clear stack */
+ lua_pop(L,1);
+}
+
+/* performs the entire class registration process */
+SWIGINTERN void SWIG_Lua_class_register(lua_State* L,swig_lua_class* clss)
+{
+ SWIG_Lua_class_register_static(L,clss);
SWIG_Lua_get_class_registry(L); /* get the registry */
lua_pushstring(L,clss->name); /* get the name */
int argnum,const char* func_name){
void* result;
if (!SWIG_IsOK(SWIG_ConvertPtr(L,index,&result,type,flags))){
- lua_pushfstring(L,"Error in %s, expected a %s at argument number %d\n",
- func_name,(type && type->str)?type->str:"void*",argnum);
- lua_error(L);
+ luaL_error (L,"Error in %s, expected a %s at argument number %d\n",
+ func_name,(type && type->str)?type->str:"void*",argnum);
}
return result;
}
#ifndef SWIG_DOSTRING_FAIL /* Allows redefining of error function */
#define SWIG_DOSTRING_FAIL(S) fprintf(stderr,"%s\n",S)
#endif
-/* Executes a C string in Lua a really simple way of calling lua from C
-Unfortunately lua keeps changing its API's, so we need a conditional compile
+/* Executes a C string in Lua which is a really simple way of calling lua from C
+Unfortunately lua keeps changing its APIs, so we need a conditional compile
In lua 5.0.X its lua_dostring()
In lua 5.1.X its luaL_dostring()
*/
}
}
- lua_pushstring(L,"Wrong arguments for overloaded function 'new_ESLevent'\n"
+ SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'new_ESLevent'\n"
" Possible C/C++ prototypes are:\n"
" ESLevent::ESLevent(char const *,char const *)\n"
" ESLevent::ESLevent(esl_event_t *,int)\n"
{ "mine", _wrap_ESLevent_mine_get, _wrap_ESLevent_mine_set},
{0,0,0}
};
+static swig_lua_attribute swig_ESLevent_cls_attributes[] = {
+ {0,0,0}
+};
+static swig_lua_method swig_ESLevent_cls_methods[] = {
+ {0,0}
+};
+static swig_lua_const_info swig_ESLevent_cls_constants[] = {
+ {0,0,0,0,0,0}
+};
static swig_lua_class *swig_ESLevent_bases[] = {0};
static const char *swig_ESLevent_base_names[] = {0};
-static swig_lua_class _wrap_class_ESLevent = { "ESLevent", &SWIGTYPE_p_ESLevent,_wrap_new_ESLevent, swig_delete_ESLevent, swig_ESLevent_methods, swig_ESLevent_attributes, swig_ESLevent_bases, swig_ESLevent_base_names };
+static swig_lua_class _wrap_class_ESLevent = { "ESLevent", &SWIGTYPE_p_ESLevent,_wrap_new_ESLevent, swig_delete_ESLevent, swig_ESLevent_methods, swig_ESLevent_attributes, { "ESLevent", swig_ESLevent_cls_methods, swig_ESLevent_cls_attributes, swig_ESLevent_cls_constants }, swig_ESLevent_bases, swig_ESLevent_base_names };
static int _wrap_new_ESLconnection__SWIG_0(lua_State* L) {
int SWIG_arg = 0;
}
}
- lua_pushstring(L,"Wrong arguments for overloaded function 'new_ESLconnection'\n"
+ SWIG_Lua_pusherrstring(L,"Wrong arguments for overloaded function 'new_ESLconnection'\n"
" Possible C/C++ prototypes are:\n"
" ESLconnection::ESLconnection(char const *,int const,char const *,char const *)\n"
" ESLconnection::ESLconnection(char const *,int const,char const *)\n"
static swig_lua_attribute swig_ESLconnection_attributes[] = {
{0,0,0}
};
+static swig_lua_attribute swig_ESLconnection_cls_attributes[] = {
+ {0,0,0}
+};
+static swig_lua_method swig_ESLconnection_cls_methods[] = {
+ {0,0}
+};
+static swig_lua_const_info swig_ESLconnection_cls_constants[] = {
+ {0,0,0,0,0,0}
+};
static swig_lua_class *swig_ESLconnection_bases[] = {0};
static const char *swig_ESLconnection_base_names[] = {0};
-static swig_lua_class _wrap_class_ESLconnection = { "ESLconnection", &SWIGTYPE_p_ESLconnection,_wrap_new_ESLconnection, swig_delete_ESLconnection, swig_ESLconnection_methods, swig_ESLconnection_attributes, swig_ESLconnection_bases, swig_ESLconnection_base_names };
+static swig_lua_class _wrap_class_ESLconnection = { "ESLconnection", &SWIGTYPE_p_ESLconnection,_wrap_new_ESLconnection, swig_delete_ESLconnection, swig_ESLconnection_methods, swig_ESLconnection_attributes, { "ESLconnection", swig_ESLconnection_cls_methods, swig_ESLconnection_cls_attributes, swig_ESLconnection_cls_constants }, swig_ESLconnection_bases, swig_ESLconnection_base_names };
static int _wrap_eslSetLogLevel(lua_State* L) {
int SWIG_arg = 0;
/* -----------------------------------------------------------------------------
* Type initialization:
- * This problem is tough by the requirement that no dynamic
- * memory is used. Also, since swig_type_info structures store pointers to
+ * This problem is tough by the requirement that no dynamic
+ * memory is used. Also, since swig_type_info structures store pointers to
* swig_cast_info structures and swig_cast_info structures store pointers back
- * to swig_type_info structures, we need some lookup code at initialization.
- * The idea is that swig generates all the structures that are needed.
- * The runtime then collects these partially filled structures.
- * The SWIG_InitializeModule function takes these initial arrays out of
+ * to swig_type_info structures, we need some lookup code at initialization.
+ * The idea is that swig generates all the structures that are needed.
+ * The runtime then collects these partially filled structures.
+ * The SWIG_InitializeModule function takes these initial arrays out of
* swig_module, and does all the lookup, filling in the swig_module.types
* array with the correct data and linking the correct swig_cast_info
* structures together.
*
- * The generated swig_type_info structures are assigned staticly to an initial
+ * The generated swig_type_info structures are assigned staticly to an initial
* array. We just loop through that array, and handle each type individually.
* First we lookup if this type has been already loaded, and if so, use the
* loaded structure instead of the generated one. Then we have to fill in the
* a column is one of the swig_cast_info structures for that type.
* The cast_initial array is actually an array of arrays, because each row has
* a variable number of columns. So to actually build the cast linked list,
- * we find the array of casts associated with the type, and loop through it
+ * we find the array of casts associated with the type, and loop through it
* adding the casts to the list. The one last trick we need to do is making
* sure the type pointer in the swig_cast_info struct is correct.
*
- * First off, we lookup the cast->type name to see if it is already loaded.
+ * First off, we lookup the cast->type name to see if it is already loaded.
* There are three cases to handle:
* 1) If the cast->type has already been loaded AND the type we are adding
* casting info to has not been loaded (it is in this module), THEN we
* replace the cast->type pointer with the type pointer that has already
* been loaded.
- * 2) If BOTH types (the one we are adding casting info to, and the
+ * 2) If BOTH types (the one we are adding casting info to, and the
* cast->type) are loaded, THEN the cast info has already been loaded by
* the previous module so we just ignore it.
* 3) Finally, if cast->type has not already been loaded, then we add that
swig_module_info *module_head, *iter;
int found, init;
- clientdata = clientdata;
-
/* check to see if the circular list has been setup, if not, set it up */
if (swig_module.next==0) {
/* Initialize the swig_module */
module_head->next = &swig_module;
}
- /* When multiple interpeters are used, a module could have already been initialized in
+ /* When multiple interpreters are used, a module could have already been initialized in
a different interpreter, but not yet have a pointer in this interpreter.
In this case, we do not want to continue adding types... everything should be
set up already */
swig_type_info *type = 0;
swig_type_info *ret;
swig_cast_info *cast;
-
+
#ifdef SWIGRUNTIME_DEBUG
printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
#endif
/* Insert casting types */
cast = swig_module.cast_initial[i];
while (cast->type) {
-
+
/* Don't need to add information already in the list */
ret = 0;
#ifdef SWIGRUNTIME_DEBUG
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
static protected SWIGStringHelper swigStringHelper = new SWIGStringHelper();
+ static ESLPINVOKE() {
+ }
+
+
[DllImport("ESL", EntryPoint="CSharp_ESLevent_Event_set")]
public static extern void ESLevent_Event_set(HandleRef jarg1, HandleRef jarg2);
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
public virtual void Dispose() {
lock(this) {
- if(swigCPtr.Handle != IntPtr.Zero && swigCMemOwn) {
- swigCMemOwn = false;
- ESLPINVOKE.delete_ESLconnection(swigCPtr);
+ if (swigCPtr.Handle != IntPtr.Zero) {
+ if (swigCMemOwn) {
+ swigCMemOwn = false;
+ ESLPINVOKE.delete_ESLconnection(swigCPtr);
+ }
+ swigCPtr = new HandleRef(null, IntPtr.Zero);
}
- swigCPtr = new HandleRef(null, IntPtr.Zero);
GC.SuppressFinalize(this);
}
}
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
public virtual void Dispose() {
lock(this) {
- if(swigCPtr.Handle != IntPtr.Zero && swigCMemOwn) {
- swigCMemOwn = false;
- ESLPINVOKE.delete_ESLevent(swigCPtr);
+ if (swigCPtr.Handle != IntPtr.Zero) {
+ if (swigCMemOwn) {
+ swigCMemOwn = false;
+ ESLPINVOKE.delete_ESLevent(swigCPtr);
+ }
+ swigCPtr = new HandleRef(null, IntPtr.Zero);
}
- swigCPtr = new HandleRef(null, IntPtr.Zero);
GC.SuppressFinalize(this);
}
}
all: ESL.so
esl_wrap.cpp:
- swig -module ESL -csharp -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
+ swig2.0 -module ESL -csharp -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
esl_wrap.o: esl_wrap.cpp
$(CXX) $(CXX_CFLAGS) $(CXXFLAGS) $(LOCAL_CFLAGS) $(WRAP_GCC_WARNING_SILENCE) -c esl_wrap.cpp -o esl_wrap.o
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 2.0.12
*
* Do not make changes to this file unless you know what you are doing--modify
* the SWIG interface file instead.
+++ /dev/null
-/* ----------------------------------------------------------------------------
- * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.1
- *
- * This file is not intended to be easily readable and contains a number of
- * coding conventions designed to improve portability and efficiency. Do not make
- * changes to this file unless you know what you are doing--modify the SWIG
- * interface file instead.
- * ----------------------------------------------------------------------------- */
-
-#define SWIGCSHARP
-
-
-#ifdef __cplusplus
-/* SwigValueWrapper is described in swig.swg */
-template<typename T> class SwigValueWrapper {
- struct SwigMovePointer {
- T *ptr;
- SwigMovePointer(T *p) : ptr(p) { }
- ~SwigMovePointer() { delete ptr; }
- SwigMovePointer& operator=(SwigMovePointer& rhs) { T* oldptr = ptr; ptr = 0; delete oldptr; ptr = rhs.ptr; rhs.ptr = 0; return *this; }
- } pointer;
- SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
- SwigValueWrapper(const SwigValueWrapper<T>& rhs);
-public:
- SwigValueWrapper() : pointer(0) { }
- SwigValueWrapper& operator=(const T& t) { SwigMovePointer tmp(new T(t)); pointer = tmp; return *this; }
- operator T&() const { return *pointer.ptr; }
- T *operator&() { return pointer.ptr; }
-};
-
-template <typename T> T SwigValueInit() {
- return T();
-}
-#endif
-
-/* -----------------------------------------------------------------------------
- * This section contains generic SWIG labels for method/variable
- * declarations/attributes, and other compiler dependent labels.
- * ----------------------------------------------------------------------------- */
-
-/* template workaround for compilers that cannot correctly implement the C++ standard */
-#ifndef SWIGTEMPLATEDISAMBIGUATOR
-# if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
-# define SWIGTEMPLATEDISAMBIGUATOR template
-# elif defined(__HP_aCC)
-/* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */
-/* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */
-# define SWIGTEMPLATEDISAMBIGUATOR template
-# else
-# define SWIGTEMPLATEDISAMBIGUATOR
-# endif
-#endif
-
-/* inline attribute */
-#ifndef SWIGINLINE
-# if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
-# define SWIGINLINE inline
-# else
-# define SWIGINLINE
-# endif
-#endif
-
-/* attribute recognised by some compilers to avoid 'unused' warnings */
-#ifndef SWIGUNUSED
-# if defined(__GNUC__)
-# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
-# define SWIGUNUSED __attribute__ ((__unused__))
-# else
-# define SWIGUNUSED
-# endif
-# elif defined(__ICC)
-# define SWIGUNUSED __attribute__ ((__unused__))
-# else
-# define SWIGUNUSED
-# endif
-#endif
-
-#ifndef SWIG_MSC_UNSUPPRESS_4505
-# if defined(_MSC_VER)
-# pragma warning(disable : 4505) /* unreferenced local function has been removed */
-# endif
-#endif
-
-#ifndef SWIGUNUSEDPARM
-# ifdef __cplusplus
-# define SWIGUNUSEDPARM(p)
-# else
-# define SWIGUNUSEDPARM(p) p SWIGUNUSED
-# endif
-#endif
-
-/* internal SWIG method */
-#ifndef SWIGINTERN
-# define SWIGINTERN static SWIGUNUSED
-#endif
-
-/* internal inline SWIG method */
-#ifndef SWIGINTERNINLINE
-# define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
-#endif
-
-/* exporting methods */
-#if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
-# ifndef GCC_HASCLASSVISIBILITY
-# define GCC_HASCLASSVISIBILITY
-# endif
-#endif
-
-#ifndef SWIGEXPORT
-# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
-# if defined(STATIC_LINKED)
-# define SWIGEXPORT
-# else
-# define SWIGEXPORT __declspec(dllexport)
-# endif
-# else
-# if defined(__GNUC__) && defined(GCC_HASCLASSVISIBILITY)
-# define SWIGEXPORT __attribute__ ((visibility("default")))
-# else
-# define SWIGEXPORT
-# endif
-# endif
-#endif
-
-/* calling conventions for Windows */
-#ifndef SWIGSTDCALL
-# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
-# define SWIGSTDCALL __stdcall
-# else
-# define SWIGSTDCALL
-# endif
-#endif
-
-/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
-#if !defined(SWIG_NO_CRT_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE)
-# define _CRT_SECURE_NO_DEPRECATE
-#endif
-
-/* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */
-#if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE)
-# define _SCL_SECURE_NO_DEPRECATE
-#endif
-
-
-
-#include <stdlib.h>
-#include <string.h>
-#include <stdio.h>
-
-
-/* Support for throwing C# exceptions from C/C++. There are two types:
- * Exceptions that take a message and ArgumentExceptions that take a message and a parameter name. */
-typedef enum {
- SWIG_CSharpApplicationException,
- SWIG_CSharpArithmeticException,
- SWIG_CSharpDivideByZeroException,
- SWIG_CSharpIndexOutOfRangeException,
- SWIG_CSharpInvalidCastException,
- SWIG_CSharpInvalidOperationException,
- SWIG_CSharpIOException,
- SWIG_CSharpNullReferenceException,
- SWIG_CSharpOutOfMemoryException,
- SWIG_CSharpOverflowException,
- SWIG_CSharpSystemException
-} SWIG_CSharpExceptionCodes;
-
-typedef enum {
- SWIG_CSharpArgumentException,
- SWIG_CSharpArgumentNullException,
- SWIG_CSharpArgumentOutOfRangeException
-} SWIG_CSharpExceptionArgumentCodes;
-
-typedef void (SWIGSTDCALL* SWIG_CSharpExceptionCallback_t)(const char *);
-typedef void (SWIGSTDCALL* SWIG_CSharpExceptionArgumentCallback_t)(const char *, const char *);
-
-typedef struct {
- SWIG_CSharpExceptionCodes code;
- SWIG_CSharpExceptionCallback_t callback;
-} SWIG_CSharpException_t;
-
-typedef struct {
- SWIG_CSharpExceptionArgumentCodes code;
- SWIG_CSharpExceptionArgumentCallback_t callback;
-} SWIG_CSharpExceptionArgument_t;
-
-static SWIG_CSharpException_t SWIG_csharp_exceptions[] = {
- { SWIG_CSharpApplicationException, NULL },
- { SWIG_CSharpArithmeticException, NULL },
- { SWIG_CSharpDivideByZeroException, NULL },
- { SWIG_CSharpIndexOutOfRangeException, NULL },
- { SWIG_CSharpInvalidCastException, NULL },
- { SWIG_CSharpInvalidOperationException, NULL },
- { SWIG_CSharpIOException, NULL },
- { SWIG_CSharpNullReferenceException, NULL },
- { SWIG_CSharpOutOfMemoryException, NULL },
- { SWIG_CSharpOverflowException, NULL },
- { SWIG_CSharpSystemException, NULL }
-};
-
-static SWIG_CSharpExceptionArgument_t SWIG_csharp_exceptions_argument[] = {
- { SWIG_CSharpArgumentException, NULL },
- { SWIG_CSharpArgumentNullException, NULL },
- { SWIG_CSharpArgumentOutOfRangeException, NULL }
-};
-
-static void SWIGUNUSED SWIG_CSharpSetPendingException(SWIG_CSharpExceptionCodes code, const char *msg) {
- SWIG_CSharpExceptionCallback_t callback = SWIG_csharp_exceptions[SWIG_CSharpApplicationException].callback;
- if ((size_t)code < sizeof(SWIG_csharp_exceptions)/sizeof(SWIG_CSharpException_t)) {
- callback = SWIG_csharp_exceptions[code].callback;
- }
- callback(msg);
-}
-
-static void SWIGUNUSED SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpExceptionArgumentCodes code, const char *msg, const char *param_name) {
- SWIG_CSharpExceptionArgumentCallback_t callback = SWIG_csharp_exceptions_argument[SWIG_CSharpArgumentException].callback;
- if ((size_t)code < sizeof(SWIG_csharp_exceptions_argument)/sizeof(SWIG_CSharpExceptionArgument_t)) {
- callback = SWIG_csharp_exceptions_argument[code].callback;
- }
- callback(msg, param_name);
-}
-
-
-#ifdef __cplusplus
-extern "C"
-#endif
-SWIGEXPORT void SWIGSTDCALL SWIGRegisterExceptionCallbacks_ESL(
- SWIG_CSharpExceptionCallback_t applicationCallback,
- SWIG_CSharpExceptionCallback_t arithmeticCallback,
- SWIG_CSharpExceptionCallback_t divideByZeroCallback,
- SWIG_CSharpExceptionCallback_t indexOutOfRangeCallback,
- SWIG_CSharpExceptionCallback_t invalidCastCallback,
- SWIG_CSharpExceptionCallback_t invalidOperationCallback,
- SWIG_CSharpExceptionCallback_t ioCallback,
- SWIG_CSharpExceptionCallback_t nullReferenceCallback,
- SWIG_CSharpExceptionCallback_t outOfMemoryCallback,
- SWIG_CSharpExceptionCallback_t overflowCallback,
- SWIG_CSharpExceptionCallback_t systemCallback) {
- SWIG_csharp_exceptions[SWIG_CSharpApplicationException].callback = applicationCallback;
- SWIG_csharp_exceptions[SWIG_CSharpArithmeticException].callback = arithmeticCallback;
- SWIG_csharp_exceptions[SWIG_CSharpDivideByZeroException].callback = divideByZeroCallback;
- SWIG_csharp_exceptions[SWIG_CSharpIndexOutOfRangeException].callback = indexOutOfRangeCallback;
- SWIG_csharp_exceptions[SWIG_CSharpInvalidCastException].callback = invalidCastCallback;
- SWIG_csharp_exceptions[SWIG_CSharpInvalidOperationException].callback = invalidOperationCallback;
- SWIG_csharp_exceptions[SWIG_CSharpIOException].callback = ioCallback;
- SWIG_csharp_exceptions[SWIG_CSharpNullReferenceException].callback = nullReferenceCallback;
- SWIG_csharp_exceptions[SWIG_CSharpOutOfMemoryException].callback = outOfMemoryCallback;
- SWIG_csharp_exceptions[SWIG_CSharpOverflowException].callback = overflowCallback;
- SWIG_csharp_exceptions[SWIG_CSharpSystemException].callback = systemCallback;
-}
-
-#ifdef __cplusplus
-extern "C"
-#endif
-SWIGEXPORT void SWIGSTDCALL SWIGRegisterExceptionArgumentCallbacks_ESL(
- SWIG_CSharpExceptionArgumentCallback_t argumentCallback,
- SWIG_CSharpExceptionArgumentCallback_t argumentNullCallback,
- SWIG_CSharpExceptionArgumentCallback_t argumentOutOfRangeCallback) {
- SWIG_csharp_exceptions_argument[SWIG_CSharpArgumentException].callback = argumentCallback;
- SWIG_csharp_exceptions_argument[SWIG_CSharpArgumentNullException].callback = argumentNullCallback;
- SWIG_csharp_exceptions_argument[SWIG_CSharpArgumentOutOfRangeException].callback = argumentOutOfRangeCallback;
-}
-
-
-/* Callback for returning strings to C# without leaking memory */
-typedef char * (SWIGSTDCALL* SWIG_CSharpStringHelperCallback)(const char *);
-static SWIG_CSharpStringHelperCallback SWIG_csharp_string_callback = NULL;
-
-
-#ifdef __cplusplus
-extern "C"
-#endif
-SWIGEXPORT void SWIGSTDCALL SWIGRegisterStringCallback_ESL(SWIG_CSharpStringHelperCallback callback) {
- SWIG_csharp_string_callback = callback;
-}
-
-
-/* Contract support */
-
-#define SWIG_contract_assert(nullreturn, expr, msg) if (!(expr)) {SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentOutOfRangeException, msg, ""); return nullreturn; } else
-
-
-#include "esl.h"
-#include "esl_oop.h"
-
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-SWIGEXPORT void SWIGSTDCALL CSharp_ESLevent_Event_set(void * jarg1, void * jarg2) {
- ESLevent *arg1 = (ESLevent *) 0 ;
- esl_event_t *arg2 = (esl_event_t *) 0 ;
-
- arg1 = (ESLevent *)jarg1;
- arg2 = (esl_event_t *)jarg2;
- if (arg1) (arg1)->event = arg2;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_ESLevent_Event_get(void * jarg1) {
- void * jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- esl_event_t *result = 0 ;
-
- arg1 = (ESLevent *)jarg1;
- result = (esl_event_t *) ((arg1)->event);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void SWIGSTDCALL CSharp_ESLevent_SerializedString_set(void * jarg1, char * jarg2) {
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *arg2 = (char *) 0 ;
-
- arg1 = (ESLevent *)jarg1;
- arg2 = (char *)jarg2;
- {
- if (arg1->serialized_string) delete [] arg1->serialized_string;
- if (arg2) {
- arg1->serialized_string = (char *) (new char[strlen((const char *)arg2)+1]);
- strcpy((char *)arg1->serialized_string, (const char *)arg2);
- } else {
- arg1->serialized_string = 0;
- }
- }
-}
-
-
-SWIGEXPORT char * SWIGSTDCALL CSharp_ESLevent_SerializedString_get(void * jarg1) {
- char * jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
-
- arg1 = (ESLevent *)jarg1;
- result = (char *) ((arg1)->serialized_string);
- jresult = SWIG_csharp_string_callback((const char *)result);
- return jresult;
-}
-
-
-SWIGEXPORT void SWIGSTDCALL CSharp_ESLevent_Mine_set(void * jarg1, int jarg2) {
- ESLevent *arg1 = (ESLevent *) 0 ;
- int arg2 ;
-
- arg1 = (ESLevent *)jarg1;
- arg2 = (int)jarg2;
- if (arg1) (arg1)->mine = arg2;
-}
-
-
-SWIGEXPORT int SWIGSTDCALL CSharp_ESLevent_Mine_get(void * jarg1) {
- int jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- int result;
-
- arg1 = (ESLevent *)jarg1;
- result = (int) ((arg1)->mine);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_new_ESLevent__SWIG_0(char * jarg1, char * jarg2) {
- void * jresult ;
- char *arg1 = (char *) 0 ;
- char *arg2 = (char *) NULL ;
- ESLevent *result = 0 ;
-
- arg1 = (char *)jarg1;
- arg2 = (char *)jarg2;
- result = (ESLevent *)new ESLevent((char const *)arg1,(char const *)arg2);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_new_ESLevent__SWIG_1(void * jarg1, int jarg2) {
- void * jresult ;
- esl_event_t *arg1 = (esl_event_t *) 0 ;
- int arg2 = (int) 0 ;
- ESLevent *result = 0 ;
-
- arg1 = (esl_event_t *)jarg1;
- arg2 = (int)jarg2;
- result = (ESLevent *)new ESLevent(arg1,arg2);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_new_ESLevent__SWIG_2(void * jarg1) {
- void * jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- ESLevent *result = 0 ;
-
- arg1 = (ESLevent *)jarg1;
- result = (ESLevent *)new ESLevent(arg1);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void SWIGSTDCALL CSharp_delete_ESLevent(void * jarg1) {
- ESLevent *arg1 = (ESLevent *) 0 ;
-
- arg1 = (ESLevent *)jarg1;
- delete arg1;
-}
-
-
-SWIGEXPORT char * SWIGSTDCALL CSharp_ESLevent_Serialize(void * jarg1, char * jarg2) {
- char * jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *arg2 = (char *) NULL ;
- char *result = 0 ;
-
- arg1 = (ESLevent *)jarg1;
- arg2 = (char *)jarg2;
- result = (char *)(arg1)->serialize((char const *)arg2);
- jresult = SWIG_csharp_string_callback((const char *)result);
- return jresult;
-}
-
-
-SWIGEXPORT unsigned int SWIGSTDCALL CSharp_ESLevent_SetPriority(void * jarg1, void * jarg2) {
- unsigned int jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- esl_priority_t arg2 = (esl_priority_t) ESL_PRIORITY_NORMAL ;
- esl_priority_t *argp2 ;
- bool result;
-
- arg1 = (ESLevent *)jarg1;
- argp2 = (esl_priority_t *)jarg2;
- if (!argp2) {
- SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentNullException, "Attempt to dereference null esl_priority_t", 0);
- return 0;
- }
- arg2 = *argp2;
- result = (bool)(arg1)->setPriority(arg2);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT char * SWIGSTDCALL CSharp_ESLevent_GetHeader(void * jarg1, char * jarg2, int jarg3) {
- char * jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *arg2 = (char *) 0 ;
- int arg3 = (int) -1 ;
- char *result = 0 ;
-
- arg1 = (ESLevent *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (int)jarg3;
- result = (char *)(arg1)->getHeader((char const *)arg2,arg3);
- jresult = SWIG_csharp_string_callback((const char *)result);
- return jresult;
-}
-
-
-SWIGEXPORT char * SWIGSTDCALL CSharp_ESLevent_GetBody(void * jarg1) {
- char * jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
-
- arg1 = (ESLevent *)jarg1;
- result = (char *)(arg1)->getBody();
- jresult = SWIG_csharp_string_callback((const char *)result);
- return jresult;
-}
-
-
-SWIGEXPORT char * SWIGSTDCALL CSharp_ESLevent_getType(void * jarg1) {
- char * jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
-
- arg1 = (ESLevent *)jarg1;
- result = (char *)(arg1)->getType();
- jresult = SWIG_csharp_string_callback((const char *)result);
- return jresult;
-}
-
-
-SWIGEXPORT unsigned int SWIGSTDCALL CSharp_ESLevent_AddBody(void * jarg1, char * jarg2) {
- unsigned int jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *arg2 = (char *) 0 ;
- bool result;
-
- arg1 = (ESLevent *)jarg1;
- arg2 = (char *)jarg2;
- result = (bool)(arg1)->addBody((char const *)arg2);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT unsigned int SWIGSTDCALL CSharp_ESLevent_AddHeader(void * jarg1, char * jarg2, char * jarg3) {
- unsigned int jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *arg2 = (char *) 0 ;
- char *arg3 = (char *) 0 ;
- bool result;
-
- arg1 = (ESLevent *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (char *)jarg3;
- result = (bool)(arg1)->addHeader((char const *)arg2,(char const *)arg3);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT unsigned int SWIGSTDCALL CSharp_ESLevent_pushHeader(void * jarg1, char * jarg2, char * jarg3) {
- unsigned int jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *arg2 = (char *) 0 ;
- char *arg3 = (char *) 0 ;
- bool result;
-
- arg1 = (ESLevent *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (char *)jarg3;
- result = (bool)(arg1)->pushHeader((char const *)arg2,(char const *)arg3);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT unsigned int SWIGSTDCALL CSharp_ESLevent_unshiftHeader(void * jarg1, char * jarg2, char * jarg3) {
- unsigned int jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *arg2 = (char *) 0 ;
- char *arg3 = (char *) 0 ;
- bool result;
-
- arg1 = (ESLevent *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (char *)jarg3;
- result = (bool)(arg1)->unshiftHeader((char const *)arg2,(char const *)arg3);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT unsigned int SWIGSTDCALL CSharp_ESLevent_DelHeader(void * jarg1, char * jarg2) {
- unsigned int jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *arg2 = (char *) 0 ;
- bool result;
-
- arg1 = (ESLevent *)jarg1;
- arg2 = (char *)jarg2;
- result = (bool)(arg1)->delHeader((char const *)arg2);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT char * SWIGSTDCALL CSharp_ESLevent_FirstHeader(void * jarg1) {
- char * jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
-
- arg1 = (ESLevent *)jarg1;
- result = (char *)(arg1)->firstHeader();
- jresult = SWIG_csharp_string_callback((const char *)result);
- return jresult;
-}
-
-
-SWIGEXPORT char * SWIGSTDCALL CSharp_ESLevent_NextHeader(void * jarg1) {
- char * jresult ;
- ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
-
- arg1 = (ESLevent *)jarg1;
- result = (char *)(arg1)->nextHeader();
- jresult = SWIG_csharp_string_callback((const char *)result);
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_new_ESLconnection__SWIG_0(char * jarg1, int jarg2, char * jarg3, char * jarg4) {
- void * jresult ;
- char *arg1 = (char *) 0 ;
- int arg2 ;
- char *arg3 = (char *) 0 ;
- char *arg4 = (char *) 0 ;
- ESLconnection *result = 0 ;
-
- arg1 = (char *)jarg1;
- arg2 = (int)jarg2;
- arg3 = (char *)jarg3;
- arg4 = (char *)jarg4;
- result = (ESLconnection *)new ESLconnection((char const *)arg1,arg2,(char const *)arg3,(char const *)arg4);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_new_ESLconnection__SWIG_1(char * jarg1, int jarg2, char * jarg3) {
- void * jresult ;
- char *arg1 = (char *) 0 ;
- int arg2 ;
- char *arg3 = (char *) 0 ;
- ESLconnection *result = 0 ;
-
- arg1 = (char *)jarg1;
- arg2 = (int)jarg2;
- arg3 = (char *)jarg3;
- result = (ESLconnection *)new ESLconnection((char const *)arg1,arg2,(char const *)arg3);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_new_ESLconnection__SWIG_2(char * jarg1, char * jarg2, char * jarg3, char * jarg4) {
- void * jresult ;
- char *arg1 = (char *) 0 ;
- char *arg2 = (char *) 0 ;
- char *arg3 = (char *) 0 ;
- char *arg4 = (char *) 0 ;
- ESLconnection *result = 0 ;
-
- arg1 = (char *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (char *)jarg3;
- arg4 = (char *)jarg4;
- result = (ESLconnection *)new ESLconnection((char const *)arg1,(char const *)arg2,(char const *)arg3,(char const *)arg4);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_new_ESLconnection__SWIG_3(char * jarg1, char * jarg2, char * jarg3) {
- void * jresult ;
- char *arg1 = (char *) 0 ;
- char *arg2 = (char *) 0 ;
- char *arg3 = (char *) 0 ;
- ESLconnection *result = 0 ;
-
- arg1 = (char *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (char *)jarg3;
- result = (ESLconnection *)new ESLconnection((char const *)arg1,(char const *)arg2,(char const *)arg3);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_new_ESLconnection__SWIG_4(int jarg1) {
- void * jresult ;
- int arg1 ;
- ESLconnection *result = 0 ;
-
- arg1 = (int)jarg1;
- result = (ESLconnection *)new ESLconnection(arg1);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void SWIGSTDCALL CSharp_delete_ESLconnection(void * jarg1) {
- ESLconnection *arg1 = (ESLconnection *) 0 ;
-
- arg1 = (ESLconnection *)jarg1;
- delete arg1;
-}
-
-
-SWIGEXPORT int SWIGSTDCALL CSharp_ESLconnection_SocketDescriptor(void * jarg1) {
- int jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- int result;
-
- arg1 = (ESLconnection *)jarg1;
- result = (int)(arg1)->socketDescriptor();
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT int SWIGSTDCALL CSharp_ESLconnection_Connected(void * jarg1) {
- int jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- int result;
-
- arg1 = (ESLconnection *)jarg1;
- result = (int)(arg1)->connected();
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_ESLconnection_GetInfo(void * jarg1) {
- void * jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- ESLevent *result = 0 ;
-
- arg1 = (ESLconnection *)jarg1;
- result = (ESLevent *)(arg1)->getInfo();
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT int SWIGSTDCALL CSharp_ESLconnection_Send(void * jarg1, char * jarg2) {
- int jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- char *arg2 = (char *) 0 ;
- int result;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (char *)jarg2;
- result = (int)(arg1)->send((char const *)arg2);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_ESLconnection_SendRecv(void * jarg1, char * jarg2) {
- void * jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- char *arg2 = (char *) 0 ;
- ESLevent *result = 0 ;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (char *)jarg2;
- result = (ESLevent *)(arg1)->sendRecv((char const *)arg2);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_ESLconnection_Api(void * jarg1, char * jarg2, char * jarg3) {
- void * jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- char *arg2 = (char *) 0 ;
- char *arg3 = (char *) NULL ;
- ESLevent *result = 0 ;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (char *)jarg3;
- result = (ESLevent *)(arg1)->api((char const *)arg2,(char const *)arg3);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_ESLconnection_Bgapi(void * jarg1, char * jarg2, char * jarg3, char * jarg4) {
- void * jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- char *arg2 = (char *) 0 ;
- char *arg3 = (char *) NULL ;
- char *arg4 = (char *) NULL ;
- ESLevent *result = 0 ;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (char *)jarg3;
- arg4 = (char *)jarg4;
- result = (ESLevent *)(arg1)->bgapi((char const *)arg2,(char const *)arg3,(char const *)arg4);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_ESLconnection_SendEvent(void * jarg1, void * jarg2) {
- void * jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- ESLevent *arg2 = (ESLevent *) 0 ;
- ESLevent *result = 0 ;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (ESLevent *)jarg2;
- result = (ESLevent *)(arg1)->sendEvent(arg2);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT int SWIGSTDCALL CSharp_ESLconnection_sendMSG(void * jarg1, void * jarg2, char * jarg3) {
- int jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- ESLevent *arg2 = (ESLevent *) 0 ;
- char *arg3 = (char *) NULL ;
- int result;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (ESLevent *)jarg2;
- arg3 = (char *)jarg3;
- result = (int)(arg1)->sendMSG(arg2,(char const *)arg3);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_ESLconnection_RecvEvent(void * jarg1) {
- void * jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- ESLevent *result = 0 ;
-
- arg1 = (ESLconnection *)jarg1;
- result = (ESLevent *)(arg1)->recvEvent();
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_ESLconnection_RecvEventTimed(void * jarg1, int jarg2) {
- void * jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- int arg2 ;
- ESLevent *result = 0 ;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (int)jarg2;
- result = (ESLevent *)(arg1)->recvEventTimed(arg2);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_ESLconnection_Filter(void * jarg1, char * jarg2, char * jarg3) {
- void * jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- char *arg2 = (char *) 0 ;
- char *arg3 = (char *) 0 ;
- ESLevent *result = 0 ;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (char *)jarg3;
- result = (ESLevent *)(arg1)->filter((char const *)arg2,(char const *)arg3);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT int SWIGSTDCALL CSharp_ESLconnection_Events(void * jarg1, char * jarg2, char * jarg3) {
- int jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- char *arg2 = (char *) 0 ;
- char *arg3 = (char *) 0 ;
- int result;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (char *)jarg3;
- result = (int)(arg1)->events((char const *)arg2,(char const *)arg3);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_ESLconnection_Execute(void * jarg1, char * jarg2, char * jarg3, char * jarg4) {
- void * jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- char *arg2 = (char *) 0 ;
- char *arg3 = (char *) NULL ;
- char *arg4 = (char *) NULL ;
- ESLevent *result = 0 ;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (char *)jarg3;
- arg4 = (char *)jarg4;
- result = (ESLevent *)(arg1)->execute((char const *)arg2,(char const *)arg3,(char const *)arg4);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT void * SWIGSTDCALL CSharp_ESLconnection_ExecuteAsync(void * jarg1, char * jarg2, char * jarg3, char * jarg4) {
- void * jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- char *arg2 = (char *) 0 ;
- char *arg3 = (char *) NULL ;
- char *arg4 = (char *) NULL ;
- ESLevent *result = 0 ;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (char *)jarg2;
- arg3 = (char *)jarg3;
- arg4 = (char *)jarg4;
- result = (ESLevent *)(arg1)->executeAsync((char const *)arg2,(char const *)arg3,(char const *)arg4);
- jresult = (void *)result;
- return jresult;
-}
-
-
-SWIGEXPORT int SWIGSTDCALL CSharp_ESLconnection_SetAsyncExecute(void * jarg1, char * jarg2) {
- int jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- char *arg2 = (char *) 0 ;
- int result;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (char *)jarg2;
- result = (int)(arg1)->setAsyncExecute((char const *)arg2);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT int SWIGSTDCALL CSharp_ESLconnection_SetEventLock(void * jarg1, char * jarg2) {
- int jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- char *arg2 = (char *) 0 ;
- int result;
-
- arg1 = (ESLconnection *)jarg1;
- arg2 = (char *)jarg2;
- result = (int)(arg1)->setEventLock((char const *)arg2);
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT int SWIGSTDCALL CSharp_ESLconnection_Disconnect(void * jarg1) {
- int jresult ;
- ESLconnection *arg1 = (ESLconnection *) 0 ;
- int result;
-
- arg1 = (ESLconnection *)jarg1;
- result = (int)(arg1)->disconnect();
- jresult = result;
- return jresult;
-}
-
-
-SWIGEXPORT void SWIGSTDCALL CSharp_eslSetLogLevel(int jarg1) {
- int arg1 ;
-
- arg1 = (int)jarg1;
- eslSetLogLevel(arg1);
-}
-
-
-#ifdef __cplusplus
-}
-#endif
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
- *
- * This file is not intended to be easily readable and contains a number of
+ * Version 2.0.12
+ *
+ * This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
- * changes to this file unless you know what you are doing--modify the SWIG
- * interface file instead.
+ * changes to this file unless you know what you are doing--modify the SWIG
+ * interface file instead.
* ----------------------------------------------------------------------------- */
+#define SWIGCSHARP
+
#ifdef __cplusplus
+/* SwigValueWrapper is described in swig.swg */
template<typename T> class SwigValueWrapper {
- T *tt;
+ struct SwigMovePointer {
+ T *ptr;
+ SwigMovePointer(T *p) : ptr(p) { }
+ ~SwigMovePointer() { delete ptr; }
+ SwigMovePointer& operator=(SwigMovePointer& rhs) { T* oldptr = ptr; ptr = 0; delete oldptr; ptr = rhs.ptr; rhs.ptr = 0; return *this; }
+ } pointer;
+ SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
+ SwigValueWrapper(const SwigValueWrapper<T>& rhs);
public:
- SwigValueWrapper() : tt(0) { }
- SwigValueWrapper(const SwigValueWrapper<T>& rhs) : tt(new T(*rhs.tt)) { }
- SwigValueWrapper(const T& t) : tt(new T(t)) { }
- ~SwigValueWrapper() { delete tt; }
- SwigValueWrapper& operator=(const T& t) { delete tt; tt = new T(t); return *this; }
- operator T&() const { return *tt; }
- T *operator&() { return tt; }
-private:
- SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
+ SwigValueWrapper() : pointer(0) { }
+ SwigValueWrapper& operator=(const T& t) { SwigMovePointer tmp(new T(t)); pointer = tmp; return *this; }
+ operator T&() const { return *pointer.ptr; }
+ T *operator&() { return pointer.ptr; }
};
template <typename T> T SwigValueInit() {
#ifndef SWIGUNUSED
# if defined(__GNUC__)
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
# elif defined(__ICC)
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
-# define SWIGUNUSED
+# define SWIGUNUSED
+# endif
+#endif
+
+#ifndef SWIG_MSC_UNSUPPRESS_4505
+# if defined(_MSC_VER)
+# pragma warning(disable : 4505) /* unreferenced local function has been removed */
# endif
#endif
# ifdef __cplusplus
# define SWIGUNUSEDPARM(p)
# else
-# define SWIGUNUSEDPARM(p) p SWIGUNUSED
+# define SWIGUNUSEDPARM(p) p SWIGUNUSED
# endif
#endif
# define SWIGSTDCALL __stdcall
# else
# define SWIGSTDCALL
-# endif
+# endif
#endif
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
static SWIG_CSharpExceptionArgument_t SWIG_csharp_exceptions_argument[] = {
{ SWIG_CSharpArgumentException, NULL },
{ SWIG_CSharpArgumentNullException, NULL },
- { SWIG_CSharpArgumentOutOfRangeException, NULL },
+ { SWIG_CSharpArgumentOutOfRangeException, NULL }
};
static void SWIGUNUSED SWIG_CSharpSetPendingException(SWIG_CSharpExceptionCodes code, const char *msg) {
SWIG_CSharpExceptionCallback_t callback = SWIG_csharp_exceptions[SWIG_CSharpApplicationException].callback;
- if (code >=0 && (size_t)code < sizeof(SWIG_csharp_exceptions)/sizeof(SWIG_CSharpException_t)) {
+ if ((size_t)code < sizeof(SWIG_csharp_exceptions)/sizeof(SWIG_CSharpException_t)) {
callback = SWIG_csharp_exceptions[code].callback;
}
callback(msg);
static void SWIGUNUSED SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpExceptionArgumentCodes code, const char *msg, const char *param_name) {
SWIG_CSharpExceptionArgumentCallback_t callback = SWIG_csharp_exceptions_argument[SWIG_CSharpArgumentException].callback;
- if (code >=0 && (size_t)code < sizeof(SWIG_csharp_exceptions_argument)/sizeof(SWIG_CSharpExceptionArgument_t)) {
+ if ((size_t)code < sizeof(SWIG_csharp_exceptions_argument)/sizeof(SWIG_CSharpExceptionArgument_t)) {
callback = SWIG_csharp_exceptions_argument[code].callback;
}
callback(msg, param_name);
arg1 = (ESLevent *)jarg1;
arg2 = (esl_event_t *)jarg2;
if (arg1) (arg1)->event = arg2;
-
}
arg1 = (ESLevent *)jarg1;
arg2 = (char *)jarg2;
{
- if (arg1->serialized_string) delete [] arg1->serialized_string;
+ delete [] arg1->serialized_string;
if (arg2) {
arg1->serialized_string = (char *) (new char[strlen((const char *)arg2)+1]);
strcpy((char *)arg1->serialized_string, (const char *)arg2);
arg1 = (ESLevent *)jarg1;
arg2 = (int)jarg2;
if (arg1) (arg1)->mine = arg2;
-
}
arg1 = (ESLevent *)jarg1;
delete arg1;
-
}
unsigned int jresult ;
ESLevent *arg1 = (ESLevent *) 0 ;
esl_priority_t arg2 = (esl_priority_t) ESL_PRIORITY_NORMAL ;
- bool result;
esl_priority_t *argp2 ;
+ bool result;
arg1 = (ESLevent *)jarg1;
argp2 = (esl_priority_t *)jarg2;
arg1 = (ESLconnection *)jarg1;
delete arg1;
-
}
# This file was automatically generated by SWIG (http://www.swig.org).
-# Version 1.3.35
+# Version 2.0.12
#
-# Don't modify this file, modify the SWIG interface instead.
+# Do not make changes to this file unless you know what you are doing--modify
+# the SWIG interface file instead.
package ESL;
-require Exporter;
-require DynaLoader;
-@ISA = qw(Exporter DynaLoader);
+use base qw(Exporter);
+use base qw(DynaLoader);
package ESLc;
bootstrap ESL;
package ESL;
-@EXPORT = qw( );
+@EXPORT = qw();
# ---------- BASE METHODS -------------
endif
esl_wrap.cpp:
- swig -module ESL -shadow -perl5 -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
+ swig2.0 -module ESL -shadow -perl5 -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
perlxsi.c:
$(PERL) -MExtUtils::Embed -e xsinit -- -o perlxsi.c
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
- *
- * This file is not intended to be easily readable and contains a number of
+ * Version 2.0.12
+ *
+ * This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
- * changes to this file unless you know what you are doing--modify the SWIG
- * interface file instead.
+ * changes to this file unless you know what you are doing--modify the SWIG
+ * interface file instead.
* ----------------------------------------------------------------------------- */
#define SWIGPERL
#define SWIG_CASTRANK_MODE
+
#ifdef __cplusplus
+/* SwigValueWrapper is described in swig.swg */
template<typename T> class SwigValueWrapper {
- T *tt;
+ struct SwigMovePointer {
+ T *ptr;
+ SwigMovePointer(T *p) : ptr(p) { }
+ ~SwigMovePointer() { delete ptr; }
+ SwigMovePointer& operator=(SwigMovePointer& rhs) { T* oldptr = ptr; ptr = 0; delete oldptr; ptr = rhs.ptr; rhs.ptr = 0; return *this; }
+ } pointer;
+ SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
+ SwigValueWrapper(const SwigValueWrapper<T>& rhs);
public:
- SwigValueWrapper() : tt(0) { }
- SwigValueWrapper(const SwigValueWrapper<T>& rhs) : tt(new T(*rhs.tt)) { }
- SwigValueWrapper(const T& t) : tt(new T(t)) { }
- ~SwigValueWrapper() { delete tt; }
- SwigValueWrapper& operator=(const T& t) { delete tt; tt = new T(t); return *this; }
- operator T&() const { return *tt; }
- T *operator&() { return tt; }
-private:
- SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
+ SwigValueWrapper() : pointer(0) { }
+ SwigValueWrapper& operator=(const T& t) { SwigMovePointer tmp(new T(t)); pointer = tmp; return *this; }
+ operator T&() const { return *pointer.ptr; }
+ T *operator&() { return pointer.ptr; }
};
template <typename T> T SwigValueInit() {
#ifndef SWIGUNUSED
# if defined(__GNUC__)
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
# elif defined(__ICC)
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
-# define SWIGUNUSED
+# define SWIGUNUSED
+# endif
+#endif
+
+#ifndef SWIG_MSC_UNSUPPRESS_4505
+# if defined(_MSC_VER)
+# pragma warning(disable : 4505) /* unreferenced local function has been removed */
# endif
#endif
# ifdef __cplusplus
# define SWIGUNUSEDPARM(p)
# else
-# define SWIGUNUSEDPARM(p) p SWIGUNUSED
+# define SWIGUNUSEDPARM(p) p SWIGUNUSED
# endif
#endif
# define SWIGSTDCALL __stdcall
# else
# define SWIGSTDCALL
-# endif
+# endif
#endif
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
/* -----------------------------------------------------------------------------
* swigrun.swg
*
- * This file contains generic CAPI SWIG runtime support for pointer
+ * This file contains generic C API SWIG runtime support for pointer
* type checking.
* ----------------------------------------------------------------------------- */
/*
You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
- creating a static or dynamic library from the swig runtime code.
- In 99.9% of the cases, swig just needs to declare them as 'static'.
-
- But only do this if is strictly necessary, ie, if you have problems
- with your compiler or so.
+ creating a static or dynamic library from the SWIG runtime code.
+ In 99.9% of the cases, SWIG just needs to declare them as 'static'.
+
+ But only do this if strictly necessary, ie, if you have problems
+ with your compiler or suchlike.
*/
#ifndef SWIGRUNTIME
#define SWIG_POINTER_OWN 0x1
-/*
+/*
Flags/methods for returning states.
-
- The swig conversion methods, as ConvertPtr, return and integer
+
+ The SWIG conversion methods, as ConvertPtr, return an integer
that tells if the conversion was successful or not. And if not,
an error code can be returned (see swigerrors.swg for the codes).
-
+
Use the following macros/flags to set or process the returning
states.
-
- In old swig versions, you usually write code as:
+
+ In old versions of SWIG, code such as the following was usually written:
if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
// success code
//fail code
}
- Now you can be more explicit as:
+ Now you can be more explicit:
int res = SWIG_ConvertPtr(obj,vptr,ty.flags);
if (SWIG_IsOK(res)) {
// fail code
}
- that seems to be the same, but now you can also do
+ which is the same really, but now you can also do
Type *ptr;
int res = SWIG_ConvertPtr(obj,(void **)(&ptr),ty.flags);
} else {
// fail code
}
-
+
I.e., now SWIG_ConvertPtr can return new objects and you can
identify the case and take care of the deallocation. Of course that
- requires also to SWIG_ConvertPtr to return new result values, as
-
- int SWIG_ConvertPtr(obj, ptr,...) {
- if (<obj is ok>) {
- if (<need new object>) {
- *ptr = <ptr to new allocated object>;
- return SWIG_NEWOBJ;
- } else {
- *ptr = <ptr to old object>;
- return SWIG_OLDOBJ;
- }
- } else {
- return SWIG_BADOBJ;
- }
+ also requires SWIG_ConvertPtr to return new result values, such as
+
+ int SWIG_ConvertPtr(obj, ptr,...) {
+ if (<obj is ok>) {
+ if (<need new object>) {
+ *ptr = <ptr to new allocated object>;
+ return SWIG_NEWOBJ;
+ } else {
+ *ptr = <ptr to old object>;
+ return SWIG_OLDOBJ;
+ }
+ } else {
+ return SWIG_BADOBJ;
+ }
}
Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
more explicit by returning SWIG_BADOBJ, SWIG_ERROR or any of the
- swig errors code.
+ SWIG errors code.
Finally, if the SWIG_CASTRANK_MODE is enabled, the result code
allows to return the 'cast rank', for example, if you have this
int fooi(int);
and you call
-
+
food(1) // cast rank '1' (1 -> 1.0)
fooi(1) // cast rank '0'
just use the SWIG_AddCast()/SWIG_CheckState()
+*/
-
- */
-#define SWIG_OK (0)
+#define SWIG_OK (0)
#define SWIG_ERROR (-1)
#define SWIG_IsOK(r) (r >= 0)
-#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
+#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
/* The CastRankLimit says how many bits are used for the cast rank */
#define SWIG_CASTRANKLIMIT (1 << 8)
#define SWIG_DelTmpMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_TMPOBJMASK) : r)
#define SWIG_IsTmpObj(r) (SWIG_IsOK(r) && (r & SWIG_TMPOBJMASK))
-
/* Cast-Rank Mode */
#if defined(SWIG_CASTRANK_MODE)
# ifndef SWIG_TypeRank
# endif
# define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
# define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
-SWIGINTERNINLINE int SWIG_AddCast(int r) {
+SWIGINTERNINLINE int SWIG_AddCast(int r) {
return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
}
-SWIGINTERNINLINE int SWIG_CheckState(int r) {
- return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
+SWIGINTERNINLINE int SWIG_CheckState(int r) {
+ return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
}
#else /* no cast-rank mode */
-# define SWIG_AddCast
+# define SWIG_AddCast(r) (r)
# define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
#endif
-
-
#include <string.h>
#ifdef __cplusplus
void *clientdata; /* Language specific module data */
} swig_module_info;
-/*
+/*
Compare two type names skipping the space characters, therefore
"char*" == "char *" and "Class<int>" == "Class<int >", etc.
/*
Check type equivalence in a name list like <name1>|<name2>|...
- Return 0 if not equal, 1 if equal
+ Return 0 if equal, -1 if nb < tb, 1 if nb > tb
*/
SWIGRUNTIME int
-SWIG_TypeEquiv(const char *nb, const char *tb) {
- int equiv = 0;
+SWIG_TypeCmp(const char *nb, const char *tb) {
+ int equiv = 1;
const char* te = tb + strlen(tb);
const char* ne = nb;
- while (!equiv && *ne) {
+ while (equiv != 0 && *ne) {
for (nb = ne; *ne; ++ne) {
if (*ne == '|') break;
}
- equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
+ equiv = SWIG_TypeNameComp(nb, ne, tb, te);
if (*ne) ++ne;
}
return equiv;
/*
Check type equivalence in a name list like <name1>|<name2>|...
- Return 0 if equal, -1 if nb < tb, 1 if nb > tb
+ Return 0 if not equal, 1 if equal
*/
SWIGRUNTIME int
-SWIG_TypeCompare(const char *nb, const char *tb) {
- int equiv = 0;
- const char* te = tb + strlen(tb);
- const char* ne = nb;
- while (!equiv && *ne) {
- for (nb = ne; *ne; ++ne) {
- if (*ne == '|') break;
- }
- equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
- if (*ne) ++ne;
- }
- return equiv;
+SWIG_TypeEquiv(const char *nb, const char *tb) {
+ return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
}
-
-/* think of this as a c++ template<> or a scheme macro */
-#define SWIG_TypeCheck_Template(comparison, ty) \
- if (ty) { \
- swig_cast_info *iter = ty->cast; \
- while (iter) { \
- if (comparison) { \
- if (iter == ty->cast) return iter; \
- /* Move iter to the top of the linked list */ \
- iter->prev->next = iter->next; \
- if (iter->next) \
- iter->next->prev = iter->prev; \
- iter->next = ty->cast; \
- iter->prev = 0; \
- if (ty->cast) ty->cast->prev = iter; \
- ty->cast = iter; \
- return iter; \
- } \
- iter = iter->next; \
- } \
- } \
- return 0
-
/*
Check the typename
*/
SWIGRUNTIME swig_cast_info *
SWIG_TypeCheck(const char *c, swig_type_info *ty) {
- SWIG_TypeCheck_Template(strcmp(iter->type->name, c) == 0, ty);
+ if (ty) {
+ swig_cast_info *iter = ty->cast;
+ while (iter) {
+ if (strcmp(iter->type->name, c) == 0) {
+ if (iter == ty->cast)
+ return iter;
+ /* Move iter to the top of the linked list */
+ iter->prev->next = iter->next;
+ if (iter->next)
+ iter->next->prev = iter->prev;
+ iter->next = ty->cast;
+ iter->prev = 0;
+ if (ty->cast) ty->cast->prev = iter;
+ ty->cast = iter;
+ return iter;
+ }
+ iter = iter->next;
+ }
+ }
+ return 0;
}
-/* Same as previous function, except strcmp is replaced with a pointer comparison */
+/*
+ Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
+*/
SWIGRUNTIME swig_cast_info *
-SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *into) {
- SWIG_TypeCheck_Template(iter->type == from, into);
+SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *ty) {
+ if (ty) {
+ swig_cast_info *iter = ty->cast;
+ while (iter) {
+ if (iter->type == from) {
+ if (iter == ty->cast)
+ return iter;
+ /* Move iter to the top of the linked list */
+ iter->prev->next = iter->next;
+ if (iter->next)
+ iter->next->prev = iter->prev;
+ iter->next = ty->cast;
+ iter->prev = 0;
+ if (ty->cast) ty->cast->prev = iter;
+ ty->cast = iter;
+ return iter;
+ }
+ iter = iter->next;
+ }
+ }
+ return 0;
}
/*
return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
}
-/*
+/*
Dynamic pointer casting. Down an inheritance hierarchy
*/
SWIGRUNTIME swig_type_info *
return type->name;
}
-/*
+/*
Set the clientdata field for a type
*/
SWIGRUNTIME void
swig_cast_info *cast = ti->cast;
/* if (ti->clientdata == clientdata) return; */
ti->clientdata = clientdata;
-
+
while (cast) {
if (!cast->converter) {
swig_type_info *tc = cast->type;
if (!tc->clientdata) {
SWIG_TypeClientData(tc, clientdata);
}
- }
+ }
cast = cast->next;
}
}
SWIG_TypeClientData(ti, clientdata);
ti->owndata = 1;
}
-
+
/*
Search for a swig_type_info structure only by mangled name
Search is a O(log #types)
-
- We start searching at module start, and finish searching when start == end.
+
+ We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
-SWIG_MangledTypeQueryModule(swig_module_info *start,
- swig_module_info *end,
+SWIG_MangledTypeQueryModule(swig_module_info *start,
+ swig_module_info *end,
const char *name) {
swig_module_info *iter = start;
do {
register size_t r = iter->size - 1;
do {
/* since l+r >= 0, we can (>> 1) instead (/ 2) */
- register size_t i = (l + r) >> 1;
+ register size_t i = (l + r) >> 1;
const char *iname = iter->types[i]->name;
if (iname) {
register int compare = strcmp(name, iname);
- if (compare == 0) {
+ if (compare == 0) {
return iter->types[i];
} else if (compare < 0) {
if (i) {
Search for a swig_type_info structure for either a mangled name or a human readable name.
It first searches the mangled names of the types, which is a O(log #types)
If a type is not found it then searches the human readable names, which is O(#types).
-
- We start searching at module start, and finish searching when start == end.
+
+ We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
-SWIG_TypeQueryModule(swig_module_info *start,
- swig_module_info *end,
+SWIG_TypeQueryModule(swig_module_info *start,
+ swig_module_info *end,
const char *name) {
/* STEP 1: Search the name field using binary search */
swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
iter = iter->next;
} while (iter != end);
}
-
+
/* neither found a match */
return 0;
}
-/*
+/*
Pack binary data into a string
*/
SWIGRUNTIME char *
return c;
}
-/*
+/*
Unpack binary data from a string
*/
SWIGRUNTIME const char *
uu = ((d - '0') << 4);
else if ((d >= 'a') && (d <= 'f'))
uu = ((d - ('a'-10)) << 4);
- else
+ else
return (char *) 0;
d = *(c++);
if ((d >= '0') && (d <= '9'))
uu |= (d - '0');
else if ((d >= 'a') && (d <= 'f'))
uu |= (d - ('a'-10));
- else
+ else
return (char *) 0;
*u = uu;
}
return c;
}
-/*
+/*
Pack 'void *' into a string buffer.
*/
SWIGRUNTIME char *
#endif
/* Errors in SWIG */
-#define SWIG_UnknownError -1
-#define SWIG_IOError -2
-#define SWIG_RuntimeError -3
-#define SWIG_IndexError -4
-#define SWIG_TypeError -5
-#define SWIG_DivisionByZero -6
-#define SWIG_OverflowError -7
-#define SWIG_SyntaxError -8
-#define SWIG_ValueError -9
+#define SWIG_UnknownError -1
+#define SWIG_IOError -2
+#define SWIG_RuntimeError -3
+#define SWIG_IndexError -4
+#define SWIG_TypeError -5
+#define SWIG_DivisionByZero -6
+#define SWIG_OverflowError -7
+#define SWIG_SyntaxError -8
+#define SWIG_ValueError -9
#define SWIG_SystemError -10
#define SWIG_AttributeError -11
-#define SWIG_MemoryError -12
+#define SWIG_MemoryError -12
#define SWIG_NullReferenceError -13
SWIGINTERN const char*
SWIG_Perl_ErrorType(int code) {
- const char* type = 0;
switch(code) {
case SWIG_MemoryError:
- type = "MemoryError";
- break;
+ return "MemoryError";
case SWIG_IOError:
- type = "IOError";
- break;
+ return "IOError";
case SWIG_RuntimeError:
- type = "RuntimeError";
- break;
+ return "RuntimeError";
case SWIG_IndexError:
- type = "IndexError";
- break;
+ return "IndexError";
case SWIG_TypeError:
- type = "TypeError";
- break;
+ return "TypeError";
case SWIG_DivisionByZero:
- type = "ZeroDivisionError";
- break;
+ return "ZeroDivisionError";
case SWIG_OverflowError:
- type = "OverflowError";
- break;
+ return "OverflowError";
case SWIG_SyntaxError:
- type = "SyntaxError";
- break;
+ return "SyntaxError";
case SWIG_ValueError:
- type = "ValueError";
- break;
+ return "ValueError";
case SWIG_SystemError:
- type = "SystemError";
- break;
+ return "SystemError";
case SWIG_AttributeError:
- type = "AttributeError";
- break;
+ return "AttributeError";
default:
- type = "RuntimeError";
+ return "RuntimeError";
}
- return type;
}
-
-
/* -----------------------------------------------------------------------------
* perlrun.swg
*
/* for raw pointers */
#define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags)
+#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own)
#define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags)
/* for raw packed data */
/* Runtime API */
-#define SWIG_GetModule(clientdata) SWIG_Perl_GetModule()
+#define SWIG_GetModule(clientdata) SWIG_Perl_GetModule(clientdata)
#define SWIG_SetModule(clientdata, pointer) SWIG_Perl_SetModule(pointer)
/* Error manipulation */
#define SWIG_ErrorType(code) SWIG_Perl_ErrorType(code)
-#define SWIG_Error(code, msg) sv_setpvf(GvSV(PL_errgv),"%s %s\n", SWIG_ErrorType(code), msg)
+#define SWIG_Error(code, msg) sv_setpvf(get_sv("@", GV_ADD), "%s %s", SWIG_ErrorType(code), msg)
#define SWIG_fail goto fail
/* Perl-specific SWIG API */
#endif /* MULTIPLICITY */
#endif /* PERL_OBJECT */
-/* Workaround for bug in perl 5.6.x croak and earlier */
-#if (PERL_VERSION < 8)
# ifdef PERL_OBJECT
# define SWIG_croak_null() SWIG_Perl_croak_null(pPerl)
static void SWIG_Perl_croak_null(CPerlObj *pPerl)
static void SWIG_croak_null()
# endif
{
- SV *err=ERRSV;
+ SV *err = get_sv("@", GV_ADD);
# if (PERL_VERSION < 6)
croak("%_", err);
# else
- if (SvOK(err) && !SvROK(err)) croak("%_", err);
- croak(Nullch);
+ if (sv_isobject(err))
+ croak(0);
+ else
+ croak("%s", SvPV_nolen(err));
# endif
}
-#else
-# define SWIG_croak_null() croak(Nullch)
-#endif
/*
}
}
+/* Identical to SWIG_TypeCheck, except for strcmp comparison */
SWIGRUNTIME swig_cast_info *
SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) {
- SWIG_TypeCheck_Template(( (!iter->type->clientdata && (strcmp(iter->type->name, c) == 0))
- || (iter->type->clientdata && (strcmp((char*)iter->type->clientdata, c) == 0))), ty);
+ if (ty) {
+ swig_cast_info *iter = ty->cast;
+ while (iter) {
+ if (strcmp(SWIG_Perl_TypeProxyName(iter->type), c) == 0) {
+ if (iter == ty->cast)
+ return iter;
+ /* Move iter to the top of the linked list */
+ iter->prev->next = iter->next;
+ if (iter->next)
+ iter->next->prev = iter->prev;
+ iter->next = ty->cast;
+ iter->prev = 0;
+ if (ty->cast) ty->cast->prev = iter;
+ ty->cast = iter;
+ return iter;
+ }
+ iter = iter->next;
+ }
+ }
+ return 0;
}
-
/* Function for getting a pointer value */
SWIGRUNTIME int
-SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) {
+SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) {
swig_cast_info *tc;
void *voidptr = (void *)0;
SV *tsv = 0;
+
+ if (own)
+ *own = 0;
+
/* If magical, apply more magic */
if (SvGMAGICAL(sv))
mg_get(sv);
return SWIG_OK;
} else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */
if (!SvROK(sv)) {
- *(ptr) = (void *) 0;
- return SWIG_OK;
+ /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */
+ if (SvIOK(sv)) {
+ return SWIG_ERROR;
+ } else {
+ /* NULL pointer (reference to undef). */
+ *(ptr) = (void *) 0;
+ return SWIG_OK;
+ }
} else {
return SWIG_ERROR;
}
{
int newmemory = 0;
*ptr = SWIG_TypeCast(tc,voidptr,&newmemory);
- assert(!newmemory); /* newmemory handling not yet implemented */
+ if (newmemory == SWIG_CAST_NEW_MEMORY) {
+ assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */
+ if (own)
+ *own = *own | SWIG_CAST_NEW_MEMORY;
+ }
}
} else {
*ptr = voidptr;
*/
SV *obj = sv;
HV *stash = SvSTASH(SvRV(obj));
- GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE);
+ GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE);
if (isGV(gv)) {
HV *hv = GvHVn(gv);
/*
return SWIG_OK;
}
+SWIGRUNTIME int
+SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) {
+ return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0);
+}
+
SWIGRUNTIME void
SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) {
- if (ptr && (flags & SWIG_SHADOW)) {
+ if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) {
SV *self;
SV *obj=newSV(0);
HV *hash=newHV();
HV *stash;
- sv_setref_pv(obj, (char *) SWIG_Perl_TypeProxyName(t), ptr);
+ sv_setref_pv(obj, SWIG_Perl_TypeProxyName(t), ptr);
stash=SvSTASH(SvRV(obj));
if (flags & SWIG_POINTER_OWN) {
HV *hv;
- GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE);
+ GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE);
if (!isGV(gv))
gv_init(gv, stash, "OWNER", 5, FALSE);
hv=GvHVn(gv);
sv_bless(sv, stash);
}
else {
- sv_setref_pv(sv, (char *) SWIG_Perl_TypeProxyName(t), ptr);
+ sv_setref_pv(sv, SWIG_Perl_TypeProxyName(t), ptr);
}
}
/* Magic variable code */
#ifndef PERL_OBJECT
-#define swig_create_magic(s,a,b,c) _swig_create_magic(s,a,b,c)
- #ifndef MULTIPLICITY
- SWIGRUNTIME void _swig_create_magic(SV *sv, char *name, int (*set)(SV *, MAGIC *), int (*get)(SV *,MAGIC *))
- #else
- SWIGRUNTIME void _swig_create_magic(SV *sv, char *name, int (*set)(struct interpreter*, SV *, MAGIC *), int (*get)(struct interpreter*, SV *,MAGIC *))
- #endif
+# ifdef __cplusplus
+# define swig_create_magic(s,a,b,c) _swig_create_magic(s,const_cast<char*>(a),b,c)
+# else
+# define swig_create_magic(s,a,b,c) _swig_create_magic(s,(char*)(a),b,c)
+# endif
+# ifndef MULTIPLICITY
+SWIGRUNTIME void _swig_create_magic(SV *sv, char *name, int (*set)(SV *, MAGIC *), int (*get)(SV *,MAGIC *))
+# else
+SWIGRUNTIME void _swig_create_magic(SV *sv, char *name, int (*set)(struct interpreter*, SV *, MAGIC *), int (*get)(struct interpreter*, SV *,MAGIC *))
+# endif
#else
# define swig_create_magic(s,a,b,c) _swig_create_magic(pPerl,s,a,b,c)
SWIGRUNTIME void _swig_create_magic(CPerlObj *pPerl, SV *sv, const char *name, int (CPerlObj::*set)(SV *, MAGIC *), int (CPerlObj::*get)(SV *, MAGIC *))
#endif
{
MAGIC *mg;
- sv_magic(sv,sv,'U',(char *) name,strlen(name));
+ sv_magic(sv,sv,'U',name,strlen(name));
mg = mg_find(sv,'U');
mg->mg_virtual = (MGVTBL *) malloc(sizeof(MGVTBL));
mg->mg_virtual->svt_get = (SwigMagicFunc) get;
SWIGRUNTIME swig_module_info *
-SWIG_Perl_GetModule(void) {
+SWIG_Perl_GetModule(void *SWIGUNUSEDPARM(clientdata)) {
static void *type_pointer = (void *)0;
SV *pointer;
#ifdef do_close
#undef do_close
#endif
+#ifdef do_exec
+ #undef do_exec
+#endif
#ifdef scalar
#undef scalar
#endif
#ifdef eof
#undef eof
#endif
-#ifdef bool
- #undef bool
-#endif
#ifdef close
#undef close
#endif
#ifdef open
#undef open
#endif
+#ifdef readdir
+ #undef readdir
+#endif
+#ifdef bind
+ #undef bind
+#endif
+#ifdef access
+ #undef access
+#endif
+#ifdef stat
+ #undef stat
+#endif
+
+#ifdef bool
+ /* Leave if macro is from C99 stdbool.h */
+ #ifndef __bool_true_false_are_defined
+ #undef bool
+ #endif
+#endif
+
#define SWIG_name "ESLc::boot_ESL"
#define SWIG_prefix "ESLc::"
-#define SWIGVERSION 0x010335
+#define SWIGVERSION 0x020012
#define SWIG_VERSION SWIGVERSION
SWIGINTERN int
SWIG_AsCharPtrAndSize(SV *obj, char** cptr, size_t* psize, int *alloc)
{
+ if (SvMAGICAL(obj)) {
+ SV *tmp = sv_newmortal();
+ SvSetSV(tmp, obj);
+ obj = tmp;
+ }
if (SvPOK(obj)) {
STRLEN len = 0;
char *cstr = SvPV(obj, len);
const char *nptr = SvPV_nolen(obj);
if (nptr) {
char *endptr;
- double v = strtod(nptr, &endptr);
+ double v;
+ errno = 0;
+ v = strtod(nptr, &endptr);
if (errno == ERANGE) {
errno = 0;
return SWIG_OverflowError;
SWIGINTERN int
SWIG_AsVal_long SWIG_PERL_DECL_ARGS_2(SV *obj, long* val)
{
- if (SvIOK(obj)) {
- if (val) *val = SvIV(obj);
- return SWIG_OK;
+ if (SvUOK(obj)) {
+ UV v = SvUV(obj);
+ if (v <= LONG_MAX) {
+ if (val) *val = v;
+ return SWIG_OK;
+ }
+ return SWIG_OverflowError;
+ } else if (SvIOK(obj)) {
+ IV v = SvIV(obj);
+ if (v >= LONG_MIN && v <= LONG_MAX) {
+ if(val) *val = v;
+ return SWIG_OK;
+ }
+ return SWIG_OverflowError;
} else {
int dispatch = 0;
const char *nptr = SvPV_nolen(obj);
SWIGINTERNINLINE SV *
SWIG_From_long SWIG_PERL_DECL_ARGS_1(long value)
-{
- SV *obj = sv_newmortal();
- sv_setiv(obj, (IV) value);
- return obj;
+{
+ SV *sv;
+ if (value >= IV_MIN && value <= IV_MAX)
+ sv = newSViv(value);
+ else
+ sv = newSVpvf("%ld", value);
+ return sv_2mortal(sv);
}
SWIGINTERNINLINE SV *
SWIG_From_bool SWIG_PERL_DECL_ARGS_1(bool value)
-{
- SV *obj = sv_newmortal();
- if (value) {
- sv_setsv(obj, &PL_sv_yes);
- } else {
- sv_setsv(obj, &PL_sv_no);
- }
- return obj;
+{
+ return boolSV(value);
}
#ifdef __cplusplus
}
arg2 = reinterpret_cast< esl_event_t * >(argp2);
if (arg1) (arg1)->event = arg2;
-
-
+ ST(argvi) = sv_newmortal();
XSRETURN(argvi);
XS(_wrap_ESLevent_event_get) {
{
ESLevent *arg1 = (ESLevent *) 0 ;
- esl_event_t *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ esl_event_t *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 1)) {
} else {
arg1->serialized_string = 0;
}
-
+ ST(argvi) = sv_newmortal();
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
XSRETURN(argvi);
XS(_wrap_ESLevent_serialized_string_get) {
{
ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ char *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 1)) {
}
arg2 = static_cast< int >(val2);
if (arg1) (arg1)->mine = arg2;
-
-
+ ST(argvi) = sv_newmortal();
XSRETURN(argvi);
XS(_wrap_ESLevent_mine_get) {
{
ESLevent *arg1 = (ESLevent *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ int result;
dXSARGS;
if ((items < 1) || (items > 1)) {
{
char *arg1 = (char *) 0 ;
char *arg2 = (char *) NULL ;
- ESLevent *result = 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 2)) {
{
esl_event_t *arg1 = (esl_event_t *) 0 ;
int arg2 = (int) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int val2 ;
int ecode2 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 2)) {
XS(_wrap_new_ESLevent__SWIG_2) {
{
ESLevent *arg1 = (ESLevent *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 1)) {
dispatch:
switch(_index) {
case 1:
- ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ESLevent__SWIG_1); return;
+ PUSHMARK(MARK); SWIG_CALLXS(_wrap_new_ESLevent__SWIG_1); return;
case 2:
- ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ESLevent__SWIG_2); return;
+ PUSHMARK(MARK); SWIG_CALLXS(_wrap_new_ESLevent__SWIG_2); return;
case 3:
- ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ESLevent__SWIG_0); return;
+ PUSHMARK(MARK); SWIG_CALLXS(_wrap_new_ESLevent__SWIG_0); return;
}
}
}
arg1 = reinterpret_cast< ESLevent * >(argp1);
delete arg1;
-
-
+ ST(argvi) = sv_newmortal();
XSRETURN(argvi);
fail:
{
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) NULL ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
int argvi = 0;
+ char *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 2)) {
{
ESLevent *arg1 = (ESLevent *) 0 ;
esl_priority_t arg2 = (esl_priority_t) ESL_PRIORITY_NORMAL ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 ;
int res2 = 0 ;
int argvi = 0;
+ bool result;
dXSARGS;
if ((items < 1) || (items > 2)) {
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
int arg3 = (int) -1 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
int val3 ;
int ecode3 = 0 ;
int argvi = 0;
+ char *result = 0 ;
dXSARGS;
if ((items < 2) || (items > 3)) {
XS(_wrap_ESLevent_getBody) {
{
ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ char *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 1)) {
XS(_wrap_ESLevent_getType) {
{
ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ char *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 1)) {
{
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
int argvi = 0;
+ bool result;
dXSARGS;
if ((items < 2) || (items > 2)) {
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int argvi = 0;
+ bool result;
dXSARGS;
if ((items < 3) || (items > 3)) {
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int argvi = 0;
+ bool result;
dXSARGS;
if ((items < 3) || (items > 3)) {
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int argvi = 0;
+ bool result;
dXSARGS;
if ((items < 3) || (items > 3)) {
{
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
int argvi = 0;
+ bool result;
dXSARGS;
if ((items < 2) || (items > 2)) {
XS(_wrap_ESLevent_firstHeader) {
{
ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ char *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 1)) {
XS(_wrap_ESLevent_nextHeader) {
{
ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ char *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 1)) {
int arg2 ;
char *arg3 = (char *) 0 ;
char *arg4 = (char *) 0 ;
- ESLconnection *result = 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
char *buf4 = 0 ;
int alloc4 = 0 ;
int argvi = 0;
+ ESLconnection *result = 0 ;
dXSARGS;
if ((items < 4) || (items > 4)) {
char *arg1 = (char *) 0 ;
int arg2 ;
char *arg3 = (char *) 0 ;
- ESLconnection *result = 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int argvi = 0;
+ ESLconnection *result = 0 ;
dXSARGS;
if ((items < 3) || (items > 3)) {
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
char *arg4 = (char *) 0 ;
- ESLconnection *result = 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
char *buf4 = 0 ;
int alloc4 = 0 ;
int argvi = 0;
+ ESLconnection *result = 0 ;
dXSARGS;
if ((items < 4) || (items > 4)) {
char *arg1 = (char *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- ESLconnection *result = 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int argvi = 0;
+ ESLconnection *result = 0 ;
dXSARGS;
if ((items < 3) || (items > 3)) {
XS(_wrap_new_ESLconnection__SWIG_4) {
{
int arg1 ;
- ESLconnection *result = 0 ;
int val1 ;
int ecode1 = 0 ;
int argvi = 0;
+ ESLconnection *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 1)) {
dispatch:
switch(_index) {
case 1:
- ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ESLconnection__SWIG_4); return;
+ PUSHMARK(MARK); SWIG_CALLXS(_wrap_new_ESLconnection__SWIG_4); return;
case 2:
- ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ESLconnection__SWIG_1); return;
+ PUSHMARK(MARK); SWIG_CALLXS(_wrap_new_ESLconnection__SWIG_1); return;
case 3:
- ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ESLconnection__SWIG_3); return;
+ PUSHMARK(MARK); SWIG_CALLXS(_wrap_new_ESLconnection__SWIG_3); return;
case 4:
- ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ESLconnection__SWIG_0); return;
+ PUSHMARK(MARK); SWIG_CALLXS(_wrap_new_ESLconnection__SWIG_0); return;
case 5:
- ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ESLconnection__SWIG_2); return;
+ PUSHMARK(MARK); SWIG_CALLXS(_wrap_new_ESLconnection__SWIG_2); return;
}
}
}
arg1 = reinterpret_cast< ESLconnection * >(argp1);
delete arg1;
-
-
+ ST(argvi) = sv_newmortal();
XSRETURN(argvi);
fail:
XS(_wrap_ESLconnection_socketDescriptor) {
{
ESLconnection *arg1 = (ESLconnection *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ int result;
dXSARGS;
if ((items < 1) || (items > 1)) {
XS(_wrap_ESLconnection_connected) {
{
ESLconnection *arg1 = (ESLconnection *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ int result;
dXSARGS;
if ((items < 1) || (items > 1)) {
XS(_wrap_ESLconnection_getInfo) {
{
ESLconnection *arg1 = (ESLconnection *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 1)) {
{
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
int argvi = 0;
+ int result;
dXSARGS;
if ((items < 2) || (items > 2)) {
{
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 2) || (items > 2)) {
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) NULL ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 2) || (items > 3)) {
char *arg2 = (char *) 0 ;
char *arg3 = (char *) NULL ;
char *arg4 = (char *) NULL ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf4 = 0 ;
int alloc4 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 2) || (items > 4)) {
{
ESLconnection *arg1 = (ESLconnection *) 0 ;
ESLevent *arg2 = (ESLevent *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 2) || (items > 2)) {
ESLconnection *arg1 = (ESLconnection *) 0 ;
ESLevent *arg2 = (ESLevent *) 0 ;
char *arg3 = (char *) NULL ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int argvi = 0;
+ int result;
dXSARGS;
if ((items < 2) || (items > 3)) {
XS(_wrap_ESLconnection_recvEvent) {
{
ESLconnection *arg1 = (ESLconnection *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 1) || (items > 1)) {
{
ESLconnection *arg1 = (ESLconnection *) 0 ;
int arg2 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int val2 ;
int ecode2 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 2) || (items > 2)) {
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 3) || (items > 3)) {
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int argvi = 0;
+ int result;
dXSARGS;
if ((items < 3) || (items > 3)) {
char *arg2 = (char *) 0 ;
char *arg3 = (char *) NULL ;
char *arg4 = (char *) NULL ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf4 = 0 ;
int alloc4 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 2) || (items > 4)) {
char *arg2 = (char *) 0 ;
char *arg3 = (char *) NULL ;
char *arg4 = (char *) NULL ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf4 = 0 ;
int alloc4 = 0 ;
int argvi = 0;
+ ESLevent *result = 0 ;
dXSARGS;
if ((items < 2) || (items > 4)) {
{
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
int argvi = 0;
+ int result;
dXSARGS;
if ((items < 2) || (items > 2)) {
{
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
int argvi = 0;
+ int result;
dXSARGS;
if ((items < 2) || (items > 2)) {
XS(_wrap_ESLconnection_disconnect) {
{
ESLconnection *arg1 = (ESLconnection *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
+ int result;
dXSARGS;
if ((items < 1) || (items > 1)) {
}
arg1 = static_cast< int >(val1);
eslSetLogLevel(arg1);
-
+ ST(argvi) = sv_newmortal();
XSRETURN(argvi);
fail:
};
/* -----------------------------------------------------------------------------
* Type initialization:
- * This problem is tough by the requirement that no dynamic
- * memory is used. Also, since swig_type_info structures store pointers to
+ * This problem is tough by the requirement that no dynamic
+ * memory is used. Also, since swig_type_info structures store pointers to
* swig_cast_info structures and swig_cast_info structures store pointers back
- * to swig_type_info structures, we need some lookup code at initialization.
- * The idea is that swig generates all the structures that are needed.
- * The runtime then collects these partially filled structures.
- * The SWIG_InitializeModule function takes these initial arrays out of
+ * to swig_type_info structures, we need some lookup code at initialization.
+ * The idea is that swig generates all the structures that are needed.
+ * The runtime then collects these partially filled structures.
+ * The SWIG_InitializeModule function takes these initial arrays out of
* swig_module, and does all the lookup, filling in the swig_module.types
* array with the correct data and linking the correct swig_cast_info
* structures together.
*
- * The generated swig_type_info structures are assigned staticly to an initial
+ * The generated swig_type_info structures are assigned staticly to an initial
* array. We just loop through that array, and handle each type individually.
* First we lookup if this type has been already loaded, and if so, use the
* loaded structure instead of the generated one. Then we have to fill in the
* a column is one of the swig_cast_info structures for that type.
* The cast_initial array is actually an array of arrays, because each row has
* a variable number of columns. So to actually build the cast linked list,
- * we find the array of casts associated with the type, and loop through it
+ * we find the array of casts associated with the type, and loop through it
* adding the casts to the list. The one last trick we need to do is making
* sure the type pointer in the swig_cast_info struct is correct.
*
- * First off, we lookup the cast->type name to see if it is already loaded.
+ * First off, we lookup the cast->type name to see if it is already loaded.
* There are three cases to handle:
* 1) If the cast->type has already been loaded AND the type we are adding
* casting info to has not been loaded (it is in this module), THEN we
* replace the cast->type pointer with the type pointer that has already
* been loaded.
- * 2) If BOTH types (the one we are adding casting info to, and the
+ * 2) If BOTH types (the one we are adding casting info to, and the
* cast->type) are loaded, THEN the cast info has already been loaded by
* the previous module so we just ignore it.
* 3) Finally, if cast->type has not already been loaded, then we add that
swig_module_info *module_head, *iter;
int found, init;
- clientdata = clientdata;
-
/* check to see if the circular list has been setup, if not, set it up */
if (swig_module.next==0) {
/* Initialize the swig_module */
module_head->next = &swig_module;
}
- /* When multiple interpeters are used, a module could have already been initialized in
+ /* When multiple interpreters are used, a module could have already been initialized in
a different interpreter, but not yet have a pointer in this interpreter.
In this case, we do not want to continue adding types... everything should be
set up already */
/* Install commands */
for (i = 0; swig_commands[i].name; i++) {
- newXS((char*) swig_commands[i].name,swig_commands[i].wrapper, (char*)__FILE__);
+ /* Casts only needed for Perl < 5.10. */
+#ifdef __cplusplus
+ newXS(const_cast<char*>(swig_commands[i].name), swig_commands[i].wrapper, const_cast<char*>(__FILE__));
+#else
+ newXS((char*)swig_commands[i].name, swig_commands[i].wrapper, (char*)__FILE__);
+#endif
}
/* Install variables */
for (i = 0; swig_variables[i].name; i++) {
SV *sv;
- sv = get_sv((char*) swig_variables[i].name, TRUE | 0x2 | GV_ADDMULTI);
+ sv = get_sv(swig_variables[i].name, TRUE | 0x2 | GV_ADDMULTI);
if (swig_variables[i].type) {
SWIG_MakePtr(sv,(void *)1, *swig_variables[i].type,0);
} else {
sv_setiv(sv,(IV) 0);
}
- swig_create_magic(sv, (char *) swig_variables[i].name, swig_variables[i].set, swig_variables[i].get);
+ swig_create_magic(sv, swig_variables[i].name, swig_variables[i].set, swig_variables[i].get);
}
/* Install constant */
for (i = 0; swig_constants[i].type; i++) {
SV *sv;
- sv = get_sv((char*)swig_constants[i].name, TRUE | 0x2 | GV_ADDMULTI);
+ sv = get_sv(swig_constants[i].name, TRUE | 0x2 | GV_ADDMULTI);
switch(swig_constants[i].type) {
case SWIG_INT:
sv_setiv(sv, (IV) swig_constants[i].lvalue);
sv_setnv(sv, (double) swig_constants[i].dvalue);
break;
case SWIG_STRING:
- sv_setpv(sv, (char *) swig_constants[i].pvalue);
+ sv_setpv(sv, (const char *) swig_constants[i].pvalue);
break;
case SWIG_POINTER:
SWIG_MakePtr(sv, swig_constants[i].pvalue, *(swig_constants[i].ptype),0);
-#include <EXTERN.h>
-#include <perl.h>
+#include "EXTERN.h"
+#include "perl.h"
+#include "XSUB.h"
EXTERN_C void xs_init (pTHX);
EXTERN_C void
xs_init(pTHX)
{
- char *file = __FILE__;
- dXSUB_SYS;
+ static const char file[] = __FILE__;
+ dXSUB_SYS;
+ PERL_UNUSED_CONTEXT;
- /* DynaLoader is a special case */
- newXS("DynaLoader::boot_DynaLoader", boot_DynaLoader, file);
+ /* DynaLoader is a special case */
+ newXS("DynaLoader::boot_DynaLoader", boot_DynaLoader, file);
}
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.7
- *
- * This file is not intended to be easily readable and contains a number of
+ * Version 2.0.12
+ *
+ * This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
- * changes to this file unless you know what you are doing--modify the SWIG
- * interface file instead.
+ * changes to this file unless you know what you are doing--modify the SWIG
+ * interface file instead.
* ----------------------------------------------------------------------------- */
// Try to load our extension if it's not already loaded.
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.7
- *
- * This file is not intended to be easily readable and contains a number of
+ * Version 2.0.12
+ *
+ * This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
- * changes to this file unless you know what you are doing--modify the SWIG
- * interface file instead.
+ * changes to this file unless you know what you are doing--modify the SWIG
+ * interface file instead.
* ----------------------------------------------------------------------------- */
#define SWIGPHP
#ifndef SWIGUNUSED
# if defined(__GNUC__)
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
# elif defined(__ICC)
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
-# define SWIGUNUSED
+# define SWIGUNUSED
# endif
#endif
#ifndef SWIG_MSC_UNSUPPRESS_4505
# if defined(_MSC_VER)
# pragma warning(disable : 4505) /* unreferenced local function has been removed */
-# endif
+# endif
#endif
#ifndef SWIGUNUSEDPARM
# ifdef __cplusplus
# define SWIGUNUSEDPARM(p)
# else
-# define SWIGUNUSEDPARM(p) p SWIGUNUSED
+# define SWIGUNUSEDPARM(p) p SWIGUNUSED
# endif
#endif
# define SWIGSTDCALL __stdcall
# else
# define SWIGSTDCALL
-# endif
+# endif
#endif
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
creating a static or dynamic library from the SWIG runtime code.
In 99.9% of the cases, SWIG just needs to declare them as 'static'.
-
+
But only do this if strictly necessary, ie, if you have problems
with your compiler or suchlike.
*/
#define SWIG_POINTER_OWN 0x1
-/*
+/*
Flags/methods for returning states.
-
- The SWIG conversion methods, as ConvertPtr, return an integer
+
+ The SWIG conversion methods, as ConvertPtr, return an integer
that tells if the conversion was successful or not. And if not,
an error code can be returned (see swigerrors.swg for the codes).
-
+
Use the following macros/flags to set or process the returning
states.
-
+
In old versions of SWIG, code such as the following was usually written:
if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
} else {
// fail code
}
-
+
I.e., now SWIG_ConvertPtr can return new objects and you can
identify the case and take care of the deallocation. Of course that
also requires SWIG_ConvertPtr to return new result values, such as
- int SWIG_ConvertPtr(obj, ptr,...) {
- if (<obj is ok>) {
- if (<need new object>) {
- *ptr = <ptr to new allocated object>;
- return SWIG_NEWOBJ;
- } else {
- *ptr = <ptr to old object>;
- return SWIG_OLDOBJ;
- }
- } else {
- return SWIG_BADOBJ;
- }
+ int SWIG_ConvertPtr(obj, ptr,...) {
+ if (<obj is ok>) {
+ if (<need new object>) {
+ *ptr = <ptr to new allocated object>;
+ return SWIG_NEWOBJ;
+ } else {
+ *ptr = <ptr to old object>;
+ return SWIG_OLDOBJ;
+ }
+ } else {
+ return SWIG_BADOBJ;
+ }
}
Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
int fooi(int);
and you call
-
+
food(1) // cast rank '1' (1 -> 1.0)
fooi(1) // cast rank '0'
just use the SWIG_AddCast()/SWIG_CheckState()
*/
-#define SWIG_OK (0)
+#define SWIG_OK (0)
#define SWIG_ERROR (-1)
#define SWIG_IsOK(r) (r >= 0)
-#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
+#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
/* The CastRankLimit says how many bits are used for the cast rank */
#define SWIG_CASTRANKLIMIT (1 << 8)
# endif
# define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
# define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
-SWIGINTERNINLINE int SWIG_AddCast(int r) {
+SWIGINTERNINLINE int SWIG_AddCast(int r) {
return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
}
-SWIGINTERNINLINE int SWIG_CheckState(int r) {
- return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
+SWIGINTERNINLINE int SWIG_CheckState(int r) {
+ return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
}
#else /* no cast-rank mode */
-# define SWIG_AddCast
+# define SWIG_AddCast(r) (r)
# define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
#endif
void *clientdata; /* Language specific module data */
} swig_module_info;
-/*
+/*
Compare two type names skipping the space characters, therefore
"char*" == "char *" and "Class<int>" == "Class<int >", etc.
/*
Check type equivalence in a name list like <name1>|<name2>|...
- Return 0 if not equal, 1 if equal
+ Return 0 if equal, -1 if nb < tb, 1 if nb > tb
*/
SWIGRUNTIME int
-SWIG_TypeEquiv(const char *nb, const char *tb) {
- int equiv = 0;
+SWIG_TypeCmp(const char *nb, const char *tb) {
+ int equiv = 1;
const char* te = tb + strlen(tb);
const char* ne = nb;
- while (!equiv && *ne) {
+ while (equiv != 0 && *ne) {
for (nb = ne; *ne; ++ne) {
if (*ne == '|') break;
}
- equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
+ equiv = SWIG_TypeNameComp(nb, ne, tb, te);
if (*ne) ++ne;
}
return equiv;
/*
Check type equivalence in a name list like <name1>|<name2>|...
- Return 0 if equal, -1 if nb < tb, 1 if nb > tb
+ Return 0 if not equal, 1 if equal
*/
SWIGRUNTIME int
-SWIG_TypeCompare(const char *nb, const char *tb) {
- int equiv = 0;
- const char* te = tb + strlen(tb);
- const char* ne = nb;
- while (!equiv && *ne) {
- for (nb = ne; *ne; ++ne) {
- if (*ne == '|') break;
- }
- equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
- if (*ne) ++ne;
- }
- return equiv;
+SWIG_TypeEquiv(const char *nb, const char *tb) {
+ return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
}
-
/*
Check the typename
*/
return 0;
}
-/*
+/*
Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
*/
SWIGRUNTIME swig_cast_info *
return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
}
-/*
+/*
Dynamic pointer casting. Down an inheritance hierarchy
*/
SWIGRUNTIME swig_type_info *
return type->name;
}
-/*
+/*
Set the clientdata field for a type
*/
SWIGRUNTIME void
swig_cast_info *cast = ti->cast;
/* if (ti->clientdata == clientdata) return; */
ti->clientdata = clientdata;
-
+
while (cast) {
if (!cast->converter) {
swig_type_info *tc = cast->type;
if (!tc->clientdata) {
SWIG_TypeClientData(tc, clientdata);
}
- }
+ }
cast = cast->next;
}
}
SWIG_TypeClientData(ti, clientdata);
ti->owndata = 1;
}
-
+
/*
Search for a swig_type_info structure only by mangled name
Search is a O(log #types)
-
- We start searching at module start, and finish searching when start == end.
+
+ We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
-SWIG_MangledTypeQueryModule(swig_module_info *start,
- swig_module_info *end,
+SWIG_MangledTypeQueryModule(swig_module_info *start,
+ swig_module_info *end,
const char *name) {
swig_module_info *iter = start;
do {
register size_t r = iter->size - 1;
do {
/* since l+r >= 0, we can (>> 1) instead (/ 2) */
- register size_t i = (l + r) >> 1;
+ register size_t i = (l + r) >> 1;
const char *iname = iter->types[i]->name;
if (iname) {
register int compare = strcmp(name, iname);
- if (compare == 0) {
+ if (compare == 0) {
return iter->types[i];
} else if (compare < 0) {
if (i) {
Search for a swig_type_info structure for either a mangled name or a human readable name.
It first searches the mangled names of the types, which is a O(log #types)
If a type is not found it then searches the human readable names, which is O(#types).
-
- We start searching at module start, and finish searching when start == end.
+
+ We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
-SWIG_TypeQueryModule(swig_module_info *start,
- swig_module_info *end,
+SWIG_TypeQueryModule(swig_module_info *start,
+ swig_module_info *end,
const char *name) {
/* STEP 1: Search the name field using binary search */
swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
iter = iter->next;
} while (iter != end);
}
-
+
/* neither found a match */
return 0;
}
-/*
+/*
Pack binary data into a string
*/
SWIGRUNTIME char *
return c;
}
-/*
+/*
Unpack binary data from a string
*/
SWIGRUNTIME const char *
uu = ((d - '0') << 4);
else if ((d >= 'a') && (d <= 'f'))
uu = ((d - ('a'-10)) << 4);
- else
+ else
return (char *) 0;
d = *(c++);
if ((d >= '0') && (d <= '9'))
uu |= (d - '0');
else if ((d >= 'a') && (d <= 'f'))
uu |= (d - ('a'-10));
- else
+ else
return (char *) 0;
*u = uu;
}
return c;
}
-/*
+/*
Pack 'void *' into a string buffer.
*/
SWIGRUNTIME char *
if (!(expr) ) { zend_printf("Contract Assert Failed %s\n",msg ); } else
/* Standard SWIG API */
-#define SWIG_GetModule(clientdata) SWIG_Php_GetModule()
+#define SWIG_GetModule(clientdata) SWIG_Php_GetModule(clientdata)
#define SWIG_SetModule(clientdata, pointer) SWIG_Php_SetModule(pointer)
/* used to wrap returned objects in so we know whether they are newobject
const char *type_name;
value = (swig_object_wrapper *) zend_list_find(z->value.lval, &type);
- if ( flags & SWIG_POINTER_DISOWN ) {
+ if (type==-1) return NULL;
+ if (flags & SWIG_POINTER_DISOWN) {
value->newobject = 0;
}
p = value->ptr;
- if (type==-1) return NULL;
type_name=zend_rsrc_list_get_rsrc_type(z->value.lval TSRMLS_CC);
}
static char const_name[] = "swig_runtime_data_type_pointer";
-static swig_module_info *SWIG_Php_GetModule() {
+static swig_module_info *SWIG_Php_GetModule(void *SWIGUNUSEDPARM(clientdata)) {
zval *pointer;
swig_module_info *ret = 0;
+ TSRMLS_FETCH();
MAKE_STD_ZVAL(pointer);
- TSRMLS_FETCH();
-
if (zend_get_constant(const_name, sizeof(const_name) - 1, pointer TSRMLS_CC)) {
if (pointer->type == IS_LONG) {
ret = (swig_module_info *) pointer->value.lval;
#endif
static void SWIG_FAIL() {
+ TSRMLS_FETCH();
zend_error(SWIG_ErrorCode(), "%s", SWIG_ErrorMsg());
abort();
}
#define SWIG_php_minit PHP_MINIT_FUNCTION(ESL)
/* -----------------------------------------------------------------------------
* Type initialization:
- * This problem is tough by the requirement that no dynamic
- * memory is used. Also, since swig_type_info structures store pointers to
+ * This problem is tough by the requirement that no dynamic
+ * memory is used. Also, since swig_type_info structures store pointers to
* swig_cast_info structures and swig_cast_info structures store pointers back
- * to swig_type_info structures, we need some lookup code at initialization.
- * The idea is that swig generates all the structures that are needed.
- * The runtime then collects these partially filled structures.
- * The SWIG_InitializeModule function takes these initial arrays out of
+ * to swig_type_info structures, we need some lookup code at initialization.
+ * The idea is that swig generates all the structures that are needed.
+ * The runtime then collects these partially filled structures.
+ * The SWIG_InitializeModule function takes these initial arrays out of
* swig_module, and does all the lookup, filling in the swig_module.types
* array with the correct data and linking the correct swig_cast_info
* structures together.
*
- * The generated swig_type_info structures are assigned staticly to an initial
+ * The generated swig_type_info structures are assigned staticly to an initial
* array. We just loop through that array, and handle each type individually.
* First we lookup if this type has been already loaded, and if so, use the
* loaded structure instead of the generated one. Then we have to fill in the
* a column is one of the swig_cast_info structures for that type.
* The cast_initial array is actually an array of arrays, because each row has
* a variable number of columns. So to actually build the cast linked list,
- * we find the array of casts associated with the type, and loop through it
+ * we find the array of casts associated with the type, and loop through it
* adding the casts to the list. The one last trick we need to do is making
* sure the type pointer in the swig_cast_info struct is correct.
*
- * First off, we lookup the cast->type name to see if it is already loaded.
+ * First off, we lookup the cast->type name to see if it is already loaded.
* There are three cases to handle:
* 1) If the cast->type has already been loaded AND the type we are adding
* casting info to has not been loaded (it is in this module), THEN we
* replace the cast->type pointer with the type pointer that has already
* been loaded.
- * 2) If BOTH types (the one we are adding casting info to, and the
+ * 2) If BOTH types (the one we are adding casting info to, and the
* cast->type) are loaded, THEN the cast info has already been loaded by
* the previous module so we just ignore it.
* 3) Finally, if cast->type has not already been loaded, then we add that
swig_module_info *module_head, *iter;
int found, init;
- clientdata = clientdata;
-
/* check to see if the circular list has been setup, if not, set it up */
if (swig_module.next==0) {
/* Initialize the swig_module */
module_head->next = &swig_module;
}
- /* When multiple interpeters are used, a module could have already been initialized in
+ /* When multiple interpreters are used, a module could have already been initialized in
a different interpreter, but not yet have a pointer in this interpreter.
In this case, we do not want to continue adding types... everything should be
set up already */
swig_type_info *type = 0;
swig_type_info *ret;
swig_cast_info *cast;
-
+
#ifdef SWIGRUNTIME_DEBUG
printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
#endif
/* Insert casting types */
cast = swig_module.cast_initial[i];
while (cast->type) {
-
+
/* Don't need to add information already in the list */
ret = 0;
#ifdef SWIGRUNTIME_DEBUG
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.7
- *
- * This file is not intended to be easily readable and contains a number of
+ * Version 2.0.12
+ *
+ * This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
- * changes to this file unless you know what you are doing--modify the SWIG
- * interface file instead.
+ * changes to this file unless you know what you are doing--modify the SWIG
+ * interface file instead.
* ----------------------------------------------------------------------------- */
#ifndef PHP_ESL_H
# This file was automatically generated by SWIG (http://www.swig.org).
-# Version 1.3.35
+# Version 2.0.12
#
-# Don't modify this file, modify the SWIG interface instead.
-# This file is compatible with both classic and new-style classes.
+# Do not make changes to this file unless you know what you are doing--modify
+# the SWIG interface file instead.
+
+
+
-import _ESL
-import new
-new_instancemethod = new.instancemethod
+
+from sys import version_info
+if version_info >= (2,6,0):
+ def swig_import_helper():
+ from os.path import dirname
+ import imp
+ fp = None
+ try:
+ fp, pathname, description = imp.find_module('_ESL', [dirname(__file__)])
+ except ImportError:
+ import _ESL
+ return _ESL
+ if fp is not None:
+ try:
+ _mod = imp.load_module('_ESL', fp, pathname, description)
+ finally:
+ fp.close()
+ return _mod
+ _ESL = swig_import_helper()
+ del swig_import_helper
+else:
+ import _ESL
+del version_info
def _swig_setattr_nondynamic(self,class_type,name,value,static=1):
if (name == "thisown"): return self.this.own(value)
if (name == "this"):
- if type(value).__name__ == 'PySwigObject':
+ if type(value).__name__ == 'SwigPyObject':
self.__dict__[name] = value
return
method = class_type.__swig_setmethods__.get(name,None)
if method: return method(self,value)
- if (not static) or hasattr(self,name):
+ if (not static):
self.__dict__[name] = value
else:
raise AttributeError("You cannot add attributes to %s" % self)
if (name == "thisown"): return self.this.own()
method = class_type.__swig_getmethods__.get(name,None)
if method: return method(self)
- raise AttributeError,name
+ raise AttributeError(name)
def _swig_repr(self):
try: strthis = "proxy of " + self.this.__repr__()
__swig_setmethods__["mine"] = _ESL.ESLevent_mine_set
__swig_getmethods__["mine"] = _ESL.ESLevent_mine_get
def __init__(self, *args):
- this = apply(_ESL.new_ESLevent, args)
+ this = _ESL.new_ESLevent(*args)
try: self.this.append(this)
except: self.this = this
__swig_destroy__ = _ESL.delete_ESLevent
__del__ = lambda self : None;
- def serialize(*args): return apply(_ESL.ESLevent_serialize, args)
- def setPriority(*args): return apply(_ESL.ESLevent_setPriority, args)
- def getHeader(*args): return apply(_ESL.ESLevent_getHeader, args)
- def getBody(*args): return apply(_ESL.ESLevent_getBody, args)
- def getType(*args): return apply(_ESL.ESLevent_getType, args)
- def addBody(*args): return apply(_ESL.ESLevent_addBody, args)
- def addHeader(*args): return apply(_ESL.ESLevent_addHeader, args)
- def pushHeader(*args): return apply(_ESL.ESLevent_pushHeader, args)
- def unshiftHeader(*args): return apply(_ESL.ESLevent_unshiftHeader, args)
- def delHeader(*args): return apply(_ESL.ESLevent_delHeader, args)
- def firstHeader(*args): return apply(_ESL.ESLevent_firstHeader, args)
- def nextHeader(*args): return apply(_ESL.ESLevent_nextHeader, args)
+ def serialize(self, format=None): return _ESL.ESLevent_serialize(self, format)
+ def setPriority(self, *args): return _ESL.ESLevent_setPriority(self, *args)
+ def getHeader(self, *args): return _ESL.ESLevent_getHeader(self, *args)
+ def getBody(self): return _ESL.ESLevent_getBody(self)
+ def getType(self): return _ESL.ESLevent_getType(self)
+ def addBody(self, *args): return _ESL.ESLevent_addBody(self, *args)
+ def addHeader(self, *args): return _ESL.ESLevent_addHeader(self, *args)
+ def pushHeader(self, *args): return _ESL.ESLevent_pushHeader(self, *args)
+ def unshiftHeader(self, *args): return _ESL.ESLevent_unshiftHeader(self, *args)
+ def delHeader(self, *args): return _ESL.ESLevent_delHeader(self, *args)
+ def firstHeader(self): return _ESL.ESLevent_firstHeader(self)
+ def nextHeader(self): return _ESL.ESLevent_nextHeader(self)
ESLevent_swigregister = _ESL.ESLevent_swigregister
ESLevent_swigregister(ESLevent)
__getattr__ = lambda self, name: _swig_getattr(self, ESLconnection, name)
__repr__ = _swig_repr
def __init__(self, *args):
- this = apply(_ESL.new_ESLconnection, args)
+ this = _ESL.new_ESLconnection(*args)
try: self.this.append(this)
except: self.this = this
__swig_destroy__ = _ESL.delete_ESLconnection
__del__ = lambda self : None;
- def socketDescriptor(*args): return apply(_ESL.ESLconnection_socketDescriptor, args)
- def connected(*args): return apply(_ESL.ESLconnection_connected, args)
- def getInfo(*args): return apply(_ESL.ESLconnection_getInfo, args)
- def send(*args): return apply(_ESL.ESLconnection_send, args)
- def sendRecv(*args): return apply(_ESL.ESLconnection_sendRecv, args)
- def api(*args): return apply(_ESL.ESLconnection_api, args)
- def bgapi(*args): return apply(_ESL.ESLconnection_bgapi, args)
- def sendEvent(*args): return apply(_ESL.ESLconnection_sendEvent, args)
- def sendMSG(*args): return apply(_ESL.ESLconnection_sendMSG, args)
- def recvEvent(*args): return apply(_ESL.ESLconnection_recvEvent, args)
- def recvEventTimed(*args): return apply(_ESL.ESLconnection_recvEventTimed, args)
- def filter(*args): return apply(_ESL.ESLconnection_filter, args)
- def events(*args): return apply(_ESL.ESLconnection_events, args)
- def execute(*args): return apply(_ESL.ESLconnection_execute, args)
- def executeAsync(*args): return apply(_ESL.ESLconnection_executeAsync, args)
- def setAsyncExecute(*args): return apply(_ESL.ESLconnection_setAsyncExecute, args)
- def setEventLock(*args): return apply(_ESL.ESLconnection_setEventLock, args)
- def disconnect(*args): return apply(_ESL.ESLconnection_disconnect, args)
+ def socketDescriptor(self): return _ESL.ESLconnection_socketDescriptor(self)
+ def connected(self): return _ESL.ESLconnection_connected(self)
+ def getInfo(self): return _ESL.ESLconnection_getInfo(self)
+ def send(self, *args): return _ESL.ESLconnection_send(self, *args)
+ def sendRecv(self, *args): return _ESL.ESLconnection_sendRecv(self, *args)
+ def api(self, *args): return _ESL.ESLconnection_api(self, *args)
+ def bgapi(self, *args): return _ESL.ESLconnection_bgapi(self, *args)
+ def sendEvent(self, *args): return _ESL.ESLconnection_sendEvent(self, *args)
+ def sendMSG(self, *args): return _ESL.ESLconnection_sendMSG(self, *args)
+ def recvEvent(self): return _ESL.ESLconnection_recvEvent(self)
+ def recvEventTimed(self, *args): return _ESL.ESLconnection_recvEventTimed(self, *args)
+ def filter(self, *args): return _ESL.ESLconnection_filter(self, *args)
+ def events(self, *args): return _ESL.ESLconnection_events(self, *args)
+ def execute(self, *args): return _ESL.ESLconnection_execute(self, *args)
+ def executeAsync(self, *args): return _ESL.ESLconnection_executeAsync(self, *args)
+ def setAsyncExecute(self, *args): return _ESL.ESLconnection_setAsyncExecute(self, *args)
+ def setEventLock(self, *args): return _ESL.ESLconnection_setEventLock(self, *args)
+ def disconnect(self): return _ESL.ESLconnection_disconnect(self)
ESLconnection_swigregister = _ESL.ESLconnection_swigregister
ESLconnection_swigregister(ESLconnection)
+
+def eslSetLogLevel(*args):
+ return _ESL.eslSetLogLevel(*args)
eslSetLogLevel = _ESL.eslSetLogLevel
+# This file is compatible with both classic and new-style classes.
all: _ESL.so
esl_wrap.cpp:
- swig -module ESL -classic -python -c++ -DMULTIPLICITY -threads -I../src/include -o esl_wrap.cpp ../ESL.i
+ swig2.0 -module ESL -classic -python -c++ -DMULTIPLICITY -threads -I../src/include -o esl_wrap.cpp ../ESL.i
esl_wrap.o: esl_wrap.cpp
$(CXX) $(CXX_CFLAGS) $(CXXFLAGS) $(LOCAL_CFLAGS) -c esl_wrap.cpp -o esl_wrap.o
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
- *
- * This file is not intended to be easily readable and contains a number of
+ * Version 2.0.12
+ *
+ * This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
- * changes to this file unless you know what you are doing--modify the SWIG
- * interface file instead.
+ * changes to this file unless you know what you are doing--modify the SWIG
+ * interface file instead.
* ----------------------------------------------------------------------------- */
#define SWIGPYTHON
#define SWIG_PYTHON_DIRECTOR_NO_VTABLE
#define SWIG_PYTHON_CLASSIC
+
#ifdef __cplusplus
+/* SwigValueWrapper is described in swig.swg */
template<typename T> class SwigValueWrapper {
- T *tt;
+ struct SwigMovePointer {
+ T *ptr;
+ SwigMovePointer(T *p) : ptr(p) { }
+ ~SwigMovePointer() { delete ptr; }
+ SwigMovePointer& operator=(SwigMovePointer& rhs) { T* oldptr = ptr; ptr = 0; delete oldptr; ptr = rhs.ptr; rhs.ptr = 0; return *this; }
+ } pointer;
+ SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
+ SwigValueWrapper(const SwigValueWrapper<T>& rhs);
public:
- SwigValueWrapper() : tt(0) { }
- SwigValueWrapper(const SwigValueWrapper<T>& rhs) : tt(new T(*rhs.tt)) { }
- SwigValueWrapper(const T& t) : tt(new T(t)) { }
- ~SwigValueWrapper() { delete tt; }
- SwigValueWrapper& operator=(const T& t) { delete tt; tt = new T(t); return *this; }
- operator T&() const { return *tt; }
- T *operator&() { return tt; }
-private:
- SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
+ SwigValueWrapper() : pointer(0) { }
+ SwigValueWrapper& operator=(const T& t) { SwigMovePointer tmp(new T(t)); pointer = tmp; return *this; }
+ operator T&() const { return *pointer.ptr; }
+ T *operator&() { return pointer.ptr; }
};
template <typename T> T SwigValueInit() {
#ifndef SWIGUNUSED
# if defined(__GNUC__)
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
# elif defined(__ICC)
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
-# define SWIGUNUSED
+# define SWIGUNUSED
+# endif
+#endif
+
+#ifndef SWIG_MSC_UNSUPPRESS_4505
+# if defined(_MSC_VER)
+# pragma warning(disable : 4505) /* unreferenced local function has been removed */
# endif
#endif
# ifdef __cplusplus
# define SWIGUNUSEDPARM(p)
# else
-# define SWIGUNUSEDPARM(p) p SWIGUNUSED
+# define SWIGUNUSEDPARM(p) p SWIGUNUSED
# endif
#endif
# define SWIGSTDCALL __stdcall
# else
# define SWIGSTDCALL
-# endif
+# endif
#endif
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
-/* Python.h has to appear first */
-#include <Python.h>
+#if defined(_DEBUG) && defined(SWIG_PYTHON_INTERPRETER_NO_DEBUG)
+/* Use debug wrappers with the Python release dll */
+# undef _DEBUG
+# include <Python.h>
+# define _DEBUG
+#else
+# include <Python.h>
+#endif
/* -----------------------------------------------------------------------------
* swigrun.swg
*
- * This file contains generic CAPI SWIG runtime support for pointer
+ * This file contains generic C API SWIG runtime support for pointer
* type checking.
* ----------------------------------------------------------------------------- */
/*
You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
- creating a static or dynamic library from the swig runtime code.
- In 99.9% of the cases, swig just needs to declare them as 'static'.
-
- But only do this if is strictly necessary, ie, if you have problems
- with your compiler or so.
+ creating a static or dynamic library from the SWIG runtime code.
+ In 99.9% of the cases, SWIG just needs to declare them as 'static'.
+
+ But only do this if strictly necessary, ie, if you have problems
+ with your compiler or suchlike.
*/
#ifndef SWIGRUNTIME
#define SWIG_POINTER_OWN 0x1
-/*
+/*
Flags/methods for returning states.
-
- The swig conversion methods, as ConvertPtr, return and integer
+
+ The SWIG conversion methods, as ConvertPtr, return an integer
that tells if the conversion was successful or not. And if not,
an error code can be returned (see swigerrors.swg for the codes).
-
+
Use the following macros/flags to set or process the returning
states.
-
- In old swig versions, you usually write code as:
+
+ In old versions of SWIG, code such as the following was usually written:
if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
// success code
//fail code
}
- Now you can be more explicit as:
+ Now you can be more explicit:
int res = SWIG_ConvertPtr(obj,vptr,ty.flags);
if (SWIG_IsOK(res)) {
// fail code
}
- that seems to be the same, but now you can also do
+ which is the same really, but now you can also do
Type *ptr;
int res = SWIG_ConvertPtr(obj,(void **)(&ptr),ty.flags);
} else {
// fail code
}
-
+
I.e., now SWIG_ConvertPtr can return new objects and you can
identify the case and take care of the deallocation. Of course that
- requires also to SWIG_ConvertPtr to return new result values, as
-
- int SWIG_ConvertPtr(obj, ptr,...) {
- if (<obj is ok>) {
- if (<need new object>) {
- *ptr = <ptr to new allocated object>;
- return SWIG_NEWOBJ;
- } else {
- *ptr = <ptr to old object>;
- return SWIG_OLDOBJ;
- }
- } else {
- return SWIG_BADOBJ;
- }
+ also requires SWIG_ConvertPtr to return new result values, such as
+
+ int SWIG_ConvertPtr(obj, ptr,...) {
+ if (<obj is ok>) {
+ if (<need new object>) {
+ *ptr = <ptr to new allocated object>;
+ return SWIG_NEWOBJ;
+ } else {
+ *ptr = <ptr to old object>;
+ return SWIG_OLDOBJ;
+ }
+ } else {
+ return SWIG_BADOBJ;
+ }
}
Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
more explicit by returning SWIG_BADOBJ, SWIG_ERROR or any of the
- swig errors code.
+ SWIG errors code.
Finally, if the SWIG_CASTRANK_MODE is enabled, the result code
allows to return the 'cast rank', for example, if you have this
int fooi(int);
and you call
-
+
food(1) // cast rank '1' (1 -> 1.0)
fooi(1) // cast rank '0'
just use the SWIG_AddCast()/SWIG_CheckState()
+*/
-
- */
-#define SWIG_OK (0)
+#define SWIG_OK (0)
#define SWIG_ERROR (-1)
#define SWIG_IsOK(r) (r >= 0)
-#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
+#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
/* The CastRankLimit says how many bits are used for the cast rank */
#define SWIG_CASTRANKLIMIT (1 << 8)
#define SWIG_DelTmpMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_TMPOBJMASK) : r)
#define SWIG_IsTmpObj(r) (SWIG_IsOK(r) && (r & SWIG_TMPOBJMASK))
-
/* Cast-Rank Mode */
#if defined(SWIG_CASTRANK_MODE)
# ifndef SWIG_TypeRank
# endif
# define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
# define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
-SWIGINTERNINLINE int SWIG_AddCast(int r) {
+SWIGINTERNINLINE int SWIG_AddCast(int r) {
return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
}
-SWIGINTERNINLINE int SWIG_CheckState(int r) {
- return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
+SWIGINTERNINLINE int SWIG_CheckState(int r) {
+ return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
}
#else /* no cast-rank mode */
-# define SWIG_AddCast
+# define SWIG_AddCast(r) (r)
# define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
#endif
-
-
#include <string.h>
#ifdef __cplusplus
void *clientdata; /* Language specific module data */
} swig_module_info;
-/*
+/*
Compare two type names skipping the space characters, therefore
"char*" == "char *" and "Class<int>" == "Class<int >", etc.
/*
Check type equivalence in a name list like <name1>|<name2>|...
- Return 0 if not equal, 1 if equal
+ Return 0 if equal, -1 if nb < tb, 1 if nb > tb
*/
SWIGRUNTIME int
-SWIG_TypeEquiv(const char *nb, const char *tb) {
- int equiv = 0;
+SWIG_TypeCmp(const char *nb, const char *tb) {
+ int equiv = 1;
const char* te = tb + strlen(tb);
const char* ne = nb;
- while (!equiv && *ne) {
+ while (equiv != 0 && *ne) {
for (nb = ne; *ne; ++ne) {
if (*ne == '|') break;
}
- equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
+ equiv = SWIG_TypeNameComp(nb, ne, tb, te);
if (*ne) ++ne;
}
return equiv;
/*
Check type equivalence in a name list like <name1>|<name2>|...
- Return 0 if equal, -1 if nb < tb, 1 if nb > tb
+ Return 0 if not equal, 1 if equal
*/
SWIGRUNTIME int
-SWIG_TypeCompare(const char *nb, const char *tb) {
- int equiv = 0;
- const char* te = tb + strlen(tb);
- const char* ne = nb;
- while (!equiv && *ne) {
- for (nb = ne; *ne; ++ne) {
- if (*ne == '|') break;
- }
- equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
- if (*ne) ++ne;
- }
- return equiv;
+SWIG_TypeEquiv(const char *nb, const char *tb) {
+ return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
}
-
-/* think of this as a c++ template<> or a scheme macro */
-#define SWIG_TypeCheck_Template(comparison, ty) \
- if (ty) { \
- swig_cast_info *iter = ty->cast; \
- while (iter) { \
- if (comparison) { \
- if (iter == ty->cast) return iter; \
- /* Move iter to the top of the linked list */ \
- iter->prev->next = iter->next; \
- if (iter->next) \
- iter->next->prev = iter->prev; \
- iter->next = ty->cast; \
- iter->prev = 0; \
- if (ty->cast) ty->cast->prev = iter; \
- ty->cast = iter; \
- return iter; \
- } \
- iter = iter->next; \
- } \
- } \
- return 0
-
/*
Check the typename
*/
SWIGRUNTIME swig_cast_info *
SWIG_TypeCheck(const char *c, swig_type_info *ty) {
- SWIG_TypeCheck_Template(strcmp(iter->type->name, c) == 0, ty);
+ if (ty) {
+ swig_cast_info *iter = ty->cast;
+ while (iter) {
+ if (strcmp(iter->type->name, c) == 0) {
+ if (iter == ty->cast)
+ return iter;
+ /* Move iter to the top of the linked list */
+ iter->prev->next = iter->next;
+ if (iter->next)
+ iter->next->prev = iter->prev;
+ iter->next = ty->cast;
+ iter->prev = 0;
+ if (ty->cast) ty->cast->prev = iter;
+ ty->cast = iter;
+ return iter;
+ }
+ iter = iter->next;
+ }
+ }
+ return 0;
}
-/* Same as previous function, except strcmp is replaced with a pointer comparison */
+/*
+ Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
+*/
SWIGRUNTIME swig_cast_info *
-SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *into) {
- SWIG_TypeCheck_Template(iter->type == from, into);
+SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *ty) {
+ if (ty) {
+ swig_cast_info *iter = ty->cast;
+ while (iter) {
+ if (iter->type == from) {
+ if (iter == ty->cast)
+ return iter;
+ /* Move iter to the top of the linked list */
+ iter->prev->next = iter->next;
+ if (iter->next)
+ iter->next->prev = iter->prev;
+ iter->next = ty->cast;
+ iter->prev = 0;
+ if (ty->cast) ty->cast->prev = iter;
+ ty->cast = iter;
+ return iter;
+ }
+ iter = iter->next;
+ }
+ }
+ return 0;
}
/*
return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
}
-/*
+/*
Dynamic pointer casting. Down an inheritance hierarchy
*/
SWIGRUNTIME swig_type_info *
return type->name;
}
-/*
+/*
Set the clientdata field for a type
*/
SWIGRUNTIME void
swig_cast_info *cast = ti->cast;
/* if (ti->clientdata == clientdata) return; */
ti->clientdata = clientdata;
-
+
while (cast) {
if (!cast->converter) {
swig_type_info *tc = cast->type;
if (!tc->clientdata) {
SWIG_TypeClientData(tc, clientdata);
}
- }
+ }
cast = cast->next;
}
}
SWIG_TypeClientData(ti, clientdata);
ti->owndata = 1;
}
-
+
/*
Search for a swig_type_info structure only by mangled name
Search is a O(log #types)
-
- We start searching at module start, and finish searching when start == end.
+
+ We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
-SWIG_MangledTypeQueryModule(swig_module_info *start,
- swig_module_info *end,
+SWIG_MangledTypeQueryModule(swig_module_info *start,
+ swig_module_info *end,
const char *name) {
swig_module_info *iter = start;
do {
register size_t r = iter->size - 1;
do {
/* since l+r >= 0, we can (>> 1) instead (/ 2) */
- register size_t i = (l + r) >> 1;
+ register size_t i = (l + r) >> 1;
const char *iname = iter->types[i]->name;
if (iname) {
register int compare = strcmp(name, iname);
- if (compare == 0) {
+ if (compare == 0) {
return iter->types[i];
} else if (compare < 0) {
if (i) {
Search for a swig_type_info structure for either a mangled name or a human readable name.
It first searches the mangled names of the types, which is a O(log #types)
If a type is not found it then searches the human readable names, which is O(#types).
-
- We start searching at module start, and finish searching when start == end.
+
+ We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
-SWIG_TypeQueryModule(swig_module_info *start,
- swig_module_info *end,
+SWIG_TypeQueryModule(swig_module_info *start,
+ swig_module_info *end,
const char *name) {
/* STEP 1: Search the name field using binary search */
swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
iter = iter->next;
} while (iter != end);
}
-
+
/* neither found a match */
return 0;
}
-/*
+/*
Pack binary data into a string
*/
SWIGRUNTIME char *
return c;
}
-/*
+/*
Unpack binary data from a string
*/
SWIGRUNTIME const char *
uu = ((d - '0') << 4);
else if ((d >= 'a') && (d <= 'f'))
uu = ((d - ('a'-10)) << 4);
- else
+ else
return (char *) 0;
d = *(c++);
if ((d >= '0') && (d <= '9'))
uu |= (d - '0');
else if ((d >= 'a') && (d <= 'f'))
uu |= (d - ('a'-10));
- else
+ else
return (char *) 0;
*u = uu;
}
return c;
}
-/*
+/*
Pack 'void *' into a string buffer.
*/
SWIGRUNTIME char *
#endif
/* Errors in SWIG */
-#define SWIG_UnknownError -1
-#define SWIG_IOError -2
-#define SWIG_RuntimeError -3
-#define SWIG_IndexError -4
-#define SWIG_TypeError -5
-#define SWIG_DivisionByZero -6
-#define SWIG_OverflowError -7
-#define SWIG_SyntaxError -8
-#define SWIG_ValueError -9
+#define SWIG_UnknownError -1
+#define SWIG_IOError -2
+#define SWIG_RuntimeError -3
+#define SWIG_IndexError -4
+#define SWIG_TypeError -5
+#define SWIG_DivisionByZero -6
+#define SWIG_OverflowError -7
+#define SWIG_SyntaxError -8
+#define SWIG_ValueError -9
#define SWIG_SystemError -10
#define SWIG_AttributeError -11
-#define SWIG_MemoryError -12
+#define SWIG_MemoryError -12
#define SWIG_NullReferenceError -13
+/* Compatibility macros for Python 3 */
+#if PY_VERSION_HEX >= 0x03000000
+
+#define PyClass_Check(obj) PyObject_IsInstance(obj, (PyObject *)&PyType_Type)
+#define PyInt_Check(x) PyLong_Check(x)
+#define PyInt_AsLong(x) PyLong_AsLong(x)
+#define PyInt_FromLong(x) PyLong_FromLong(x)
+#define PyInt_FromSize_t(x) PyLong_FromSize_t(x)
+#define PyString_Check(name) PyBytes_Check(name)
+#define PyString_FromString(x) PyUnicode_FromString(x)
+#define PyString_Format(fmt, args) PyUnicode_Format(fmt, args)
+#define PyString_AsString(str) PyBytes_AsString(str)
+#define PyString_Size(str) PyBytes_Size(str)
+#define PyString_InternFromString(key) PyUnicode_InternFromString(key)
+#define Py_TPFLAGS_HAVE_CLASS Py_TPFLAGS_BASETYPE
+#define PyString_AS_STRING(x) PyUnicode_AS_STRING(x)
+#define _PyLong_FromSsize_t(x) PyLong_FromSsize_t(x)
+
+#endif
+
+#ifndef Py_TYPE
+# define Py_TYPE(op) ((op)->ob_type)
+#endif
+
+/* SWIG APIs for compatibility of both Python 2 & 3 */
+
+#if PY_VERSION_HEX >= 0x03000000
+# define SWIG_Python_str_FromFormat PyUnicode_FromFormat
+#else
+# define SWIG_Python_str_FromFormat PyString_FromFormat
+#endif
+
+
+/* Warning: This function will allocate a new string in Python 3,
+ * so please call SWIG_Python_str_DelForPy3(x) to free the space.
+ */
+SWIGINTERN char*
+SWIG_Python_str_AsChar(PyObject *str)
+{
+#if PY_VERSION_HEX >= 0x03000000
+ char *cstr;
+ char *newstr;
+ Py_ssize_t len;
+ str = PyUnicode_AsUTF8String(str);
+ PyBytes_AsStringAndSize(str, &cstr, &len);
+ newstr = (char *) malloc(len+1);
+ memcpy(newstr, cstr, len+1);
+ Py_XDECREF(str);
+ return newstr;
+#else
+ return PyString_AsString(str);
+#endif
+}
+
+#if PY_VERSION_HEX >= 0x03000000
+# define SWIG_Python_str_DelForPy3(x) free( (void*) (x) )
+#else
+# define SWIG_Python_str_DelForPy3(x)
+#endif
+
+
+SWIGINTERN PyObject*
+SWIG_Python_str_FromChar(const char *c)
+{
+#if PY_VERSION_HEX >= 0x03000000
+ return PyUnicode_FromString(c);
+#else
+ return PyString_FromString(c);
+#endif
+}
/* Add PyOS_snprintf for old Pythons */
#if PY_VERSION_HEX < 0x02020000
# define PyObject_GenericGetAttr 0
# endif
#endif
+
/* Py_NotImplemented is defined in 2.1 and up. */
#if PY_VERSION_HEX < 0x02010000
# ifndef Py_NotImplemented
# endif
#endif
-
/* A crude PyString_AsStringAndSize implementation for old Pythons */
#if PY_VERSION_HEX < 0x02010000
# ifndef PyString_AsStringAndSize
# endif
#endif
-
/* PyBool_FromLong for old Pythons */
#if PY_VERSION_HEX < 0x02030000
static
typedef int Py_ssize_t;
# define PY_SSIZE_T_MAX INT_MAX
# define PY_SSIZE_T_MIN INT_MIN
+typedef inquiry lenfunc;
+typedef intargfunc ssizeargfunc;
+typedef intintargfunc ssizessizeargfunc;
+typedef intobjargproc ssizeobjargproc;
+typedef intintobjargproc ssizessizeobjargproc;
+typedef getreadbufferproc readbufferproc;
+typedef getwritebufferproc writebufferproc;
+typedef getsegcountproc segcountproc;
+typedef getcharbufferproc charbufferproc;
+static long PyNumber_AsSsize_t (PyObject *x, void *SWIGUNUSEDPARM(exc))
+{
+ long result = 0;
+ PyObject *i = PyNumber_Int(x);
+ if (i) {
+ result = PyInt_AsLong(i);
+ Py_DECREF(i);
+ }
+ return result;
+}
+#endif
+
+#if PY_VERSION_HEX < 0x02050000
+#define PyInt_FromSize_t(x) PyInt_FromLong((long)x)
+#endif
+
+#if PY_VERSION_HEX < 0x02040000
+#define Py_VISIT(op) \
+ do { \
+ if (op) { \
+ int vret = visit((op), arg); \
+ if (vret) \
+ return vret; \
+ } \
+ } while (0)
+#endif
+
+#if PY_VERSION_HEX < 0x02030000
+typedef struct {
+ PyTypeObject type;
+ PyNumberMethods as_number;
+ PyMappingMethods as_mapping;
+ PySequenceMethods as_sequence;
+ PyBufferProcs as_buffer;
+ PyObject *name, *slots;
+} PyHeapTypeObject;
+#endif
+
+#if PY_VERSION_HEX < 0x02030000
+typedef destructor freefunc;
+#endif
+
+#if ((PY_MAJOR_VERSION == 2 && PY_MINOR_VERSION > 6) || \
+ (PY_MAJOR_VERSION == 3 && PY_MINOR_VERSION > 0) || \
+ (PY_MAJOR_VERSION > 3))
+# define SWIGPY_USE_CAPSULE
+# define SWIGPY_CAPSULE_NAME ((char*)"swig_runtime_data" SWIG_RUNTIME_VERSION ".type_pointer_capsule" SWIG_TYPE_TABLE_NAME)
+#endif
+
+#if PY_VERSION_HEX < 0x03020000
+#define PyDescr_TYPE(x) (((PyDescrObject *)(x))->d_type)
+#define PyDescr_NAME(x) (((PyDescrObject *)(x))->d_name)
#endif
/* -----------------------------------------------------------------------------
if (PyErr_Occurred()) PyErr_Fetch(&type, &value, &traceback);
if (value) {
+ char *tmp;
PyObject *old_str = PyObject_Str(value);
PyErr_Clear();
Py_XINCREF(type);
- PyErr_Format(type, "%s %s", PyString_AsString(old_str), mesg);
+
+ PyErr_Format(type, "%s %s", tmp = SWIG_Python_str_AsChar(old_str), mesg);
+ SWIG_Python_str_DelForPy3(tmp);
Py_DECREF(old_str);
Py_DECREF(value);
} else {
}
}
-
-
#if defined(SWIG_PYTHON_NO_THREADS)
# if defined(SWIG_PYTHON_THREADS)
# undef SWIG_PYTHON_THREADS
#ifdef __cplusplus
extern "C" {
-#if 0
-} /* cc-mode */
-#endif
#endif
/* -----------------------------------------------------------------------------
swig_type_info **ptype;
} swig_const_info;
-#ifdef __cplusplus
-#if 0
-{ /* cc-mode */
+
+/* -----------------------------------------------------------------------------
+ * Wrapper of PyInstanceMethod_New() used in Python 3
+ * It is exported to the generated module, used for -fastproxy
+ * ----------------------------------------------------------------------------- */
+#if PY_VERSION_HEX >= 0x03000000
+SWIGRUNTIME PyObject* SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func)
+{
+ return PyInstanceMethod_New(func);
+}
+#else
+SWIGRUNTIME PyObject* SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *SWIGUNUSEDPARM(func))
+{
+ return NULL;
+}
#endif
+
+#ifdef __cplusplus
}
#endif
/* -----------------------------------------------------------------------------
- * See the LICENSE file for information on copyright, usage and redistribution
- * of SWIG, and the README file for authors - http://www.swig.org/release.html.
- *
* pyrun.swg
*
* This file contains the runtime support for Python modules
#define SWIG_Python_ConvertPtr(obj, pptr, type, flags) SWIG_Python_ConvertPtrAndOwn(obj, pptr, type, flags, 0)
#define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Python_ConvertPtr(obj, pptr, type, flags)
#define SWIG_ConvertPtrAndOwn(obj,pptr,type,flags,own) SWIG_Python_ConvertPtrAndOwn(obj, pptr, type, flags, own)
-#define SWIG_NewPointerObj(ptr, type, flags) SWIG_Python_NewPointerObj(ptr, type, flags)
+
+#ifdef SWIGPYTHON_BUILTIN
+#define SWIG_NewPointerObj(ptr, type, flags) SWIG_Python_NewPointerObj(self, ptr, type, flags)
+#else
+#define SWIG_NewPointerObj(ptr, type, flags) SWIG_Python_NewPointerObj(NULL, ptr, type, flags)
+#endif
+
+#define SWIG_InternalNewPointerObj(ptr, type, flags) SWIG_Python_NewPointerObj(NULL, ptr, type, flags)
+
#define SWIG_CheckImplicit(ty) SWIG_Python_CheckImplicit(ty)
#define SWIG_AcquirePtr(ptr, src) SWIG_Python_AcquirePtr(ptr, src)
#define swig_owntype int
/* for C or C++ function pointers */
#define SWIG_ConvertFunctionPtr(obj, pptr, type) SWIG_Python_ConvertFunctionPtr(obj, pptr, type)
-#define SWIG_NewFunctionPtrObj(ptr, type) SWIG_Python_NewPointerObj(ptr, type, 0)
+#define SWIG_NewFunctionPtrObj(ptr, type) SWIG_Python_NewPointerObj(NULL, ptr, type, 0)
/* for C++ member pointers, ie, member methods */
#define SWIG_ConvertMember(obj, ptr, sz, ty) SWIG_Python_ConvertPacked(obj, ptr, sz, ty)
/* Runtime API */
-#define SWIG_GetModule(clientdata) SWIG_Python_GetModule()
+#define SWIG_GetModule(clientdata) SWIG_Python_GetModule(clientdata)
#define SWIG_SetModule(clientdata, pointer) SWIG_Python_SetModule(pointer)
-#define SWIG_NewClientData(obj) PySwigClientData_New(obj)
+#define SWIG_NewClientData(obj) SwigPyClientData_New(obj)
#define SWIG_SetErrorObj SWIG_Python_SetErrorObj
#define SWIG_SetErrorMsg SWIG_Python_SetErrorMsg
SWIGINTERN void
SWIG_Python_SetErrorMsg(PyObject *errtype, const char *msg) {
SWIG_PYTHON_THREAD_BEGIN_BLOCK;
- PyErr_SetString(errtype, (char *) msg);
+ PyErr_SetString(errtype, msg);
SWIG_PYTHON_THREAD_END_BLOCK;
}
/* Set a constant value */
+#if defined(SWIGPYTHON_BUILTIN)
+
+SWIGINTERN void
+SwigPyBuiltin_AddPublicSymbol(PyObject *seq, const char *key) {
+ PyObject *s = PyString_InternFromString(key);
+ PyList_Append(seq, s);
+ Py_DECREF(s);
+}
+
+SWIGINTERN void
+SWIG_Python_SetConstant(PyObject *d, PyObject *public_interface, const char *name, PyObject *obj) {
+#if PY_VERSION_HEX < 0x02030000
+ PyDict_SetItemString(d, (char *)name, obj);
+#else
+ PyDict_SetItemString(d, name, obj);
+#endif
+ Py_DECREF(obj);
+ if (public_interface)
+ SwigPyBuiltin_AddPublicSymbol(public_interface, name);
+}
+
+#else
+
SWIGINTERN void
SWIG_Python_SetConstant(PyObject *d, const char *name, PyObject *obj) {
- PyDict_SetItemString(d, (char*) name, obj);
+#if PY_VERSION_HEX < 0x02030000
+ PyDict_SetItemString(d, (char *)name, obj);
+#else
+ PyDict_SetItemString(d, name, obj);
+#endif
Py_DECREF(obj);
}
+#endif
+
/* Append a value to the result obj */
SWIGINTERN PyObject*
}
}
if (!PyTuple_Check(args)) {
+ if (min <= 1 && max >= 1) {
+ register int i;
+ objs[0] = args;
+ for (i = 1; i < max; ++i) {
+ objs[i] = 0;
+ }
+ return 2;
+ }
PyErr_SetString(PyExc_SystemError, "UnpackTuple() argument list is not a tuple");
return 0;
} else {
#define SWIG_POINTER_IMPLICIT_CONV (SWIG_POINTER_DISOWN << 1)
+#define SWIG_BUILTIN_TP_INIT (SWIG_POINTER_OWN << 2)
+#define SWIG_BUILTIN_INIT (SWIG_BUILTIN_TP_INIT | SWIG_POINTER_OWN)
+
#ifdef __cplusplus
extern "C" {
-#if 0
-} /* cc-mode */
-#endif
#endif
/* How to access Py_None */
return none;
}
-/* PySwigClientData */
+/* SwigPyClientData */
typedef struct {
PyObject *klass;
PyObject *destroy;
int delargs;
int implicitconv;
-} PySwigClientData;
+ PyTypeObject *pytype;
+} SwigPyClientData;
SWIGRUNTIMEINLINE int
SWIG_Python_CheckImplicit(swig_type_info *ty)
{
- PySwigClientData *data = (PySwigClientData *)ty->clientdata;
+ SwigPyClientData *data = (SwigPyClientData *)ty->clientdata;
return data ? data->implicitconv : 0;
}
SWIGRUNTIMEINLINE PyObject *
SWIG_Python_ExceptionType(swig_type_info *desc) {
- PySwigClientData *data = desc ? (PySwigClientData *) desc->clientdata : 0;
+ SwigPyClientData *data = desc ? (SwigPyClientData *) desc->clientdata : 0;
PyObject *klass = data ? data->klass : 0;
return (klass ? klass : PyExc_RuntimeError);
}
-SWIGRUNTIME PySwigClientData *
-PySwigClientData_New(PyObject* obj)
+SWIGRUNTIME SwigPyClientData *
+SwigPyClientData_New(PyObject* obj)
{
if (!obj) {
return 0;
} else {
- PySwigClientData *data = (PySwigClientData *)malloc(sizeof(PySwigClientData));
+ SwigPyClientData *data = (SwigPyClientData *)malloc(sizeof(SwigPyClientData));
/* the klass element */
data->klass = obj;
Py_INCREF(data->klass);
data->delargs = 0;
}
data->implicitconv = 0;
+ data->pytype = 0;
return data;
}
}
SWIGRUNTIME void
-PySwigClientData_Del(PySwigClientData* data)
-{
+SwigPyClientData_Del(SwigPyClientData *data) {
Py_XDECREF(data->newraw);
Py_XDECREF(data->newargs);
Py_XDECREF(data->destroy);
}
-/* =============== PySwigObject =====================*/
+/* =============== SwigPyObject =====================*/
typedef struct {
PyObject_HEAD
swig_type_info *ty;
int own;
PyObject *next;
-} PySwigObject;
+#ifdef SWIGPYTHON_BUILTIN
+ PyObject *dict;
+#endif
+} SwigPyObject;
SWIGRUNTIME PyObject *
-PySwigObject_long(PySwigObject *v)
+SwigPyObject_long(SwigPyObject *v)
{
return PyLong_FromVoidPtr(v->ptr);
}
SWIGRUNTIME PyObject *
-PySwigObject_format(const char* fmt, PySwigObject *v)
+SwigPyObject_format(const char* fmt, SwigPyObject *v)
{
PyObject *res = NULL;
PyObject *args = PyTuple_New(1);
if (args) {
- if (PyTuple_SetItem(args, 0, PySwigObject_long(v)) == 0) {
- PyObject *ofmt = PyString_FromString(fmt);
+ if (PyTuple_SetItem(args, 0, SwigPyObject_long(v)) == 0) {
+ PyObject *ofmt = SWIG_Python_str_FromChar(fmt);
if (ofmt) {
+#if PY_VERSION_HEX >= 0x03000000
+ res = PyUnicode_Format(ofmt,args);
+#else
res = PyString_Format(ofmt,args);
+#endif
Py_DECREF(ofmt);
}
Py_DECREF(args);
}
SWIGRUNTIME PyObject *
-PySwigObject_oct(PySwigObject *v)
+SwigPyObject_oct(SwigPyObject *v)
{
- return PySwigObject_format("%o",v);
+ return SwigPyObject_format("%o",v);
}
SWIGRUNTIME PyObject *
-PySwigObject_hex(PySwigObject *v)
+SwigPyObject_hex(SwigPyObject *v)
{
- return PySwigObject_format("%x",v);
+ return SwigPyObject_format("%x",v);
}
SWIGRUNTIME PyObject *
#ifdef METH_NOARGS
-PySwigObject_repr(PySwigObject *v)
+SwigPyObject_repr(SwigPyObject *v)
#else
-PySwigObject_repr(PySwigObject *v, PyObject *args)
+SwigPyObject_repr(SwigPyObject *v, PyObject *args)
#endif
{
const char *name = SWIG_TypePrettyName(v->ty);
- PyObject *hex = PySwigObject_hex(v);
- PyObject *repr = PyString_FromFormat("<Swig Object of type '%s' at 0x%s>", name, PyString_AsString(hex));
- Py_DECREF(hex);
+ PyObject *repr = SWIG_Python_str_FromFormat("<Swig Object of type '%s' at %p>", (name ? name : "unknown"), (void *)v);
if (v->next) {
-#ifdef METH_NOARGS
- PyObject *nrep = PySwigObject_repr((PySwigObject *)v->next);
-#else
- PyObject *nrep = PySwigObject_repr((PySwigObject *)v->next, args);
-#endif
+# ifdef METH_NOARGS
+ PyObject *nrep = SwigPyObject_repr((SwigPyObject *)v->next);
+# else
+ PyObject *nrep = SwigPyObject_repr((SwigPyObject *)v->next, args);
+# endif
+# if PY_VERSION_HEX >= 0x03000000
+ PyObject *joined = PyUnicode_Concat(repr, nrep);
+ Py_DecRef(repr);
+ Py_DecRef(nrep);
+ repr = joined;
+# else
PyString_ConcatAndDel(&repr,nrep);
+# endif
}
return repr;
}
SWIGRUNTIME int
-PySwigObject_print(PySwigObject *v, FILE *fp, int SWIGUNUSEDPARM(flags))
+SwigPyObject_compare(SwigPyObject *v, SwigPyObject *w)
{
-#ifdef METH_NOARGS
- PyObject *repr = PySwigObject_repr(v);
-#else
- PyObject *repr = PySwigObject_repr(v, NULL);
-#endif
- if (repr) {
- fputs(PyString_AsString(repr), fp);
- Py_DECREF(repr);
- return 0;
- } else {
- return 1;
- }
+ void *i = v->ptr;
+ void *j = w->ptr;
+ return (i < j) ? -1 : ((i > j) ? 1 : 0);
}
-SWIGRUNTIME PyObject *
-PySwigObject_str(PySwigObject *v)
+/* Added for Python 3.x, would it also be useful for Python 2.x? */
+SWIGRUNTIME PyObject*
+SwigPyObject_richcompare(SwigPyObject *v, SwigPyObject *w, int op)
{
- char result[SWIG_BUFFER_SIZE];
- return SWIG_PackVoidPtr(result, v->ptr, v->ty->name, sizeof(result)) ?
- PyString_FromString(result) : 0;
+ PyObject* res;
+ if( op != Py_EQ && op != Py_NE ) {
+ Py_INCREF(Py_NotImplemented);
+ return Py_NotImplemented;
+ }
+ res = PyBool_FromLong( (SwigPyObject_compare(v, w)==0) == (op == Py_EQ) ? 1 : 0);
+ return res;
}
-SWIGRUNTIME int
-PySwigObject_compare(PySwigObject *v, PySwigObject *w)
-{
- void *i = v->ptr;
- void *j = w->ptr;
- return (i < j) ? -1 : ((i > j) ? 1 : 0);
-}
-SWIGRUNTIME PyTypeObject* _PySwigObject_type(void);
+SWIGRUNTIME PyTypeObject* SwigPyObject_TypeOnce(void);
+#ifdef SWIGPYTHON_BUILTIN
+static swig_type_info *SwigPyObject_stype = 0;
SWIGRUNTIME PyTypeObject*
-PySwigObject_type(void) {
- static PyTypeObject *SWIG_STATIC_POINTER(type) = _PySwigObject_type();
+SwigPyObject_type(void) {
+ SwigPyClientData *cd;
+ assert(SwigPyObject_stype);
+ cd = (SwigPyClientData*) SwigPyObject_stype->clientdata;
+ assert(cd);
+ assert(cd->pytype);
+ return cd->pytype;
+}
+#else
+SWIGRUNTIME PyTypeObject*
+SwigPyObject_type(void) {
+ static PyTypeObject *SWIG_STATIC_POINTER(type) = SwigPyObject_TypeOnce();
return type;
}
+#endif
SWIGRUNTIMEINLINE int
-PySwigObject_Check(PyObject *op) {
- return ((op)->ob_type == PySwigObject_type())
- || (strcmp((op)->ob_type->tp_name,"PySwigObject") == 0);
+SwigPyObject_Check(PyObject *op) {
+#ifdef SWIGPYTHON_BUILTIN
+ PyTypeObject *target_tp = SwigPyObject_type();
+ if (PyType_IsSubtype(op->ob_type, target_tp))
+ return 1;
+ return (strcmp(op->ob_type->tp_name, "SwigPyObject") == 0);
+#else
+ return (Py_TYPE(op) == SwigPyObject_type())
+ || (strcmp(Py_TYPE(op)->tp_name,"SwigPyObject") == 0);
+#endif
}
SWIGRUNTIME PyObject *
-PySwigObject_New(void *ptr, swig_type_info *ty, int own);
+SwigPyObject_New(void *ptr, swig_type_info *ty, int own);
SWIGRUNTIME void
-PySwigObject_dealloc(PyObject *v)
+SwigPyObject_dealloc(PyObject *v)
{
- PySwigObject *sobj = (PySwigObject *) v;
+ SwigPyObject *sobj = (SwigPyObject *) v;
PyObject *next = sobj->next;
if (sobj->own == SWIG_POINTER_OWN) {
swig_type_info *ty = sobj->ty;
- PySwigClientData *data = ty ? (PySwigClientData *) ty->clientdata : 0;
+ SwigPyClientData *data = ty ? (SwigPyClientData *) ty->clientdata : 0;
PyObject *destroy = data ? data->destroy : 0;
if (destroy) {
/* destroy is always a VARARGS method */
PyObject *res;
if (data->delargs) {
- /* we need to create a temporal object to carry the destroy operation */
- PyObject *tmp = PySwigObject_New(sobj->ptr, ty, 0);
+ /* we need to create a temporary object to carry the destroy operation */
+ PyObject *tmp = SwigPyObject_New(sobj->ptr, ty, 0);
res = SWIG_Python_CallFunctor(destroy, tmp);
Py_DECREF(tmp);
} else {
}
SWIGRUNTIME PyObject*
-PySwigObject_append(PyObject* v, PyObject* next)
+SwigPyObject_append(PyObject* v, PyObject* next)
{
- PySwigObject *sobj = (PySwigObject *) v;
+ SwigPyObject *sobj = (SwigPyObject *) v;
#ifndef METH_O
PyObject *tmp = 0;
if (!PyArg_ParseTuple(next,(char *)"O:append", &tmp)) return NULL;
next = tmp;
#endif
- if (!PySwigObject_Check(next)) {
+ if (!SwigPyObject_Check(next)) {
return NULL;
}
sobj->next = next;
SWIGRUNTIME PyObject*
#ifdef METH_NOARGS
-PySwigObject_next(PyObject* v)
+SwigPyObject_next(PyObject* v)
#else
-PySwigObject_next(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
+SwigPyObject_next(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
#endif
{
- PySwigObject *sobj = (PySwigObject *) v;
+ SwigPyObject *sobj = (SwigPyObject *) v;
if (sobj->next) {
Py_INCREF(sobj->next);
return sobj->next;
SWIGINTERN PyObject*
#ifdef METH_NOARGS
-PySwigObject_disown(PyObject *v)
+SwigPyObject_disown(PyObject *v)
#else
-PySwigObject_disown(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
+SwigPyObject_disown(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
#endif
{
- PySwigObject *sobj = (PySwigObject *)v;
+ SwigPyObject *sobj = (SwigPyObject *)v;
sobj->own = 0;
return SWIG_Py_Void();
}
SWIGINTERN PyObject*
#ifdef METH_NOARGS
-PySwigObject_acquire(PyObject *v)
+SwigPyObject_acquire(PyObject *v)
#else
-PySwigObject_acquire(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
+SwigPyObject_acquire(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
#endif
{
- PySwigObject *sobj = (PySwigObject *)v;
+ SwigPyObject *sobj = (SwigPyObject *)v;
sobj->own = SWIG_POINTER_OWN;
return SWIG_Py_Void();
}
SWIGINTERN PyObject*
-PySwigObject_own(PyObject *v, PyObject *args)
+SwigPyObject_own(PyObject *v, PyObject *args)
{
PyObject *val = 0;
#if (PY_VERSION_HEX < 0x02020000)
if (!PyArg_ParseTuple(args,(char *)"|O:own",&val))
-#else
+#elif (PY_VERSION_HEX < 0x02050000)
if (!PyArg_UnpackTuple(args, (char *)"own", 0, 1, &val))
+#else
+ if (!PyArg_UnpackTuple(args, "own", 0, 1, &val))
#endif
{
return NULL;
}
else
{
- PySwigObject *sobj = (PySwigObject *)v;
+ SwigPyObject *sobj = (SwigPyObject *)v;
PyObject *obj = PyBool_FromLong(sobj->own);
if (val) {
#ifdef METH_NOARGS
if (PyObject_IsTrue(val)) {
- PySwigObject_acquire(v);
+ SwigPyObject_acquire(v);
} else {
- PySwigObject_disown(v);
+ SwigPyObject_disown(v);
}
#else
if (PyObject_IsTrue(val)) {
- PySwigObject_acquire(v,args);
+ SwigPyObject_acquire(v,args);
} else {
- PySwigObject_disown(v,args);
+ SwigPyObject_disown(v,args);
}
#endif
}
#ifdef METH_O
static PyMethodDef
swigobject_methods[] = {
- {(char *)"disown", (PyCFunction)PySwigObject_disown, METH_NOARGS, (char *)"releases ownership of the pointer"},
- {(char *)"acquire", (PyCFunction)PySwigObject_acquire, METH_NOARGS, (char *)"aquires ownership of the pointer"},
- {(char *)"own", (PyCFunction)PySwigObject_own, METH_VARARGS, (char *)"returns/sets ownership of the pointer"},
- {(char *)"append", (PyCFunction)PySwigObject_append, METH_O, (char *)"appends another 'this' object"},
- {(char *)"next", (PyCFunction)PySwigObject_next, METH_NOARGS, (char *)"returns the next 'this' object"},
- {(char *)"__repr__",(PyCFunction)PySwigObject_repr, METH_NOARGS, (char *)"returns object representation"},
+ {(char *)"disown", (PyCFunction)SwigPyObject_disown, METH_NOARGS, (char *)"releases ownership of the pointer"},
+ {(char *)"acquire", (PyCFunction)SwigPyObject_acquire, METH_NOARGS, (char *)"acquires ownership of the pointer"},
+ {(char *)"own", (PyCFunction)SwigPyObject_own, METH_VARARGS, (char *)"returns/sets ownership of the pointer"},
+ {(char *)"append", (PyCFunction)SwigPyObject_append, METH_O, (char *)"appends another 'this' object"},
+ {(char *)"next", (PyCFunction)SwigPyObject_next, METH_NOARGS, (char *)"returns the next 'this' object"},
+ {(char *)"__repr__",(PyCFunction)SwigPyObject_repr, METH_NOARGS, (char *)"returns object representation"},
{0, 0, 0, 0}
};
#else
static PyMethodDef
swigobject_methods[] = {
- {(char *)"disown", (PyCFunction)PySwigObject_disown, METH_VARARGS, (char *)"releases ownership of the pointer"},
- {(char *)"acquire", (PyCFunction)PySwigObject_acquire, METH_VARARGS, (char *)"aquires ownership of the pointer"},
- {(char *)"own", (PyCFunction)PySwigObject_own, METH_VARARGS, (char *)"returns/sets ownership of the pointer"},
- {(char *)"append", (PyCFunction)PySwigObject_append, METH_VARARGS, (char *)"appends another 'this' object"},
- {(char *)"next", (PyCFunction)PySwigObject_next, METH_VARARGS, (char *)"returns the next 'this' object"},
- {(char *)"__repr__",(PyCFunction)PySwigObject_repr, METH_VARARGS, (char *)"returns object representation"},
+ {(char *)"disown", (PyCFunction)SwigPyObject_disown, METH_VARARGS, (char *)"releases ownership of the pointer"},
+ {(char *)"acquire", (PyCFunction)SwigPyObject_acquire, METH_VARARGS, (char *)"aquires ownership of the pointer"},
+ {(char *)"own", (PyCFunction)SwigPyObject_own, METH_VARARGS, (char *)"returns/sets ownership of the pointer"},
+ {(char *)"append", (PyCFunction)SwigPyObject_append, METH_VARARGS, (char *)"appends another 'this' object"},
+ {(char *)"next", (PyCFunction)SwigPyObject_next, METH_VARARGS, (char *)"returns the next 'this' object"},
+ {(char *)"__repr__",(PyCFunction)SwigPyObject_repr, METH_VARARGS, (char *)"returns object representation"},
{0, 0, 0, 0}
};
#endif
#if PY_VERSION_HEX < 0x02020000
SWIGINTERN PyObject *
-PySwigObject_getattr(PySwigObject *sobj,char *name)
+SwigPyObject_getattr(SwigPyObject *sobj,char *name)
{
return Py_FindMethod(swigobject_methods, (PyObject *)sobj, name);
}
#endif
SWIGRUNTIME PyTypeObject*
-_PySwigObject_type(void) {
+SwigPyObject_TypeOnce(void) {
static char swigobject_doc[] = "Swig object carries a C/C++ instance pointer";
-
- static PyNumberMethods PySwigObject_as_number = {
+
+ static PyNumberMethods SwigPyObject_as_number = {
(binaryfunc)0, /*nb_add*/
(binaryfunc)0, /*nb_subtract*/
(binaryfunc)0, /*nb_multiply*/
+ /* nb_divide removed in Python 3 */
+#if PY_VERSION_HEX < 0x03000000
(binaryfunc)0, /*nb_divide*/
+#endif
(binaryfunc)0, /*nb_remainder*/
(binaryfunc)0, /*nb_divmod*/
(ternaryfunc)0,/*nb_power*/
0, /*nb_and*/
0, /*nb_xor*/
0, /*nb_or*/
- (coercion)0, /*nb_coerce*/
- (unaryfunc)PySwigObject_long, /*nb_int*/
- (unaryfunc)PySwigObject_long, /*nb_long*/
+#if PY_VERSION_HEX < 0x03000000
+ 0, /*nb_coerce*/
+#endif
+ (unaryfunc)SwigPyObject_long, /*nb_int*/
+#if PY_VERSION_HEX < 0x03000000
+ (unaryfunc)SwigPyObject_long, /*nb_long*/
+#else
+ 0, /*nb_reserved*/
+#endif
(unaryfunc)0, /*nb_float*/
- (unaryfunc)PySwigObject_oct, /*nb_oct*/
- (unaryfunc)PySwigObject_hex, /*nb_hex*/
-#if PY_VERSION_HEX >= 0x02050000 /* 2.5.0 */
+#if PY_VERSION_HEX < 0x03000000
+ (unaryfunc)SwigPyObject_oct, /*nb_oct*/
+ (unaryfunc)SwigPyObject_hex, /*nb_hex*/
+#endif
+#if PY_VERSION_HEX >= 0x03000000 /* 3.0 */
+ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_index, nb_inplace_divide removed */
+#elif PY_VERSION_HEX >= 0x02050000 /* 2.5.0 */
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_index */
#elif PY_VERSION_HEX >= 0x02020000 /* 2.2.0 */
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_inplace_true_divide */
#endif
};
- static PyTypeObject pyswigobject_type;
+ static PyTypeObject swigpyobject_type;
static int type_init = 0;
if (!type_init) {
- const PyTypeObject tmp
- = {
- PyObject_HEAD_INIT(NULL)
- 0, /* ob_size */
- (char *)"PySwigObject", /* tp_name */
- sizeof(PySwigObject), /* tp_basicsize */
- 0, /* tp_itemsize */
- (destructor)PySwigObject_dealloc, /* tp_dealloc */
- (printfunc)PySwigObject_print, /* tp_print */
+ const PyTypeObject tmp = {
+ /* PyObject header changed in Python 3 */
+#if PY_VERSION_HEX >= 0x03000000
+ PyVarObject_HEAD_INIT(NULL, 0)
+#else
+ PyObject_HEAD_INIT(NULL)
+ 0, /* ob_size */
+#endif
+ (char *)"SwigPyObject", /* tp_name */
+ sizeof(SwigPyObject), /* tp_basicsize */
+ 0, /* tp_itemsize */
+ (destructor)SwigPyObject_dealloc, /* tp_dealloc */
+ 0, /* tp_print */
#if PY_VERSION_HEX < 0x02020000
- (getattrfunc)PySwigObject_getattr, /* tp_getattr */
+ (getattrfunc)SwigPyObject_getattr, /* tp_getattr */
#else
- (getattrfunc)0, /* tp_getattr */
-#endif
- (setattrfunc)0, /* tp_setattr */
- (cmpfunc)PySwigObject_compare, /* tp_compare */
- (reprfunc)PySwigObject_repr, /* tp_repr */
- &PySwigObject_as_number, /* tp_as_number */
- 0, /* tp_as_sequence */
- 0, /* tp_as_mapping */
- (hashfunc)0, /* tp_hash */
- (ternaryfunc)0, /* tp_call */
- (reprfunc)PySwigObject_str, /* tp_str */
- PyObject_GenericGetAttr, /* tp_getattro */
- 0, /* tp_setattro */
- 0, /* tp_as_buffer */
- Py_TPFLAGS_DEFAULT, /* tp_flags */
- swigobject_doc, /* tp_doc */
- 0, /* tp_traverse */
- 0, /* tp_clear */
- 0, /* tp_richcompare */
- 0, /* tp_weaklistoffset */
+ (getattrfunc)0, /* tp_getattr */
+#endif
+ (setattrfunc)0, /* tp_setattr */
+#if PY_VERSION_HEX >= 0x03000000
+ 0, /* tp_reserved in 3.0.1, tp_compare in 3.0.0 but not used */
+#else
+ (cmpfunc)SwigPyObject_compare, /* tp_compare */
+#endif
+ (reprfunc)SwigPyObject_repr, /* tp_repr */
+ &SwigPyObject_as_number, /* tp_as_number */
+ 0, /* tp_as_sequence */
+ 0, /* tp_as_mapping */
+ (hashfunc)0, /* tp_hash */
+ (ternaryfunc)0, /* tp_call */
+ 0, /* tp_str */
+ PyObject_GenericGetAttr, /* tp_getattro */
+ 0, /* tp_setattro */
+ 0, /* tp_as_buffer */
+ Py_TPFLAGS_DEFAULT, /* tp_flags */
+ swigobject_doc, /* tp_doc */
+ 0, /* tp_traverse */
+ 0, /* tp_clear */
+ (richcmpfunc)SwigPyObject_richcompare,/* tp_richcompare */
+ 0, /* tp_weaklistoffset */
#if PY_VERSION_HEX >= 0x02020000
- 0, /* tp_iter */
- 0, /* tp_iternext */
- swigobject_methods, /* tp_methods */
- 0, /* tp_members */
- 0, /* tp_getset */
- 0, /* tp_base */
- 0, /* tp_dict */
- 0, /* tp_descr_get */
- 0, /* tp_descr_set */
- 0, /* tp_dictoffset */
- 0, /* tp_init */
- 0, /* tp_alloc */
- 0, /* tp_new */
- 0, /* tp_free */
- 0, /* tp_is_gc */
- 0, /* tp_bases */
- 0, /* tp_mro */
- 0, /* tp_cache */
- 0, /* tp_subclasses */
- 0, /* tp_weaklist */
+ 0, /* tp_iter */
+ 0, /* tp_iternext */
+ swigobject_methods, /* tp_methods */
+ 0, /* tp_members */
+ 0, /* tp_getset */
+ 0, /* tp_base */
+ 0, /* tp_dict */
+ 0, /* tp_descr_get */
+ 0, /* tp_descr_set */
+ 0, /* tp_dictoffset */
+ 0, /* tp_init */
+ 0, /* tp_alloc */
+ 0, /* tp_new */
+ 0, /* tp_free */
+ 0, /* tp_is_gc */
+ 0, /* tp_bases */
+ 0, /* tp_mro */
+ 0, /* tp_cache */
+ 0, /* tp_subclasses */
+ 0, /* tp_weaklist */
#endif
#if PY_VERSION_HEX >= 0x02030000
- 0, /* tp_del */
+ 0, /* tp_del */
+#endif
+#if PY_VERSION_HEX >= 0x02060000
+ 0, /* tp_version */
#endif
#ifdef COUNT_ALLOCS
- 0,0,0,0 /* tp_alloc -> tp_next */
+ 0,0,0,0 /* tp_alloc -> tp_next */
#endif
- };
- pyswigobject_type = tmp;
- pyswigobject_type.ob_type = &PyType_Type;
+ };
+ swigpyobject_type = tmp;
type_init = 1;
+#if PY_VERSION_HEX < 0x02020000
+ swigpyobject_type.ob_type = &PyType_Type;
+#else
+ if (PyType_Ready(&swigpyobject_type) < 0)
+ return NULL;
+#endif
}
- return &pyswigobject_type;
+ return &swigpyobject_type;
}
SWIGRUNTIME PyObject *
-PySwigObject_New(void *ptr, swig_type_info *ty, int own)
+SwigPyObject_New(void *ptr, swig_type_info *ty, int own)
{
- PySwigObject *sobj = PyObject_NEW(PySwigObject, PySwigObject_type());
+ SwigPyObject *sobj = PyObject_NEW(SwigPyObject, SwigPyObject_type());
if (sobj) {
sobj->ptr = ptr;
sobj->ty = ty;
void *pack;
swig_type_info *ty;
size_t size;
-} PySwigPacked;
+} SwigPyPacked;
SWIGRUNTIME int
-PySwigPacked_print(PySwigPacked *v, FILE *fp, int SWIGUNUSEDPARM(flags))
+SwigPyPacked_print(SwigPyPacked *v, FILE *fp, int SWIGUNUSEDPARM(flags))
{
char result[SWIG_BUFFER_SIZE];
fputs("<Swig Packed ", fp);
}
SWIGRUNTIME PyObject *
-PySwigPacked_repr(PySwigPacked *v)
+SwigPyPacked_repr(SwigPyPacked *v)
{
char result[SWIG_BUFFER_SIZE];
if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))) {
- return PyString_FromFormat("<Swig Packed at %s%s>", result, v->ty->name);
+ return SWIG_Python_str_FromFormat("<Swig Packed at %s%s>", result, v->ty->name);
} else {
- return PyString_FromFormat("<Swig Packed %s>", v->ty->name);
+ return SWIG_Python_str_FromFormat("<Swig Packed %s>", v->ty->name);
}
}
SWIGRUNTIME PyObject *
-PySwigPacked_str(PySwigPacked *v)
+SwigPyPacked_str(SwigPyPacked *v)
{
char result[SWIG_BUFFER_SIZE];
if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))){
- return PyString_FromFormat("%s%s", result, v->ty->name);
+ return SWIG_Python_str_FromFormat("%s%s", result, v->ty->name);
} else {
- return PyString_FromString(v->ty->name);
+ return SWIG_Python_str_FromChar(v->ty->name);
}
}
SWIGRUNTIME int
-PySwigPacked_compare(PySwigPacked *v, PySwigPacked *w)
+SwigPyPacked_compare(SwigPyPacked *v, SwigPyPacked *w)
{
size_t i = v->size;
size_t j = w->size;
return s ? s : strncmp((char *)v->pack, (char *)w->pack, 2*v->size);
}
-SWIGRUNTIME PyTypeObject* _PySwigPacked_type(void);
+SWIGRUNTIME PyTypeObject* SwigPyPacked_TypeOnce(void);
SWIGRUNTIME PyTypeObject*
-PySwigPacked_type(void) {
- static PyTypeObject *SWIG_STATIC_POINTER(type) = _PySwigPacked_type();
+SwigPyPacked_type(void) {
+ static PyTypeObject *SWIG_STATIC_POINTER(type) = SwigPyPacked_TypeOnce();
return type;
}
SWIGRUNTIMEINLINE int
-PySwigPacked_Check(PyObject *op) {
- return ((op)->ob_type == _PySwigPacked_type())
- || (strcmp((op)->ob_type->tp_name,"PySwigPacked") == 0);
+SwigPyPacked_Check(PyObject *op) {
+ return ((op)->ob_type == SwigPyPacked_TypeOnce())
+ || (strcmp((op)->ob_type->tp_name,"SwigPyPacked") == 0);
}
SWIGRUNTIME void
-PySwigPacked_dealloc(PyObject *v)
+SwigPyPacked_dealloc(PyObject *v)
{
- if (PySwigPacked_Check(v)) {
- PySwigPacked *sobj = (PySwigPacked *) v;
+ if (SwigPyPacked_Check(v)) {
+ SwigPyPacked *sobj = (SwigPyPacked *) v;
free(sobj->pack);
}
PyObject_DEL(v);
}
SWIGRUNTIME PyTypeObject*
-_PySwigPacked_type(void) {
+SwigPyPacked_TypeOnce(void) {
static char swigpacked_doc[] = "Swig object carries a C/C++ instance pointer";
- static PyTypeObject pyswigpacked_type;
- static int type_init = 0;
+ static PyTypeObject swigpypacked_type;
+ static int type_init = 0;
if (!type_init) {
- const PyTypeObject tmp
- = {
- PyObject_HEAD_INIT(NULL)
- 0, /* ob_size */
- (char *)"PySwigPacked", /* tp_name */
- sizeof(PySwigPacked), /* tp_basicsize */
- 0, /* tp_itemsize */
- (destructor)PySwigPacked_dealloc, /* tp_dealloc */
- (printfunc)PySwigPacked_print, /* tp_print */
- (getattrfunc)0, /* tp_getattr */
- (setattrfunc)0, /* tp_setattr */
- (cmpfunc)PySwigPacked_compare, /* tp_compare */
- (reprfunc)PySwigPacked_repr, /* tp_repr */
- 0, /* tp_as_number */
- 0, /* tp_as_sequence */
- 0, /* tp_as_mapping */
- (hashfunc)0, /* tp_hash */
- (ternaryfunc)0, /* tp_call */
- (reprfunc)PySwigPacked_str, /* tp_str */
- PyObject_GenericGetAttr, /* tp_getattro */
- 0, /* tp_setattro */
- 0, /* tp_as_buffer */
- Py_TPFLAGS_DEFAULT, /* tp_flags */
- swigpacked_doc, /* tp_doc */
- 0, /* tp_traverse */
- 0, /* tp_clear */
- 0, /* tp_richcompare */
- 0, /* tp_weaklistoffset */
+ const PyTypeObject tmp = {
+ /* PyObject header changed in Python 3 */
+#if PY_VERSION_HEX>=0x03000000
+ PyVarObject_HEAD_INIT(NULL, 0)
+#else
+ PyObject_HEAD_INIT(NULL)
+ 0, /* ob_size */
+#endif
+ (char *)"SwigPyPacked", /* tp_name */
+ sizeof(SwigPyPacked), /* tp_basicsize */
+ 0, /* tp_itemsize */
+ (destructor)SwigPyPacked_dealloc, /* tp_dealloc */
+ (printfunc)SwigPyPacked_print, /* tp_print */
+ (getattrfunc)0, /* tp_getattr */
+ (setattrfunc)0, /* tp_setattr */
+#if PY_VERSION_HEX>=0x03000000
+ 0, /* tp_reserved in 3.0.1 */
+#else
+ (cmpfunc)SwigPyPacked_compare, /* tp_compare */
+#endif
+ (reprfunc)SwigPyPacked_repr, /* tp_repr */
+ 0, /* tp_as_number */
+ 0, /* tp_as_sequence */
+ 0, /* tp_as_mapping */
+ (hashfunc)0, /* tp_hash */
+ (ternaryfunc)0, /* tp_call */
+ (reprfunc)SwigPyPacked_str, /* tp_str */
+ PyObject_GenericGetAttr, /* tp_getattro */
+ 0, /* tp_setattro */
+ 0, /* tp_as_buffer */
+ Py_TPFLAGS_DEFAULT, /* tp_flags */
+ swigpacked_doc, /* tp_doc */
+ 0, /* tp_traverse */
+ 0, /* tp_clear */
+ 0, /* tp_richcompare */
+ 0, /* tp_weaklistoffset */
#if PY_VERSION_HEX >= 0x02020000
- 0, /* tp_iter */
- 0, /* tp_iternext */
- 0, /* tp_methods */
- 0, /* tp_members */
- 0, /* tp_getset */
- 0, /* tp_base */
- 0, /* tp_dict */
- 0, /* tp_descr_get */
- 0, /* tp_descr_set */
- 0, /* tp_dictoffset */
- 0, /* tp_init */
- 0, /* tp_alloc */
- 0, /* tp_new */
- 0, /* tp_free */
- 0, /* tp_is_gc */
- 0, /* tp_bases */
- 0, /* tp_mro */
- 0, /* tp_cache */
- 0, /* tp_subclasses */
- 0, /* tp_weaklist */
+ 0, /* tp_iter */
+ 0, /* tp_iternext */
+ 0, /* tp_methods */
+ 0, /* tp_members */
+ 0, /* tp_getset */
+ 0, /* tp_base */
+ 0, /* tp_dict */
+ 0, /* tp_descr_get */
+ 0, /* tp_descr_set */
+ 0, /* tp_dictoffset */
+ 0, /* tp_init */
+ 0, /* tp_alloc */
+ 0, /* tp_new */
+ 0, /* tp_free */
+ 0, /* tp_is_gc */
+ 0, /* tp_bases */
+ 0, /* tp_mro */
+ 0, /* tp_cache */
+ 0, /* tp_subclasses */
+ 0, /* tp_weaklist */
#endif
#if PY_VERSION_HEX >= 0x02030000
- 0, /* tp_del */
+ 0, /* tp_del */
+#endif
+#if PY_VERSION_HEX >= 0x02060000
+ 0, /* tp_version */
#endif
#ifdef COUNT_ALLOCS
- 0,0,0,0 /* tp_alloc -> tp_next */
+ 0,0,0,0 /* tp_alloc -> tp_next */
#endif
- };
- pyswigpacked_type = tmp;
- pyswigpacked_type.ob_type = &PyType_Type;
+ };
+ swigpypacked_type = tmp;
type_init = 1;
+#if PY_VERSION_HEX < 0x02020000
+ swigpypacked_type.ob_type = &PyType_Type;
+#else
+ if (PyType_Ready(&swigpypacked_type) < 0)
+ return NULL;
+#endif
}
- return &pyswigpacked_type;
+ return &swigpypacked_type;
}
SWIGRUNTIME PyObject *
-PySwigPacked_New(void *ptr, size_t size, swig_type_info *ty)
+SwigPyPacked_New(void *ptr, size_t size, swig_type_info *ty)
{
- PySwigPacked *sobj = PyObject_NEW(PySwigPacked, PySwigPacked_type());
+ SwigPyPacked *sobj = PyObject_NEW(SwigPyPacked, SwigPyPacked_type());
if (sobj) {
void *pack = malloc(size);
if (pack) {
}
SWIGRUNTIME swig_type_info *
-PySwigPacked_UnpackData(PyObject *obj, void *ptr, size_t size)
+SwigPyPacked_UnpackData(PyObject *obj, void *ptr, size_t size)
{
- if (PySwigPacked_Check(obj)) {
- PySwigPacked *sobj = (PySwigPacked *)obj;
+ if (SwigPyPacked_Check(obj)) {
+ SwigPyPacked *sobj = (SwigPyPacked *)obj;
if (sobj->size != size) return 0;
memcpy(ptr, sobj->pack, size);
return sobj->ty;
SWIGRUNTIMEINLINE PyObject *
_SWIG_This(void)
{
- return PyString_FromString("this");
+ return SWIG_Python_str_FromChar("this");
}
+static PyObject *swig_this = NULL;
+
SWIGRUNTIME PyObject *
SWIG_This(void)
{
- static PyObject *SWIG_STATIC_POINTER(swig_this) = _SWIG_This();
+ if (swig_this == NULL)
+ swig_this = _SWIG_This();
return swig_this;
}
/* #define SWIG_PYTHON_SLOW_GETSET_THIS */
-SWIGRUNTIME PySwigObject *
+/* TODO: I don't know how to implement the fast getset in Python 3 right now */
+#if PY_VERSION_HEX>=0x03000000
+#define SWIG_PYTHON_SLOW_GETSET_THIS
+#endif
+
+SWIGRUNTIME SwigPyObject *
SWIG_Python_GetSwigThis(PyObject *pyobj)
{
- if (PySwigObject_Check(pyobj)) {
- return (PySwigObject *) pyobj;
- } else {
- PyObject *obj = 0;
+ PyObject *obj;
+
+ if (SwigPyObject_Check(pyobj))
+ return (SwigPyObject *) pyobj;
+
+#ifdef SWIGPYTHON_BUILTIN
+ (void)obj;
+# ifdef PyWeakref_CheckProxy
+ if (PyWeakref_CheckProxy(pyobj)) {
+ pyobj = PyWeakref_GET_OBJECT(pyobj);
+ if (pyobj && SwigPyObject_Check(pyobj))
+ return (SwigPyObject*) pyobj;
+ }
+# endif
+ return NULL;
+#else
+
+ obj = 0;
+
#if (!defined(SWIG_PYTHON_SLOW_GETSET_THIS) && (PY_VERSION_HEX >= 0x02030000))
- if (PyInstance_Check(pyobj)) {
- obj = _PyInstance_Lookup(pyobj, SWIG_This());
+ if (PyInstance_Check(pyobj)) {
+ obj = _PyInstance_Lookup(pyobj, SWIG_This());
+ } else {
+ PyObject **dictptr = _PyObject_GetDictPtr(pyobj);
+ if (dictptr != NULL) {
+ PyObject *dict = *dictptr;
+ obj = dict ? PyDict_GetItem(dict, SWIG_This()) : 0;
} else {
- PyObject **dictptr = _PyObject_GetDictPtr(pyobj);
- if (dictptr != NULL) {
- PyObject *dict = *dictptr;
- obj = dict ? PyDict_GetItem(dict, SWIG_This()) : 0;
- } else {
#ifdef PyWeakref_CheckProxy
- if (PyWeakref_CheckProxy(pyobj)) {
- PyObject *wobj = PyWeakref_GET_OBJECT(pyobj);
- return wobj ? SWIG_Python_GetSwigThis(wobj) : 0;
- }
+ if (PyWeakref_CheckProxy(pyobj)) {
+ PyObject *wobj = PyWeakref_GET_OBJECT(pyobj);
+ return wobj ? SWIG_Python_GetSwigThis(wobj) : 0;
+ }
#endif
- obj = PyObject_GetAttr(pyobj,SWIG_This());
- if (obj) {
- Py_DECREF(obj);
- } else {
- if (PyErr_Occurred()) PyErr_Clear();
- return 0;
- }
+ obj = PyObject_GetAttr(pyobj,SWIG_This());
+ if (obj) {
+ Py_DECREF(obj);
+ } else {
+ if (PyErr_Occurred()) PyErr_Clear();
+ return 0;
}
}
+ }
#else
- obj = PyObject_GetAttr(pyobj,SWIG_This());
- if (obj) {
- Py_DECREF(obj);
- } else {
- if (PyErr_Occurred()) PyErr_Clear();
- return 0;
- }
+ obj = PyObject_GetAttr(pyobj,SWIG_This());
+ if (obj) {
+ Py_DECREF(obj);
+ } else {
+ if (PyErr_Occurred()) PyErr_Clear();
+ return 0;
+ }
#endif
- if (obj && !PySwigObject_Check(obj)) {
- /* a PyObject is called 'this', try to get the 'real this'
- PySwigObject from it */
- return SWIG_Python_GetSwigThis(obj);
- }
- return (PySwigObject *)obj;
+ if (obj && !SwigPyObject_Check(obj)) {
+ /* a PyObject is called 'this', try to get the 'real this'
+ SwigPyObject from it */
+ return SWIG_Python_GetSwigThis(obj);
}
+ return (SwigPyObject *)obj;
+#endif
}
/* Acquire a pointer value */
SWIGRUNTIME int
SWIG_Python_AcquirePtr(PyObject *obj, int own) {
if (own == SWIG_POINTER_OWN) {
- PySwigObject *sobj = SWIG_Python_GetSwigThis(obj);
+ SwigPyObject *sobj = SWIG_Python_GetSwigThis(obj);
if (sobj) {
int oldown = sobj->own;
sobj->own = own;
SWIGRUNTIME int
SWIG_Python_ConvertPtrAndOwn(PyObject *obj, void **ptr, swig_type_info *ty, int flags, int *own) {
- if (!obj) return SWIG_ERROR;
- if (obj == Py_None) {
- if (ptr) *ptr = 0;
+ int res;
+ SwigPyObject *sobj;
+ int implicit_conv = (flags & SWIG_POINTER_IMPLICIT_CONV) != 0;
+
+ if (!obj)
+ return SWIG_ERROR;
+ if (obj == Py_None && !implicit_conv) {
+ if (ptr)
+ *ptr = 0;
return SWIG_OK;
- } else {
- PySwigObject *sobj = SWIG_Python_GetSwigThis(obj);
+ }
+
+ res = SWIG_ERROR;
+
+ sobj = SWIG_Python_GetSwigThis(obj);
+ if (own)
+ *own = 0;
+ while (sobj) {
+ void *vptr = sobj->ptr;
+ if (ty) {
+ swig_type_info *to = sobj->ty;
+ if (to == ty) {
+ /* no type cast needed */
+ if (ptr) *ptr = vptr;
+ break;
+ } else {
+ swig_cast_info *tc = SWIG_TypeCheck(to->name,ty);
+ if (!tc) {
+ sobj = (SwigPyObject *)sobj->next;
+ } else {
+ if (ptr) {
+ int newmemory = 0;
+ *ptr = SWIG_TypeCast(tc,vptr,&newmemory);
+ if (newmemory == SWIG_CAST_NEW_MEMORY) {
+ assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */
+ if (own)
+ *own = *own | SWIG_CAST_NEW_MEMORY;
+ }
+ }
+ break;
+ }
+ }
+ } else {
+ if (ptr) *ptr = vptr;
+ break;
+ }
+ }
+ if (sobj) {
if (own)
- *own = 0;
- while (sobj) {
- void *vptr = sobj->ptr;
- if (ty) {
- swig_type_info *to = sobj->ty;
- if (to == ty) {
- /* no type cast needed */
- if (ptr) *ptr = vptr;
- break;
- } else {
- swig_cast_info *tc = SWIG_TypeCheck(to->name,ty);
- if (!tc) {
- sobj = (PySwigObject *)sobj->next;
- } else {
- if (ptr) {
- int newmemory = 0;
- *ptr = SWIG_TypeCast(tc,vptr,&newmemory);
- if (newmemory == SWIG_CAST_NEW_MEMORY) {
- assert(own);
- if (own)
- *own = *own | SWIG_CAST_NEW_MEMORY;
+ *own = *own | sobj->own;
+ if (flags & SWIG_POINTER_DISOWN) {
+ sobj->own = 0;
+ }
+ res = SWIG_OK;
+ } else {
+ if (implicit_conv) {
+ SwigPyClientData *data = ty ? (SwigPyClientData *) ty->clientdata : 0;
+ if (data && !data->implicitconv) {
+ PyObject *klass = data->klass;
+ if (klass) {
+ PyObject *impconv;
+ data->implicitconv = 1; /* avoid recursion and call 'explicit' constructors*/
+ impconv = SWIG_Python_CallFunctor(klass, obj);
+ data->implicitconv = 0;
+ if (PyErr_Occurred()) {
+ PyErr_Clear();
+ impconv = 0;
+ }
+ if (impconv) {
+ SwigPyObject *iobj = SWIG_Python_GetSwigThis(impconv);
+ if (iobj) {
+ void *vptr;
+ res = SWIG_Python_ConvertPtrAndOwn((PyObject*)iobj, &vptr, ty, 0, 0);
+ if (SWIG_IsOK(res)) {
+ if (ptr) {
+ *ptr = vptr;
+ /* transfer the ownership to 'ptr' */
+ iobj->own = 0;
+ res = SWIG_AddCast(res);
+ res = SWIG_AddNewMask(res);
+ } else {
+ res = SWIG_AddCast(res);
+ }
}
}
- break;
- }
- }
- } else {
- if (ptr) *ptr = vptr;
- break;
+ Py_DECREF(impconv);
+ }
+ }
}
}
- if (sobj) {
- if (own)
- *own = *own | sobj->own;
- if (flags & SWIG_POINTER_DISOWN) {
- sobj->own = 0;
- }
- return SWIG_OK;
- } else {
- int res = SWIG_ERROR;
- if (flags & SWIG_POINTER_IMPLICIT_CONV) {
- PySwigClientData *data = ty ? (PySwigClientData *) ty->clientdata : 0;
- if (data && !data->implicitconv) {
- PyObject *klass = data->klass;
- if (klass) {
- PyObject *impconv;
- data->implicitconv = 1; /* avoid recursion and call 'explicit' constructors*/
- impconv = SWIG_Python_CallFunctor(klass, obj);
- data->implicitconv = 0;
- if (PyErr_Occurred()) {
- PyErr_Clear();
- impconv = 0;
- }
- if (impconv) {
- PySwigObject *iobj = SWIG_Python_GetSwigThis(impconv);
- if (iobj) {
- void *vptr;
- res = SWIG_Python_ConvertPtrAndOwn((PyObject*)iobj, &vptr, ty, 0, 0);
- if (SWIG_IsOK(res)) {
- if (ptr) {
- *ptr = vptr;
- /* transfer the ownership to 'ptr' */
- iobj->own = 0;
- res = SWIG_AddCast(res);
- res = SWIG_AddNewMask(res);
- } else {
- res = SWIG_AddCast(res);
- }
- }
- }
- Py_DECREF(impconv);
- }
- }
- }
- }
- return res;
+ if (!SWIG_IsOK(res) && obj == Py_None) {
+ if (ptr)
+ *ptr = 0;
+ if (PyErr_Occurred())
+ PyErr_Clear();
+ res = SWIG_OK;
}
}
+ return res;
}
/* Convert a function ptr value */
/* here we get the method pointer for callbacks */
const char *doc = (((PyCFunctionObject *)obj) -> m_ml -> ml_doc);
const char *desc = doc ? strstr(doc, "swig_ptr: ") : 0;
- if (desc) {
+ if (desc)
desc = ty ? SWIG_UnpackVoidPtr(desc + 10, &vptr, ty->name) : 0;
- if (!desc) return SWIG_ERROR;
- }
+ if (!desc)
+ return SWIG_ERROR;
if (ty) {
swig_cast_info *tc = SWIG_TypeCheck(desc,ty);
if (tc) {
SWIGRUNTIME int
SWIG_Python_ConvertPacked(PyObject *obj, void *ptr, size_t sz, swig_type_info *ty) {
- swig_type_info *to = PySwigPacked_UnpackData(obj, ptr, sz);
+ swig_type_info *to = SwigPyPacked_UnpackData(obj, ptr, sz);
if (!to) return SWIG_ERROR;
if (ty) {
if (to != ty) {
* ----------------------------------------------------------------------------- */
/*
- Create a new instance object, whitout calling __init__, and set the
+ Create a new instance object, without calling __init__, and set the
'this' attribute.
*/
SWIGRUNTIME PyObject*
-SWIG_Python_NewShadowInstance(PySwigClientData *data, PyObject *swig_this)
+SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this)
{
#if (PY_VERSION_HEX >= 0x02020000)
PyObject *inst = 0;
#endif
}
} else {
+#if PY_VERSION_HEX >= 0x03000000
+ inst = PyBaseObject_Type.tp_new((PyTypeObject*) data->newargs, Py_None, Py_None);
+ if (inst) {
+ PyObject_SetAttr(inst, SWIG_This(), swig_this);
+ Py_TYPE(inst)->tp_flags &= ~Py_TPFLAGS_VALID_VERSION_TAG;
+ }
+#else
PyObject *dict = PyDict_New();
- PyDict_SetItem(dict, SWIG_This(), swig_this);
- inst = PyInstance_NewRaw(data->newargs, dict);
- Py_DECREF(dict);
+ if (dict) {
+ PyDict_SetItem(dict, SWIG_This(), swig_this);
+ inst = PyInstance_NewRaw(data->newargs, dict);
+ Py_DECREF(dict);
+ }
+#endif
}
return inst;
#else
#if (PY_VERSION_HEX >= 0x02010000)
- PyObject *inst;
+ PyObject *inst = 0;
PyObject *dict = PyDict_New();
- PyDict_SetItem(dict, SWIG_This(), swig_this);
- inst = PyInstance_NewRaw(data->newargs, dict);
- Py_DECREF(dict);
+ if (dict) {
+ PyDict_SetItem(dict, SWIG_This(), swig_this);
+ inst = PyInstance_NewRaw(data->newargs, dict);
+ Py_DECREF(dict);
+ }
return (PyObject *) inst;
#else
PyInstanceObject *inst = PyObject_NEW(PyInstanceObject, &PyInstance_Type);
SWIGINTERN PyObject *
SWIG_Python_InitShadowInstance(PyObject *args) {
PyObject *obj[2];
- if (!SWIG_Python_UnpackTuple(args,(char*)"swiginit", 2, 2, obj)) {
+ if (!SWIG_Python_UnpackTuple(args, "swiginit", 2, 2, obj)) {
return NULL;
} else {
- PySwigObject *sthis = SWIG_Python_GetSwigThis(obj[0]);
+ SwigPyObject *sthis = SWIG_Python_GetSwigThis(obj[0]);
if (sthis) {
- PySwigObject_append((PyObject*) sthis, obj[1]);
+ SwigPyObject_append((PyObject*) sthis, obj[1]);
} else {
SWIG_Python_SetSwigThis(obj[0], obj[1]);
}
/* Create a new pointer object */
SWIGRUNTIME PyObject *
-SWIG_Python_NewPointerObj(void *ptr, swig_type_info *type, int flags) {
- if (!ptr) {
+SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int flags) {
+ SwigPyClientData *clientdata;
+ PyObject * robj;
+ int own;
+
+ if (!ptr)
return SWIG_Py_Void();
- } else {
- int own = (flags & SWIG_POINTER_OWN) ? SWIG_POINTER_OWN : 0;
- PyObject *robj = PySwigObject_New(ptr, type, own);
- PySwigClientData *clientdata = type ? (PySwigClientData *)(type->clientdata) : 0;
- if (clientdata && !(flags & SWIG_POINTER_NOSHADOW)) {
- PyObject *inst = SWIG_Python_NewShadowInstance(clientdata, robj);
- if (inst) {
- Py_DECREF(robj);
- robj = inst;
+
+ clientdata = type ? (SwigPyClientData *)(type->clientdata) : 0;
+ own = (flags & SWIG_POINTER_OWN) ? SWIG_POINTER_OWN : 0;
+ if (clientdata && clientdata->pytype) {
+ SwigPyObject *newobj;
+ if (flags & SWIG_BUILTIN_TP_INIT) {
+ newobj = (SwigPyObject*) self;
+ if (newobj->ptr) {
+ PyObject *next_self = clientdata->pytype->tp_alloc(clientdata->pytype, 0);
+ while (newobj->next)
+ newobj = (SwigPyObject *) newobj->next;
+ newobj->next = next_self;
+ newobj = (SwigPyObject *)next_self;
}
+ } else {
+ newobj = PyObject_New(SwigPyObject, clientdata->pytype);
+ }
+ if (newobj) {
+ newobj->ptr = ptr;
+ newobj->ty = type;
+ newobj->own = own;
+ newobj->next = 0;
+#ifdef SWIGPYTHON_BUILTIN
+ newobj->dict = 0;
+#endif
+ return (PyObject*) newobj;
}
- return robj;
+ return SWIG_Py_Void();
}
+
+ assert(!(flags & SWIG_BUILTIN_TP_INIT));
+
+ robj = SwigPyObject_New(ptr, type, own);
+ if (robj && clientdata && !(flags & SWIG_POINTER_NOSHADOW)) {
+ PyObject *inst = SWIG_Python_NewShadowInstance(clientdata, robj);
+ Py_DECREF(robj);
+ robj = inst;
+ }
+ return robj;
}
/* Create a new packed object */
SWIGRUNTIMEINLINE PyObject *
SWIG_Python_NewPackedObj(void *ptr, size_t sz, swig_type_info *type) {
- return ptr ? PySwigPacked_New((void *) ptr, sz, type) : SWIG_Py_Void();
+ return ptr ? SwigPyPacked_New((void *) ptr, sz, type) : SWIG_Py_Void();
}
/* -----------------------------------------------------------------------------*
#endif
SWIGRUNTIME swig_module_info *
-SWIG_Python_GetModule(void) {
+SWIG_Python_GetModule(void *SWIGUNUSEDPARM(clientdata)) {
static void *type_pointer = (void *)0;
/* first check if module already created */
if (!type_pointer) {
#ifdef SWIG_LINK_RUNTIME
type_pointer = SWIG_ReturnGlobalTypeList((void *)0);
#else
+# ifdef SWIGPY_USE_CAPSULE
+ type_pointer = PyCapsule_Import(SWIGPY_CAPSULE_NAME, 0);
+# else
type_pointer = PyCObject_Import((char*)"swig_runtime_data" SWIG_RUNTIME_VERSION,
(char*)"type_pointer" SWIG_TYPE_TABLE_NAME);
+# endif
if (PyErr_Occurred()) {
PyErr_Clear();
type_pointer = (void *)0;
#endif
SWIGRUNTIME void
+#ifdef SWIGPY_USE_CAPSULE
+SWIG_Python_DestroyModule(PyObject *obj)
+#else
SWIG_Python_DestroyModule(void *vptr)
+#endif
{
+#ifdef SWIGPY_USE_CAPSULE
+ swig_module_info *swig_module = (swig_module_info *) PyCapsule_GetPointer(obj, SWIGPY_CAPSULE_NAME);
+#else
swig_module_info *swig_module = (swig_module_info *) vptr;
+#endif
swig_type_info **types = swig_module->types;
size_t i;
for (i =0; i < swig_module->size; ++i) {
swig_type_info *ty = types[i];
if (ty->owndata) {
- PySwigClientData *data = (PySwigClientData *) ty->clientdata;
- if (data) PySwigClientData_Del(data);
+ SwigPyClientData *data = (SwigPyClientData *) ty->clientdata;
+ if (data) SwigPyClientData_Del(data);
}
}
Py_DECREF(SWIG_This());
+ swig_this = NULL;
}
SWIGRUNTIME void
SWIG_Python_SetModule(swig_module_info *swig_module) {
- static PyMethodDef swig_empty_runtime_method_table[] = { {NULL, NULL, 0, NULL} };/* Sentinel */
-
- PyObject *module = Py_InitModule((char*)"swig_runtime_data" SWIG_RUNTIME_VERSION,
- swig_empty_runtime_method_table);
+#if PY_VERSION_HEX >= 0x03000000
+ /* Add a dummy module object into sys.modules */
+ PyObject *module = PyImport_AddModule((char*)"swig_runtime_data" SWIG_RUNTIME_VERSION);
+#else
+ static PyMethodDef swig_empty_runtime_method_table[] = { {NULL, NULL, 0, NULL} }; /* Sentinel */
+ PyObject *module = Py_InitModule((char*)"swig_runtime_data" SWIG_RUNTIME_VERSION, swig_empty_runtime_method_table);
+#endif
+#ifdef SWIGPY_USE_CAPSULE
+ PyObject *pointer = PyCapsule_New((void *) swig_module, SWIGPY_CAPSULE_NAME, SWIG_Python_DestroyModule);
+ if (pointer && module) {
+ PyModule_AddObject(module, (char*)"type_pointer_capsule" SWIG_TYPE_TABLE_NAME, pointer);
+ } else {
+ Py_XDECREF(pointer);
+ }
+#else
PyObject *pointer = PyCObject_FromVoidPtr((void *) swig_module, SWIG_Python_DestroyModule);
if (pointer && module) {
PyModule_AddObject(module, (char*)"type_pointer" SWIG_TYPE_TABLE_NAME, pointer);
} else {
Py_XDECREF(pointer);
}
+#endif
}
/* The python cached type query */
SWIG_Python_TypeQuery(const char *type)
{
PyObject *cache = SWIG_Python_TypeCache();
- PyObject *key = PyString_FromString(type);
+ PyObject *key = SWIG_Python_str_FromChar(type);
PyObject *obj = PyDict_GetItem(cache, key);
swig_type_info *descriptor;
if (obj) {
+#ifdef SWIGPY_USE_CAPSULE
+ descriptor = (swig_type_info *) PyCapsule_GetPointer(obj, NULL);
+#else
descriptor = (swig_type_info *) PyCObject_AsVoidPtr(obj);
+#endif
} else {
- swig_module_info *swig_module = SWIG_Python_GetModule();
+ swig_module_info *swig_module = SWIG_GetModule(0);
descriptor = SWIG_TypeQueryModule(swig_module, swig_module, type);
if (descriptor) {
+#ifdef SWIGPY_USE_CAPSULE
+ obj = PyCapsule_New((void*) descriptor, NULL, NULL);
+#else
obj = PyCObject_FromVoidPtr(descriptor, NULL);
+#endif
PyDict_SetItem(cache, key, obj);
Py_DECREF(obj);
}
SWIGRUNTIME int
SWIG_Python_AddErrMesg(const char* mesg, int infront)
-{
+{
if (PyErr_Occurred()) {
PyObject *type = 0;
PyObject *value = 0;
PyObject *traceback = 0;
PyErr_Fetch(&type, &value, &traceback);
if (value) {
+ char *tmp;
PyObject *old_str = PyObject_Str(value);
Py_XINCREF(type);
PyErr_Clear();
if (infront) {
- PyErr_Format(type, "%s %s", mesg, PyString_AsString(old_str));
+ PyErr_Format(type, "%s %s", mesg, tmp = SWIG_Python_str_AsChar(old_str));
} else {
- PyErr_Format(type, "%s %s", PyString_AsString(old_str), mesg);
+ PyErr_Format(type, "%s %s", tmp = SWIG_Python_str_AsChar(old_str), mesg);
}
+ SWIG_Python_str_DelForPy3(tmp);
Py_DECREF(old_str);
}
return 1;
}
SWIGRUNTIMEINLINE const char *
-PySwigObject_GetDesc(PyObject *self)
+SwigPyObject_GetDesc(PyObject *self)
{
- PySwigObject *v = (PySwigObject *)self;
+ SwigPyObject *v = (SwigPyObject *)self;
swig_type_info *ty = v ? v->ty : 0;
- return ty ? ty->str : (char*)"";
+ return ty ? ty->str : "";
}
SWIGRUNTIME void
{
if (type) {
#if defined(SWIG_COBJECT_TYPES)
- if (obj && PySwigObject_Check(obj)) {
- const char *otype = (const char *) PySwigObject_GetDesc(obj);
+ if (obj && SwigPyObject_Check(obj)) {
+ const char *otype = (const char *) SwigPyObject_GetDesc(obj);
if (otype) {
- PyErr_Format(PyExc_TypeError, "a '%s' is expected, 'PySwigObject(%s)' is received",
+ PyErr_Format(PyExc_TypeError, "a '%s' is expected, 'SwigPyObject(%s)' is received",
type, otype);
return;
}
const char *otype = (obj ? obj->ob_type->tp_name : 0);
if (otype) {
PyObject *str = PyObject_Str(obj);
- const char *cstr = str ? PyString_AsString(str) : 0;
+ const char *cstr = str ? SWIG_Python_str_AsChar(str) : 0;
if (cstr) {
PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s(%s)' is received",
type, otype, cstr);
+ SWIG_Python_str_DelForPy3(cstr);
} else {
PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s' is received",
type, otype);
/* Convert a pointer value, signal an exception on a type mismatch */
SWIGRUNTIME void *
-SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int argnum, int flags) {
+SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int SWIGUNUSEDPARM(argnum), int flags) {
void *result;
if (SWIG_Python_ConvertPtr(obj, &result, ty, flags) == -1) {
PyErr_Clear();
- if (flags & SWIG_POINTER_EXCEPTION) {
+#if SWIG_POINTER_EXCEPTION
+ if (flags) {
SWIG_Python_TypeError(SWIG_TypePrettyName(ty), obj);
SWIG_Python_ArgFail(argnum);
}
+#endif
}
return result;
}
+#ifdef SWIGPYTHON_BUILTIN
+SWIGRUNTIME int
+SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
+ PyTypeObject *tp = obj->ob_type;
+ PyObject *descr;
+ PyObject *encoded_name;
+ descrsetfunc f;
+ int res = -1;
+
+# ifdef Py_USING_UNICODE
+ if (PyString_Check(name)) {
+ name = PyUnicode_Decode(PyString_AsString(name), PyString_Size(name), NULL, NULL);
+ if (!name)
+ return -1;
+ } else if (!PyUnicode_Check(name))
+# else
+ if (!PyString_Check(name))
+# endif
+ {
+ PyErr_Format(PyExc_TypeError, "attribute name must be string, not '%.200s'", name->ob_type->tp_name);
+ return -1;
+ } else {
+ Py_INCREF(name);
+ }
-#ifdef __cplusplus
-#if 0
-{ /* cc-mode */
+ if (!tp->tp_dict) {
+ if (PyType_Ready(tp) < 0)
+ goto done;
+ }
+
+ descr = _PyType_Lookup(tp, name);
+ f = NULL;
+ if (descr != NULL)
+ f = descr->ob_type->tp_descr_set;
+ if (!f) {
+ if (PyString_Check(name)) {
+ encoded_name = name;
+ Py_INCREF(name);
+ } else {
+ encoded_name = PyUnicode_AsUTF8String(name);
+ }
+ PyErr_Format(PyExc_AttributeError, "'%.100s' object has no attribute '%.200s'", tp->tp_name, PyString_AsString(encoded_name));
+ Py_DECREF(encoded_name);
+ } else {
+ res = f(descr, obj, value);
+ }
+
+ done:
+ Py_DECREF(name);
+ return res;
+}
#endif
+
+
+#ifdef __cplusplus
}
#endif
/*-----------------------------------------------
@(target):= _ESL.so
------------------------------------------------*/
-#define SWIG_init init_ESL
+#if PY_VERSION_HEX >= 0x03000000
+# define SWIG_init PyInit__ESL
+
+#else
+# define SWIG_init init_ESL
+#endif
#define SWIG_name "_ESL"
-#define SWIGVERSION 0x010335
+#define SWIGVERSION 0x020012
#define SWIG_VERSION SWIGVERSION
namespace swig {
- class PyObject_ptr {
+ class SwigPtr_PyObject {
protected:
PyObject *_obj;
public:
- PyObject_ptr() :_obj(0)
+ SwigPtr_PyObject() :_obj(0)
{
}
- PyObject_ptr(const PyObject_ptr& item) : _obj(item._obj)
+ SwigPtr_PyObject(const SwigPtr_PyObject& item) : _obj(item._obj)
{
Py_XINCREF(_obj);
}
- PyObject_ptr(PyObject *obj, bool initial_ref = true) :_obj(obj)
+ SwigPtr_PyObject(PyObject *obj, bool initial_ref = true) :_obj(obj)
{
if (initial_ref) {
Py_XINCREF(_obj);
}
}
- PyObject_ptr & operator=(const PyObject_ptr& item)
+ SwigPtr_PyObject & operator=(const SwigPtr_PyObject& item)
{
Py_XINCREF(item._obj);
Py_XDECREF(_obj);
return *this;
}
- ~PyObject_ptr()
+ ~SwigPtr_PyObject()
{
Py_XDECREF(_obj);
}
namespace swig {
- struct PyObject_var : PyObject_ptr {
- PyObject_var(PyObject* obj = 0) : PyObject_ptr(obj, false) { }
+ struct SwigVar_PyObject : SwigPtr_PyObject {
+ SwigVar_PyObject(PyObject* obj = 0) : SwigPtr_PyObject(obj, false) { }
- PyObject_var & operator = (PyObject* obj)
+ SwigVar_PyObject & operator = (PyObject* obj)
{
Py_XDECREF(_obj);
_obj = obj;
SWIGINTERN int
SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc)
{
- if (PyString_Check(obj)) {
+#if PY_VERSION_HEX>=0x03000000
+ if (PyUnicode_Check(obj))
+#else
+ if (PyString_Check(obj))
+#endif
+ {
char *cstr; Py_ssize_t len;
+#if PY_VERSION_HEX>=0x03000000
+ if (!alloc && cptr) {
+ /* We can't allow converting without allocation, since the internal
+ representation of string in Python 3 is UCS-2/UCS-4 but we require
+ a UTF-8 representation.
+ TODO(bhy) More detailed explanation */
+ return SWIG_RuntimeError;
+ }
+ obj = PyUnicode_AsUTF8String(obj);
+ PyBytes_AsStringAndSize(obj, &cstr, &len);
+ if(alloc) *alloc = SWIG_NEWOBJ;
+#else
PyString_AsStringAndSize(obj, &cstr, &len);
- if (cptr) {
+#endif
+ if (cptr) {
if (alloc) {
/*
In python the user should not be able to modify the inner
*alloc = SWIG_OLDOBJ;
}
} else {
- *cptr = PyString_AsString(obj);
+ #if PY_VERSION_HEX>=0x03000000
+ assert(0); /* Should never reach here in Python 3 */
+ #endif
+ *cptr = SWIG_Python_str_AsChar(obj);
}
}
if (psize) *psize = len + 1;
+#if PY_VERSION_HEX>=0x03000000
+ Py_XDECREF(obj);
+#endif
return SWIG_OK;
} else {
swig_type_info* pchar_descriptor = SWIG_pchar_descriptor();
if (size > INT_MAX) {
swig_type_info* pchar_descriptor = SWIG_pchar_descriptor();
return pchar_descriptor ?
- SWIG_NewPointerObj(const_cast< char * >(carray), pchar_descriptor, 0) : SWIG_Py_Void();
+ SWIG_InternalNewPointerObj(const_cast< char * >(carray), pchar_descriptor, 0) : SWIG_Py_Void();
} else {
+#if PY_VERSION_HEX >= 0x03000000
+ return PyUnicode_FromStringAndSize(carray, static_cast< int >(size));
+#else
return PyString_FromStringAndSize(carray, static_cast< int >(size));
+#endif
}
} else {
return SWIG_Py_Void();
}
- #define SWIG_From_long PyInt_FromLong
-
-
-SWIGINTERNINLINE PyObject *
-SWIG_From_int (int value)
-{
- return SWIG_From_long (value);
+SWIGINTERNINLINE PyObject*
+ SWIG_From_int (int value)
+{
+ return PyInt_FromLong((long) value);
}
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO:ESLevent_event_set",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
{
SWIG_PYTHON_THREAD_BEGIN_ALLOW;
if (arg1) (arg1)->event = arg2;
-
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_Py_Void();
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLevent_event_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
- esl_event_t *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ esl_event_t *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLevent_event_get",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_esl_event_t, 0 | 0 );
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO:ESLevent_serialized_string_set",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
}
resultobj = SWIG_Py_Void();
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLevent_serialized_string_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ char *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLevent_serialized_string_get",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_FromCharPtr((const char *)result);
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO:ESLevent_mine_set",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
{
SWIG_PYTHON_THREAD_BEGIN_ALLOW;
if (arg1) (arg1)->mine = arg2;
-
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_Py_Void();
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLevent_mine_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ int result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLevent_mine_get",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_From_int(static_cast< int >(result));
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
char *arg1 = (char *) 0 ;
char *arg2 = (char *) NULL ;
- ESLevent *result = 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
int alloc2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O|O:new_ESLevent",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_AsCharPtrAndSize(obj0, &buf1, NULL, &alloc1);
if (!SWIG_IsOK(res1)) {
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLevent, SWIG_POINTER_NEW | 0 );
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
esl_event_t *arg1 = (esl_event_t *) 0 ;
int arg2 = (int) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int val2 ;
int ecode2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O|O:new_ESLevent",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_esl_event_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLevent, SWIG_POINTER_NEW | 0 );
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_new_ESLevent__SWIG_2(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:new_ESLevent",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLevent, SWIG_POINTER_NEW | 0 );
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *argv[3];
int ii;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyTuple_Check(args)) SWIG_fail;
- argc = (int)PyObject_Length(args);
- for (ii = 0; (ii < argc) && (ii < 2); ii++) {
+ argc = args ? (int)PyObject_Length(args) : 0;
+ for (ii = 0; (ii < 2) && (ii < argc); ii++) {
argv[ii] = PyTuple_GET_ITEM(args,ii);
}
if ((argc >= 1) && (argc <= 2)) {
_v = SWIG_CheckState(res);
if (_v) {
if (argc <= 1) {
- SWIG_PYTHON_THREAD_END_BLOCK;
return _wrap_new_ESLevent__SWIG_1(self, args);
}
{
_v = SWIG_CheckState(res);
}
if (_v) {
- SWIG_PYTHON_THREAD_END_BLOCK;
return _wrap_new_ESLevent__SWIG_1(self, args);
}
}
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_ESLevent, 0);
_v = SWIG_CheckState(res);
if (_v) {
- SWIG_PYTHON_THREAD_END_BLOCK;
return _wrap_new_ESLevent__SWIG_2(self, args);
}
}
_v = SWIG_CheckState(res);
if (_v) {
if (argc <= 1) {
- SWIG_PYTHON_THREAD_END_BLOCK;
return _wrap_new_ESLevent__SWIG_0(self, args);
}
int res = SWIG_AsCharPtrAndSize(argv[1], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
- SWIG_PYTHON_THREAD_END_BLOCK;
return _wrap_new_ESLevent__SWIG_0(self, args);
}
}
}
- SWIG_PYTHON_THREAD_END_BLOCK;
fail:
- SWIG_SetErrorMsg(PyExc_NotImplementedError,"Wrong number of arguments for overloaded function 'new_ESLevent'.\n"
+ SWIG_SetErrorMsg(PyExc_NotImplementedError,"Wrong number or type of arguments for overloaded function 'new_ESLevent'.\n"
" Possible C/C++ prototypes are:\n"
- " ESLevent(char const *,char const *)\n"
- " ESLevent(esl_event_t *,int)\n"
- " ESLevent(ESLevent *)\n");
- return NULL;
+ " ESLevent::ESLevent(char const *,char const *)\n"
+ " ESLevent::ESLevent(esl_event_t *,int)\n"
+ " ESLevent::ESLevent(ESLevent *)\n");
+ return 0;
}
int res1 = 0 ;
PyObject * obj0 = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:delete_ESLevent",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, SWIG_POINTER_DISOWN | 0 );
if (!SWIG_IsOK(res1)) {
{
SWIG_PYTHON_THREAD_BEGIN_ALLOW;
delete arg1;
-
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_Py_Void();
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) NULL ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
int alloc2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ char *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O|O:ESLevent_serialize",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
}
resultobj = SWIG_FromCharPtr((const char *)result);
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
esl_priority_t arg2 = (esl_priority_t) ESL_PRIORITY_NORMAL ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 ;
int res2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ bool result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O|O:ESLevent_setPriority",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_From_bool(static_cast< bool >(result));
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
int arg3 = (int) -1 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
+ char *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO|O:ESLevent_getHeader",&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
}
resultobj = SWIG_FromCharPtr((const char *)result);
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLevent_getBody(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ char *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLevent_getBody",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_FromCharPtr((const char *)result);
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLevent_getType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ char *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLevent_getType",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_FromCharPtr((const char *)result);
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
int alloc2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ bool result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO:ESLevent_addBody",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
}
resultobj = SWIG_From_bool(static_cast< bool >(result));
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
+ bool result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OOO:ESLevent_addHeader",&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
resultobj = SWIG_From_bool(static_cast< bool >(result));
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
+ bool result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OOO:ESLevent_pushHeader",&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
resultobj = SWIG_From_bool(static_cast< bool >(result));
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
+ bool result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OOO:ESLevent_unshiftHeader",&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
resultobj = SWIG_From_bool(static_cast< bool >(result));
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
char *arg2 = (char *) 0 ;
- bool result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
int alloc2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ bool result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO:ESLevent_delHeader",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
}
resultobj = SWIG_From_bool(static_cast< bool >(result));
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLevent_firstHeader(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ char *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLevent_firstHeader",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_FromCharPtr((const char *)result);
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLevent_nextHeader(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLevent *arg1 = (ESLevent *) 0 ;
- char *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ char *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLevent_nextHeader",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLevent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_FromCharPtr((const char *)result);
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
int arg2 ;
char *arg3 = (char *) 0 ;
char *arg4 = (char *) 0 ;
- ESLconnection *result = 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
PyObject * obj3 = 0 ;
+ ESLconnection *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OOOO:new_ESLconnection",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
res1 = SWIG_AsCharPtrAndSize(obj0, &buf1, NULL, &alloc1);
if (!SWIG_IsOK(res1)) {
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
char *arg1 = (char *) 0 ;
int arg2 ;
char *arg3 = (char *) 0 ;
- ESLconnection *result = 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
+ ESLconnection *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OOO:new_ESLconnection",&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_AsCharPtrAndSize(obj0, &buf1, NULL, &alloc1);
if (!SWIG_IsOK(res1)) {
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLconnection, SWIG_POINTER_NEW | 0 );
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
char *arg4 = (char *) 0 ;
- ESLconnection *result = 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
PyObject * obj3 = 0 ;
+ ESLconnection *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OOOO:new_ESLconnection",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
res1 = SWIG_AsCharPtrAndSize(obj0, &buf1, NULL, &alloc1);
if (!SWIG_IsOK(res1)) {
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
char *arg1 = (char *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- ESLconnection *result = 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
+ ESLconnection *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OOO:new_ESLconnection",&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_AsCharPtrAndSize(obj0, &buf1, NULL, &alloc1);
if (!SWIG_IsOK(res1)) {
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_new_ESLconnection__SWIG_4(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
int arg1 ;
- ESLconnection *result = 0 ;
int val1 ;
int ecode1 = 0 ;
PyObject * obj0 = 0 ;
+ ESLconnection *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:new_ESLconnection",&obj0)) SWIG_fail;
ecode1 = SWIG_AsVal_int(obj0, &val1);
if (!SWIG_IsOK(ecode1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLconnection, SWIG_POINTER_NEW | 0 );
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *argv[5];
int ii;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyTuple_Check(args)) SWIG_fail;
- argc = (int)PyObject_Length(args);
- for (ii = 0; (ii < argc) && (ii < 4); ii++) {
+ argc = args ? (int)PyObject_Length(args) : 0;
+ for (ii = 0; (ii < 4) && (ii < argc); ii++) {
argv[ii] = PyTuple_GET_ITEM(args,ii);
}
if (argc == 1) {
_v = SWIG_CheckState(res);
}
if (_v) {
- SWIG_PYTHON_THREAD_END_BLOCK;
return _wrap_new_ESLconnection__SWIG_4(self, args);
}
}
int res = SWIG_AsCharPtrAndSize(argv[2], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
- SWIG_PYTHON_THREAD_END_BLOCK;
return _wrap_new_ESLconnection__SWIG_1(self, args);
}
}
int res = SWIG_AsCharPtrAndSize(argv[2], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
- SWIG_PYTHON_THREAD_END_BLOCK;
return _wrap_new_ESLconnection__SWIG_3(self, args);
}
}
int res = SWIG_AsCharPtrAndSize(argv[3], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
- SWIG_PYTHON_THREAD_END_BLOCK;
return _wrap_new_ESLconnection__SWIG_0(self, args);
}
}
int res = SWIG_AsCharPtrAndSize(argv[3], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
- SWIG_PYTHON_THREAD_END_BLOCK;
return _wrap_new_ESLconnection__SWIG_2(self, args);
}
}
}
}
- SWIG_PYTHON_THREAD_END_BLOCK;
fail:
- SWIG_SetErrorMsg(PyExc_NotImplementedError,"Wrong number of arguments for overloaded function 'new_ESLconnection'.\n"
+ SWIG_SetErrorMsg(PyExc_NotImplementedError,"Wrong number or type of arguments for overloaded function 'new_ESLconnection'.\n"
" Possible C/C++ prototypes are:\n"
- " ESLconnection(char const *,int const,char const *,char const *)\n"
- " ESLconnection(char const *,int const,char const *)\n"
- " ESLconnection(char const *,char const *,char const *,char const *)\n"
- " ESLconnection(char const *,char const *,char const *)\n"
- " ESLconnection(int)\n");
- return NULL;
+ " ESLconnection::ESLconnection(char const *,int const,char const *,char const *)\n"
+ " ESLconnection::ESLconnection(char const *,int const,char const *)\n"
+ " ESLconnection::ESLconnection(char const *,char const *,char const *,char const *)\n"
+ " ESLconnection::ESLconnection(char const *,char const *,char const *)\n"
+ " ESLconnection::ESLconnection(int)\n");
+ return 0;
}
int res1 = 0 ;
PyObject * obj0 = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:delete_ESLconnection",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, SWIG_POINTER_DISOWN | 0 );
if (!SWIG_IsOK(res1)) {
{
SWIG_PYTHON_THREAD_BEGIN_ALLOW;
delete arg1;
-
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_Py_Void();
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLconnection_socketDescriptor(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLconnection *arg1 = (ESLconnection *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ int result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLconnection_socketDescriptor",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_From_int(static_cast< int >(result));
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLconnection_connected(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLconnection *arg1 = (ESLconnection *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ int result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLconnection_connected",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_From_int(static_cast< int >(result));
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLconnection_getInfo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLconnection *arg1 = (ESLconnection *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLconnection_getInfo",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLevent, SWIG_POINTER_OWN | 0 );
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
int alloc2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ int result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO:ESLconnection_send",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
}
resultobj = SWIG_From_int(static_cast< int >(result));
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
int alloc2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO:ESLconnection_sendRecv",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
}
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLevent, SWIG_POINTER_OWN | 0 );
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) NULL ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO|O:ESLconnection_api",&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLevent, SWIG_POINTER_OWN | 0 );
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
char *arg2 = (char *) 0 ;
char *arg3 = (char *) NULL ;
char *arg4 = (char *) NULL ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
PyObject * obj3 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO|OO:ESLconnection_bgapi",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
ESLconnection *arg1 = (ESLconnection *) 0 ;
ESLevent *arg2 = (ESLevent *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO:ESLconnection_sendEvent",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLevent, SWIG_POINTER_OWN | 0 );
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
ESLconnection *arg1 = (ESLconnection *) 0 ;
ESLevent *arg2 = (ESLevent *) 0 ;
char *arg3 = (char *) NULL ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
+ int result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO|O:ESLconnection_sendMSG",&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
}
resultobj = SWIG_From_int(static_cast< int >(result));
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLconnection_recvEvent(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLconnection *arg1 = (ESLconnection *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLconnection_recvEvent",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLevent, SWIG_POINTER_OWN | 0 );
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
ESLconnection *arg1 = (ESLconnection *) 0 ;
int arg2 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int val2 ;
int ecode2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO:ESLconnection_recvEventTimed",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLevent, SWIG_POINTER_OWN | 0 );
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OOO:ESLconnection_filter",&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ESLevent, SWIG_POINTER_OWN | 0 );
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
+ int result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OOO:ESLconnection_events",&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
resultobj = SWIG_From_int(static_cast< int >(result));
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
char *arg2 = (char *) 0 ;
char *arg3 = (char *) NULL ;
char *arg4 = (char *) NULL ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
PyObject * obj3 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO|OO:ESLconnection_execute",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
char *arg2 = (char *) 0 ;
char *arg3 = (char *) NULL ;
char *arg4 = (char *) NULL ;
- ESLevent *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
PyObject * obj1 = 0 ;
PyObject * obj2 = 0 ;
PyObject * obj3 = 0 ;
+ ESLevent *result = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO|OO:ESLconnection_executeAsync",&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
int alloc2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ int result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO:ESLconnection_setAsyncExecute",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
}
resultobj = SWIG_From_int(static_cast< int >(result));
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
PyObject *resultobj = 0;
ESLconnection *arg1 = (ESLconnection *) 0 ;
char *arg2 = (char *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
int alloc2 = 0 ;
PyObject * obj0 = 0 ;
PyObject * obj1 = 0 ;
+ int result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"OO:ESLconnection_setEventLock",&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
}
resultobj = SWIG_From_int(static_cast< int >(result));
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
SWIGINTERN PyObject *_wrap_ESLconnection_disconnect(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
PyObject *resultobj = 0;
ESLconnection *arg1 = (ESLconnection *) 0 ;
- int result;
void *argp1 = 0 ;
int res1 = 0 ;
PyObject * obj0 = 0 ;
+ int result;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:ESLconnection_disconnect",&obj0)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_ESLconnection, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_From_int(static_cast< int >(result));
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
int ecode1 = 0 ;
PyObject * obj0 = 0 ;
- SWIG_PYTHON_THREAD_BEGIN_BLOCK;
if (!PyArg_ParseTuple(args,(char *)"O:eslSetLogLevel",&obj0)) SWIG_fail;
ecode1 = SWIG_AsVal_int(obj0, &val1);
if (!SWIG_IsOK(ecode1)) {
SWIG_PYTHON_THREAD_END_ALLOW;
}
resultobj = SWIG_Py_Void();
- SWIG_PYTHON_THREAD_END_BLOCK;
return resultobj;
fail:
- SWIG_PYTHON_THREAD_END_BLOCK;
return NULL;
}
static PyMethodDef SwigMethods[] = {
+ { (char *)"SWIG_PyInstanceMethod_New", (PyCFunction)SWIG_PyInstanceMethod_New, METH_O, NULL},
{ (char *)"ESLevent_event_set", _wrap_ESLevent_event_set, METH_VARARGS, NULL},
{ (char *)"ESLevent_event_get", _wrap_ESLevent_event_get, METH_VARARGS, NULL},
{ (char *)"ESLevent_serialized_string_set", _wrap_ESLevent_serialized_string_set, METH_VARARGS, NULL},
#endif
/* -----------------------------------------------------------------------------
* Type initialization:
- * This problem is tough by the requirement that no dynamic
- * memory is used. Also, since swig_type_info structures store pointers to
+ * This problem is tough by the requirement that no dynamic
+ * memory is used. Also, since swig_type_info structures store pointers to
* swig_cast_info structures and swig_cast_info structures store pointers back
- * to swig_type_info structures, we need some lookup code at initialization.
- * The idea is that swig generates all the structures that are needed.
- * The runtime then collects these partially filled structures.
- * The SWIG_InitializeModule function takes these initial arrays out of
+ * to swig_type_info structures, we need some lookup code at initialization.
+ * The idea is that swig generates all the structures that are needed.
+ * The runtime then collects these partially filled structures.
+ * The SWIG_InitializeModule function takes these initial arrays out of
* swig_module, and does all the lookup, filling in the swig_module.types
* array with the correct data and linking the correct swig_cast_info
* structures together.
*
- * The generated swig_type_info structures are assigned staticly to an initial
+ * The generated swig_type_info structures are assigned staticly to an initial
* array. We just loop through that array, and handle each type individually.
* First we lookup if this type has been already loaded, and if so, use the
* loaded structure instead of the generated one. Then we have to fill in the
* a column is one of the swig_cast_info structures for that type.
* The cast_initial array is actually an array of arrays, because each row has
* a variable number of columns. So to actually build the cast linked list,
- * we find the array of casts associated with the type, and loop through it
+ * we find the array of casts associated with the type, and loop through it
* adding the casts to the list. The one last trick we need to do is making
* sure the type pointer in the swig_cast_info struct is correct.
*
- * First off, we lookup the cast->type name to see if it is already loaded.
+ * First off, we lookup the cast->type name to see if it is already loaded.
* There are three cases to handle:
* 1) If the cast->type has already been loaded AND the type we are adding
* casting info to has not been loaded (it is in this module), THEN we
* replace the cast->type pointer with the type pointer that has already
* been loaded.
- * 2) If BOTH types (the one we are adding casting info to, and the
+ * 2) If BOTH types (the one we are adding casting info to, and the
* cast->type) are loaded, THEN the cast info has already been loaded by
* the previous module so we just ignore it.
* 3) Finally, if cast->type has not already been loaded, then we add that
swig_module_info *module_head, *iter;
int found, init;
- clientdata = clientdata;
-
/* check to see if the circular list has been setup, if not, set it up */
if (swig_module.next==0) {
/* Initialize the swig_module */
module_head->next = &swig_module;
}
- /* When multiple interpeters are used, a module could have already been initialized in
+ /* When multiple interpreters are used, a module could have already been initialized in
a different interpreter, but not yet have a pointer in this interpreter.
In this case, we do not want to continue adding types... everything should be
set up already */
SWIGINTERN PyObject *
swig_varlink_repr(swig_varlinkobject *SWIGUNUSEDPARM(v)) {
+#if PY_VERSION_HEX >= 0x03000000
+ return PyUnicode_InternFromString("<Swig global variables>");
+#else
return PyString_FromString("<Swig global variables>");
+#endif
}
SWIGINTERN PyObject *
swig_varlink_str(swig_varlinkobject *v) {
+#if PY_VERSION_HEX >= 0x03000000
+ PyObject *str = PyUnicode_InternFromString("(");
+ PyObject *tail;
+ PyObject *joined;
+ swig_globalvar *var;
+ for (var = v->vars; var; var=var->next) {
+ tail = PyUnicode_FromString(var->name);
+ joined = PyUnicode_Concat(str, tail);
+ Py_DecRef(str);
+ Py_DecRef(tail);
+ str = joined;
+ if (var->next) {
+ tail = PyUnicode_InternFromString(", ");
+ joined = PyUnicode_Concat(str, tail);
+ Py_DecRef(str);
+ Py_DecRef(tail);
+ str = joined;
+ }
+ }
+ tail = PyUnicode_InternFromString(")");
+ joined = PyUnicode_Concat(str, tail);
+ Py_DecRef(str);
+ Py_DecRef(tail);
+ str = joined;
+#else
PyObject *str = PyString_FromString("(");
- swig_globalvar *var;
+ swig_globalvar *var;
for (var = v->vars; var; var=var->next) {
PyString_ConcatAndDel(&str,PyString_FromString(var->name));
if (var->next) PyString_ConcatAndDel(&str,PyString_FromString(", "));
}
PyString_ConcatAndDel(&str,PyString_FromString(")"));
+#endif
return str;
}
SWIGINTERN int
swig_varlink_print(swig_varlinkobject *v, FILE *fp, int SWIGUNUSEDPARM(flags)) {
+ char *tmp;
PyObject *str = swig_varlink_str(v);
fprintf(fp,"Swig global variables ");
- fprintf(fp,"%s\n", PyString_AsString(str));
+ fprintf(fp,"%s\n", tmp = SWIG_Python_str_AsChar(str));
+ SWIG_Python_str_DelForPy3(tmp);
Py_DECREF(str);
return 0;
}
swig_varlink_type(void) {
static char varlink__doc__[] = "Swig var link object";
static PyTypeObject varlink_type;
- static int type_init = 0;
+ static int type_init = 0;
if (!type_init) {
- const PyTypeObject tmp
- = {
+ const PyTypeObject tmp = {
+ /* PyObject header changed in Python 3 */
+#if PY_VERSION_HEX >= 0x03000000
+ PyVarObject_HEAD_INIT(NULL, 0)
+#else
PyObject_HEAD_INIT(NULL)
- 0, /* Number of items in variable part (ob_size) */
- (char *)"swigvarlink", /* Type name (tp_name) */
- sizeof(swig_varlinkobject), /* Basic size (tp_basicsize) */
- 0, /* Itemsize (tp_itemsize) */
- (destructor) swig_varlink_dealloc, /* Deallocator (tp_dealloc) */
- (printfunc) swig_varlink_print, /* Print (tp_print) */
- (getattrfunc) swig_varlink_getattr, /* get attr (tp_getattr) */
- (setattrfunc) swig_varlink_setattr, /* Set attr (tp_setattr) */
+ 0, /* ob_size */
+#endif
+ (char *)"swigvarlink", /* tp_name */
+ sizeof(swig_varlinkobject), /* tp_basicsize */
+ 0, /* tp_itemsize */
+ (destructor) swig_varlink_dealloc, /* tp_dealloc */
+ (printfunc) swig_varlink_print, /* tp_print */
+ (getattrfunc) swig_varlink_getattr, /* tp_getattr */
+ (setattrfunc) swig_varlink_setattr, /* tp_setattr */
0, /* tp_compare */
(reprfunc) swig_varlink_repr, /* tp_repr */
0, /* tp_as_number */
0, /* tp_as_mapping */
0, /* tp_hash */
0, /* tp_call */
- (reprfunc)swig_varlink_str, /* tp_str */
+ (reprfunc) swig_varlink_str, /* tp_str */
0, /* tp_getattro */
0, /* tp_setattro */
0, /* tp_as_buffer */
#if PY_VERSION_HEX >= 0x02030000
0, /* tp_del */
#endif
+#if PY_VERSION_HEX >= 0x02060000
+ 0, /* tp_version */
+#endif
#ifdef COUNT_ALLOCS
0,0,0,0 /* tp_alloc -> tp_next */
#endif
};
varlink_type = tmp;
- varlink_type.ob_type = &PyType_Type;
type_init = 1;
+#if PY_VERSION_HEX < 0x02020000
+ varlink_type.ob_type = &PyType_Type;
+#else
+ if (PyType_Ready(&varlink_type) < 0)
+ return NULL;
+#endif
}
return &varlink_type;
}
for (i = 0; constants[i].type; ++i) {
switch(constants[i].type) {
case SWIG_PY_POINTER:
- obj = SWIG_NewPointerObj(constants[i].pvalue, *(constants[i]).ptype,0);
+ obj = SWIG_InternalNewPointerObj(constants[i].pvalue, *(constants[i]).ptype,0);
break;
case SWIG_PY_BINARY:
obj = SWIG_NewPackedObj(constants[i].pvalue, constants[i].lvalue, *(constants[i].ptype));
}
}
if (ci) {
- size_t shift = (ci->ptype) - types;
- swig_type_info *ty = types_initial[shift];
- size_t ldoc = (c - methods[i].ml_doc);
- size_t lptr = strlen(ty->name)+2*sizeof(void*)+2;
- char *ndoc = (char*)malloc(ldoc + lptr + 10);
- if (ndoc) {
- char *buff = ndoc;
- void *ptr = (ci->type == SWIG_PY_POINTER) ? ci->pvalue : 0;
- if (ptr) {
+ void *ptr = (ci->type == SWIG_PY_POINTER) ? ci->pvalue : 0;
+ if (ptr) {
+ size_t shift = (ci->ptype) - types;
+ swig_type_info *ty = types_initial[shift];
+ size_t ldoc = (c - methods[i].ml_doc);
+ size_t lptr = strlen(ty->name)+2*sizeof(void*)+2;
+ char *ndoc = (char*)malloc(ldoc + lptr + 10);
+ if (ndoc) {
+ char *buff = ndoc;
strncpy(buff, methods[i].ml_doc, ldoc);
buff += ldoc;
strncpy(buff, "swig_ptr: ", 10);
#ifdef __cplusplus
extern "C"
#endif
-SWIGEXPORT void SWIG_init(void) {
- PyObject *m, *d;
+
+SWIGEXPORT
+#if PY_VERSION_HEX >= 0x03000000
+PyObject*
+#else
+void
+#endif
+SWIG_init(void) {
+ PyObject *m, *d, *md;
+#if PY_VERSION_HEX >= 0x03000000
+ static struct PyModuleDef SWIG_module = {
+# if PY_VERSION_HEX >= 0x03020000
+ PyModuleDef_HEAD_INIT,
+# else
+ {
+ PyObject_HEAD_INIT(NULL)
+ NULL, /* m_init */
+ 0, /* m_index */
+ NULL, /* m_copy */
+ },
+# endif
+ (char *) SWIG_name,
+ NULL,
+ -1,
+ SwigMethods,
+ NULL,
+ NULL,
+ NULL,
+ NULL
+ };
+#endif
+
+#if defined(SWIGPYTHON_BUILTIN)
+ static SwigPyClientData SwigPyObject_clientdata = {
+ 0, 0, 0, 0, 0, 0, 0
+ };
+ static PyGetSetDef this_getset_def = {
+ (char *)"this", &SwigPyBuiltin_ThisClosure, NULL, NULL, NULL
+ };
+ static SwigPyGetSet thisown_getset_closure = {
+ (PyCFunction) SwigPyObject_own,
+ (PyCFunction) SwigPyObject_own
+ };
+ static PyGetSetDef thisown_getset_def = {
+ (char *)"thisown", SwigPyBuiltin_GetterClosure, SwigPyBuiltin_SetterClosure, NULL, &thisown_getset_closure
+ };
+ PyObject *metatype_args;
+ PyTypeObject *builtin_pytype;
+ int builtin_base_count;
+ swig_type_info *builtin_basetype;
+ PyObject *tuple;
+ PyGetSetDescrObject *static_getset;
+ PyTypeObject *metatype;
+ SwigPyClientData *cd;
+ PyObject *public_interface, *public_symbol;
+ PyObject *this_descr;
+ PyObject *thisown_descr;
+ int i;
+
+ (void)builtin_pytype;
+ (void)builtin_base_count;
+ (void)builtin_basetype;
+ (void)tuple;
+ (void)static_getset;
+
+ /* metatype is used to implement static member variables. */
+ metatype_args = Py_BuildValue("(s(O){})", "SwigPyObjectType", &PyType_Type);
+ assert(metatype_args);
+ metatype = (PyTypeObject *) PyType_Type.tp_call((PyObject *) &PyType_Type, metatype_args, NULL);
+ assert(metatype);
+ Py_DECREF(metatype_args);
+ metatype->tp_setattro = (setattrofunc) &SwigPyObjectType_setattro;
+ assert(PyType_Ready(metatype) >= 0);
+#endif
/* Fix SwigMethods to carry the callback ptrs when needed */
SWIG_Python_FixMethods(SwigMethods, swig_const_table, swig_types, swig_type_initial);
+#if PY_VERSION_HEX >= 0x03000000
+ m = PyModule_Create(&SWIG_module);
+#else
m = Py_InitModule((char *) SWIG_name, SwigMethods);
- d = PyModule_GetDict(m);
+#endif
+ md = d = PyModule_GetDict(m);
+ (void)md;
SWIG_InitializeModule(0);
- SWIG_InstallConstants(d,swig_const_table);
+#ifdef SWIGPYTHON_BUILTIN
+ SwigPyObject_stype = SWIG_MangledTypeQuery("_p_SwigPyObject");
+ assert(SwigPyObject_stype);
+ cd = (SwigPyClientData*) SwigPyObject_stype->clientdata;
+ if (!cd) {
+ SwigPyObject_stype->clientdata = &SwigPyObject_clientdata;
+ SwigPyObject_clientdata.pytype = SwigPyObject_TypeOnce();
+ } else if (SwigPyObject_TypeOnce()->tp_basicsize != cd->pytype->tp_basicsize) {
+ PyErr_SetString(PyExc_RuntimeError, "Import error: attempted to load two incompatible swig-generated modules.");
+# if PY_VERSION_HEX >= 0x03000000
+ return NULL;
+# else
+ return;
+# endif
+ }
+
+ /* All objects have a 'this' attribute */
+ this_descr = PyDescr_NewGetSet(SwigPyObject_type(), &this_getset_def);
+ (void)this_descr;
+
+ /* All objects have a 'thisown' attribute */
+ thisown_descr = PyDescr_NewGetSet(SwigPyObject_type(), &thisown_getset_def);
+ (void)thisown_descr;
+
+ public_interface = PyList_New(0);
+ public_symbol = 0;
+ (void)public_symbol;
+
+ PyDict_SetItemString(md, "__all__", public_interface);
+ Py_DECREF(public_interface);
+ for (i = 0; SwigMethods[i].ml_name != NULL; ++i)
+ SwigPyBuiltin_AddPublicSymbol(public_interface, SwigMethods[i].ml_name);
+ for (i = 0; swig_const_table[i].name != 0; ++i)
+ SwigPyBuiltin_AddPublicSymbol(public_interface, swig_const_table[i].name);
+#endif
+
+ SWIG_InstallConstants(d,swig_const_table);
/* Initialize threading */
SWIG_PYTHON_INITIALIZE_THREADS;
+#if PY_VERSION_HEX >= 0x03000000
+ return m;
+#else
+ return;
+#endif
}
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.7
- *
- * This file is not intended to be easily readable and contains a number of
+ * Version 2.0.12
+ *
+ * This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
- * changes to this file unless you know what you are doing--modify the SWIG
- * interface file instead.
+ * changes to this file unless you know what you are doing--modify the SWIG
+ * interface file instead.
* ----------------------------------------------------------------------------- */
#define SWIGRUBY
#ifndef SWIGUNUSED
# if defined(__GNUC__)
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
# elif defined(__ICC)
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
-# define SWIGUNUSED
+# define SWIGUNUSED
# endif
#endif
#ifndef SWIG_MSC_UNSUPPRESS_4505
# if defined(_MSC_VER)
# pragma warning(disable : 4505) /* unreferenced local function has been removed */
-# endif
+# endif
#endif
#ifndef SWIGUNUSEDPARM
# ifdef __cplusplus
# define SWIGUNUSEDPARM(p)
# else
-# define SWIGUNUSEDPARM(p) p SWIGUNUSED
+# define SWIGUNUSEDPARM(p) p SWIGUNUSED
# endif
#endif
# define SWIGSTDCALL __stdcall
# else
# define SWIGSTDCALL
-# endif
+# endif
#endif
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
#ifndef SWIGUNUSED
# if defined(__GNUC__)
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
# elif defined(__ICC)
-# define SWIGUNUSED __attribute__ ((__unused__))
+# define SWIGUNUSED __attribute__ ((__unused__))
# else
-# define SWIGUNUSED
+# define SWIGUNUSED
# endif
#endif
#ifndef SWIG_MSC_UNSUPPRESS_4505
# if defined(_MSC_VER)
# pragma warning(disable : 4505) /* unreferenced local function has been removed */
-# endif
+# endif
#endif
#ifndef SWIGUNUSEDPARM
# ifdef __cplusplus
# define SWIGUNUSEDPARM(p)
# else
-# define SWIGUNUSEDPARM(p) p SWIGUNUSED
+# define SWIGUNUSEDPARM(p) p SWIGUNUSED
# endif
#endif
# define SWIGSTDCALL __stdcall
# else
# define SWIGSTDCALL
-# endif
+# endif
#endif
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
creating a static or dynamic library from the SWIG runtime code.
In 99.9% of the cases, SWIG just needs to declare them as 'static'.
-
+
But only do this if strictly necessary, ie, if you have problems
with your compiler or suchlike.
*/
#define SWIG_POINTER_OWN 0x1
-/*
+/*
Flags/methods for returning states.
-
- The SWIG conversion methods, as ConvertPtr, return an integer
+
+ The SWIG conversion methods, as ConvertPtr, return an integer
that tells if the conversion was successful or not. And if not,
an error code can be returned (see swigerrors.swg for the codes).
-
+
Use the following macros/flags to set or process the returning
states.
-
+
In old versions of SWIG, code such as the following was usually written:
if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
} else {
// fail code
}
-
+
I.e., now SWIG_ConvertPtr can return new objects and you can
identify the case and take care of the deallocation. Of course that
also requires SWIG_ConvertPtr to return new result values, such as
- int SWIG_ConvertPtr(obj, ptr,...) {
- if (<obj is ok>) {
- if (<need new object>) {
- *ptr = <ptr to new allocated object>;
- return SWIG_NEWOBJ;
- } else {
- *ptr = <ptr to old object>;
- return SWIG_OLDOBJ;
- }
- } else {
- return SWIG_BADOBJ;
- }
+ int SWIG_ConvertPtr(obj, ptr,...) {
+ if (<obj is ok>) {
+ if (<need new object>) {
+ *ptr = <ptr to new allocated object>;
+ return SWIG_NEWOBJ;
+ } else {
+ *ptr = <ptr to old object>;
+ return SWIG_OLDOBJ;
+ }
+ } else {
+ return SWIG_BADOBJ;
+ }
}
Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
int fooi(int);
and you call
-
+
food(1) // cast rank '1' (1 -> 1.0)
fooi(1) // cast rank '0'
just use the SWIG_AddCast()/SWIG_CheckState()
*/
-#define SWIG_OK (0)
+#define SWIG_OK (0)
#define SWIG_ERROR (-1)
#define SWIG_IsOK(r) (r >= 0)
-#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
+#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
/* The CastRankLimit says how many bits are used for the cast rank */
#define SWIG_CASTRANKLIMIT (1 << 8)
# endif
# define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
# define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
-SWIGINTERNINLINE int SWIG_AddCast(int r) {
+SWIGINTERNINLINE int SWIG_AddCast(int r) {
return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
}
-SWIGINTERNINLINE int SWIG_CheckState(int r) {
- return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
+SWIGINTERNINLINE int SWIG_CheckState(int r) {
+ return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
}
#else /* no cast-rank mode */
-# define SWIG_AddCast
+# define SWIG_AddCast(r) (r)
# define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
#endif
void *clientdata; /* Language specific module data */
} swig_module_info;
-/*
+/*
Compare two type names skipping the space characters, therefore
"char*" == "char *" and "Class<int>" == "Class<int >", etc.
/*
Check type equivalence in a name list like <name1>|<name2>|...
- Return 0 if not equal, 1 if equal
+ Return 0 if equal, -1 if nb < tb, 1 if nb > tb
*/
SWIGRUNTIME int
-SWIG_TypeEquiv(const char *nb, const char *tb) {
- int equiv = 0;
+SWIG_TypeCmp(const char *nb, const char *tb) {
+ int equiv = 1;
const char* te = tb + strlen(tb);
const char* ne = nb;
- while (!equiv && *ne) {
+ while (equiv != 0 && *ne) {
for (nb = ne; *ne; ++ne) {
if (*ne == '|') break;
}
- equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
+ equiv = SWIG_TypeNameComp(nb, ne, tb, te);
if (*ne) ++ne;
}
return equiv;
/*
Check type equivalence in a name list like <name1>|<name2>|...
- Return 0 if equal, -1 if nb < tb, 1 if nb > tb
+ Return 0 if not equal, 1 if equal
*/
SWIGRUNTIME int
-SWIG_TypeCompare(const char *nb, const char *tb) {
- int equiv = 0;
- const char* te = tb + strlen(tb);
- const char* ne = nb;
- while (!equiv && *ne) {
- for (nb = ne; *ne; ++ne) {
- if (*ne == '|') break;
- }
- equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
- if (*ne) ++ne;
- }
- return equiv;
+SWIG_TypeEquiv(const char *nb, const char *tb) {
+ return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
}
-
/*
Check the typename
*/
return 0;
}
-/*
+/*
Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
*/
SWIGRUNTIME swig_cast_info *
return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
}
-/*
+/*
Dynamic pointer casting. Down an inheritance hierarchy
*/
SWIGRUNTIME swig_type_info *
return type->name;
}
-/*
+/*
Set the clientdata field for a type
*/
SWIGRUNTIME void
swig_cast_info *cast = ti->cast;
/* if (ti->clientdata == clientdata) return; */
ti->clientdata = clientdata;
-
+
while (cast) {
if (!cast->converter) {
swig_type_info *tc = cast->type;
if (!tc->clientdata) {
SWIG_TypeClientData(tc, clientdata);
}
- }
+ }
cast = cast->next;
}
}
SWIG_TypeClientData(ti, clientdata);
ti->owndata = 1;
}
-
+
/*
Search for a swig_type_info structure only by mangled name
Search is a O(log #types)
-
- We start searching at module start, and finish searching when start == end.
+
+ We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
-SWIG_MangledTypeQueryModule(swig_module_info *start,
- swig_module_info *end,
+SWIG_MangledTypeQueryModule(swig_module_info *start,
+ swig_module_info *end,
const char *name) {
swig_module_info *iter = start;
do {
register size_t r = iter->size - 1;
do {
/* since l+r >= 0, we can (>> 1) instead (/ 2) */
- register size_t i = (l + r) >> 1;
+ register size_t i = (l + r) >> 1;
const char *iname = iter->types[i]->name;
if (iname) {
register int compare = strcmp(name, iname);
- if (compare == 0) {
+ if (compare == 0) {
return iter->types[i];
} else if (compare < 0) {
if (i) {
Search for a swig_type_info structure for either a mangled name or a human readable name.
It first searches the mangled names of the types, which is a O(log #types)
If a type is not found it then searches the human readable names, which is O(#types).
-
- We start searching at module start, and finish searching when start == end.
+
+ We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
-SWIG_TypeQueryModule(swig_module_info *start,
- swig_module_info *end,
+SWIG_TypeQueryModule(swig_module_info *start,
+ swig_module_info *end,
const char *name) {
/* STEP 1: Search the name field using binary search */
swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
iter = iter->next;
} while (iter != end);
}
-
+
/* neither found a match */
return 0;
}
-/*
+/*
Pack binary data into a string
*/
SWIGRUNTIME char *
return c;
}
-/*
+/*
Unpack binary data from a string
*/
SWIGRUNTIME const char *
uu = ((d - '0') << 4);
else if ((d >= 'a') && (d <= 'f'))
uu = ((d - ('a'-10)) << 4);
- else
+ else
return (char *) 0;
d = *(c++);
if ((d >= '0') && (d <= '9'))
uu |= (d - '0');
else if ((d >= 'a') && (d <= 'f'))
uu |= (d - ('a'-10));
- else
+ else
return (char *) 0;
*u = uu;
}
return c;
}
-/*
+/*
Pack 'void *' into a string buffer.
*/
SWIGRUNTIME char *
#endif
/* Errors in SWIG */
-#define SWIG_UnknownError -1
-#define SWIG_IOError -2
-#define SWIG_RuntimeError -3
-#define SWIG_IndexError -4
-#define SWIG_TypeError -5
-#define SWIG_DivisionByZero -6
-#define SWIG_OverflowError -7
-#define SWIG_SyntaxError -8
-#define SWIG_ValueError -9
+#define SWIG_UnknownError -1
+#define SWIG_IOError -2
+#define SWIG_RuntimeError -3
+#define SWIG_IndexError -4
+#define SWIG_TypeError -5
+#define SWIG_DivisionByZero -6
+#define SWIG_OverflowError -7
+#define SWIG_SyntaxError -8
+#define SWIG_ValueError -9
#define SWIG_SystemError -10
#define SWIG_AttributeError -11
-#define SWIG_MemoryError -12
+#define SWIG_MemoryError -12
#define SWIG_NullReferenceError -13
/* Runtime API */
-#define SWIG_GetModule(clientdata) SWIG_Ruby_GetModule()
+#define SWIG_GetModule(clientdata) SWIG_Ruby_GetModule(clientdata)
#define SWIG_SetModule(clientdata, pointer) SWIG_Ruby_SetModule(pointer)
}
SWIGRUNTIME swig_module_info *
-SWIG_Ruby_GetModule(void)
+SWIG_Ruby_GetModule(void *SWIGUNUSEDPARM(clientdata))
{
VALUE pointer;
swig_module_info *ret = 0;
SWIGINTERN
int SWIG_Ruby_isCallable( VALUE proc )
{
- if ( rb_respond_to( proc, swig_call_id ) == Qtrue )
+ if ( rb_respond_to( proc, swig_call_id ) )
return 1;
return 0;
}
SWIGINTERN
int SWIG_Ruby_arity( VALUE proc, int minimal )
{
- if ( rb_respond_to( proc, swig_arity_id ) == Qtrue )
+ if ( rb_respond_to( proc, swig_arity_id ) )
{
VALUE num = rb_funcall( proc, swig_arity_id, 0 );
int arity = NUM2INT(num);
#define SWIG_RUBY_THREAD_END_BLOCK
-#define SWIGVERSION 0x020007
+#define SWIGVERSION 0x020012
#define SWIG_VERSION SWIGVERSION
SWIG_AsCharPtrAndSize(VALUE obj, char** cptr, size_t* psize, int *alloc)
{
if (TYPE(obj) == T_STRING) {
- #if defined(StringValuePtr)
char *cstr = StringValuePtr(obj);
- #else
- char *cstr = STR2CSTR(obj);
- #endif
size_t size = RSTRING_LEN(obj) + 1;
if (cptr) {
if (alloc) {
/* -----------------------------------------------------------------------------
* Type initialization:
- * This problem is tough by the requirement that no dynamic
- * memory is used. Also, since swig_type_info structures store pointers to
+ * This problem is tough by the requirement that no dynamic
+ * memory is used. Also, since swig_type_info structures store pointers to
* swig_cast_info structures and swig_cast_info structures store pointers back
- * to swig_type_info structures, we need some lookup code at initialization.
- * The idea is that swig generates all the structures that are needed.
- * The runtime then collects these partially filled structures.
- * The SWIG_InitializeModule function takes these initial arrays out of
+ * to swig_type_info structures, we need some lookup code at initialization.
+ * The idea is that swig generates all the structures that are needed.
+ * The runtime then collects these partially filled structures.
+ * The SWIG_InitializeModule function takes these initial arrays out of
* swig_module, and does all the lookup, filling in the swig_module.types
* array with the correct data and linking the correct swig_cast_info
* structures together.
*
- * The generated swig_type_info structures are assigned staticly to an initial
+ * The generated swig_type_info structures are assigned staticly to an initial
* array. We just loop through that array, and handle each type individually.
* First we lookup if this type has been already loaded, and if so, use the
* loaded structure instead of the generated one. Then we have to fill in the
* a column is one of the swig_cast_info structures for that type.
* The cast_initial array is actually an array of arrays, because each row has
* a variable number of columns. So to actually build the cast linked list,
- * we find the array of casts associated with the type, and loop through it
+ * we find the array of casts associated with the type, and loop through it
* adding the casts to the list. The one last trick we need to do is making
* sure the type pointer in the swig_cast_info struct is correct.
*
- * First off, we lookup the cast->type name to see if it is already loaded.
+ * First off, we lookup the cast->type name to see if it is already loaded.
* There are three cases to handle:
* 1) If the cast->type has already been loaded AND the type we are adding
* casting info to has not been loaded (it is in this module), THEN we
* replace the cast->type pointer with the type pointer that has already
* been loaded.
- * 2) If BOTH types (the one we are adding casting info to, and the
+ * 2) If BOTH types (the one we are adding casting info to, and the
* cast->type) are loaded, THEN the cast info has already been loaded by
* the previous module so we just ignore it.
* 3) Finally, if cast->type has not already been loaded, then we add that
swig_module_info *module_head, *iter;
int found, init;
- clientdata = clientdata;
-
/* check to see if the circular list has been setup, if not, set it up */
if (swig_module.next==0) {
/* Initialize the swig_module */
module_head->next = &swig_module;
}
- /* When multiple interpeters are used, a module could have already been initialized in
+ /* When multiple interpreters are used, a module could have already been initialized in
a different interpreter, but not yet have a pointer in this interpreter.
In this case, we do not want to continue adding types... everything should be
set up already */
swig_type_info *type = 0;
swig_type_info *ret;
swig_cast_info *cast;
-
+
#ifdef SWIGRUNTIME_DEBUG
printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
#endif
/* Insert casting types */
cast = swig_module.cast_initial[i];
while (cast->type) {
-
+
/* Don't need to add information already in the list */
ret = 0;
#ifdef SWIGRUNTIME_DEBUG