]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-10427: move libesl to use swig3.0 so we can reswig on debian9
authorMike Jerris <mike@jerris.com>
Tue, 27 Jun 2017 17:10:04 +0000 (12:10 -0500)
committerMike Jerris <mike@jerris.com>
Tue, 27 Jun 2017 17:10:04 +0000 (12:10 -0500)
33 files changed:
libs/esl/.gitignore
libs/esl/java/Makefile
libs/esl/java/esl_wrap.cpp
libs/esl/java/org/freeswitch/esl/ESLconnection.java
libs/esl/java/org/freeswitch/esl/ESLevent.java
libs/esl/java/org/freeswitch/esl/SWIGTYPE_p_esl_event_t.java
libs/esl/java/org/freeswitch/esl/SWIGTYPE_p_esl_priority_t.java
libs/esl/java/org/freeswitch/esl/esl.java
libs/esl/java/org/freeswitch/esl/eslJNI.java
libs/esl/lua/Makefile
libs/esl/lua/esl_wrap.cpp
libs/esl/managed/ESL.cs
libs/esl/managed/ESLPINVOKE.cs
libs/esl/managed/ESLconnection.cs
libs/esl/managed/ESLevent.cs
libs/esl/managed/Makefile
libs/esl/managed/SWIGTYPE_p_esl_event_t.cs
libs/esl/managed/SWIGTYPE_p_esl_priority_t.cs
libs/esl/managed/esl_wrap.cpp
libs/esl/perl/ESL.pm
libs/esl/perl/Makefile.am
libs/esl/perl/esl_wrap.cpp
libs/esl/php/ESL.php
libs/esl/php/Makefile.am
libs/esl/php/esl_wrap.cpp
libs/esl/php/php_ESL.h
libs/esl/python/ESL.py
libs/esl/python/Makefile
libs/esl/python/esl_wrap.cpp
libs/esl/ruby/Makefile
libs/esl/ruby/esl_wrap.cpp
libs/esl/tcl/Makefile
libs/esl/tcl/esl_wrap.cpp

index 301cd8879e74867c844106e6acf24fe8836621ba..ede7bd50151845f70e76ea3d83901edb4ca2c38b 100644 (file)
@@ -10,3 +10,6 @@ Makefile.in
 !python/Makefile
 !ruby/Makefile
 !tcl/Makefile
+java/classes/org/
+java/esl.jar
+               
index 80064b380bea4f151a58aec91c9fdaf76efd107d..48ee95acc4507c3c87f9b7369b046ca608a3c7e9 100644 (file)
@@ -5,7 +5,7 @@ CLASSES=org/freeswitch/esl/*
 all: esl.jar
 
 esl_wrap.cpp:
-       swig2.0 -module esl -java -c++ $(LOCAL_CFLAGS) -package org.freeswitch.esl -outdir org/freeswitch/esl -o esl_wrap.cpp ../ESL.i
+       swig3.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
index b31f7d216ba01cfe2bacdc190bf69a50958ed963..cff05c75ed40b07a8036eec228ffb4d2001b66d0 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * 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
index 364dcb3f8296d70047e53d6e135b3738d7ec3a0c..06d7f1ef4571f8a56f38934d9fc72f59046c18ce 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
index 9e95fbd2ab1edb6ce80d178a0e3c6185cdf37fdc..1999347197662e8423c12a53f5b1bd01876b52c5 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
index 6b1dcbbc3a519eca8ae553bd5dd117f4a6d0ad7d..d8359101e18f68b0b589a403dd4c9f7551d09a43 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
index 04bd5e1b4f26220a477e9bbb49abfa2d9e322f85..72de2b89725e158078349d5b0887d3904362a6cb 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
index d314ef90f5af9c4ae422be126dc52876a3b638ed..08a0f4acad61cd19612c83999efa27546f2a62cc 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
index 38bc0dca4657c7f7f8e719c0d30d6f9b1126ab4d..50ecb8af4e77c74b95dc4f5db3782b0bcede055d 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
index 24b6fbd18e1264d50300a96c3ab8db5cfe87817e..a24b527ba5e64513a720f9c495caffa3d8501ba9 100644 (file)
@@ -5,7 +5,7 @@ WRAP_GCC_WARNING_SILENCE=-Wno-unused-function
 all: ESL.so
 
 esl_wrap.cpp:
-       swig2.0 -module ESL -lua -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
+       swig3.0 -module ESL -lua -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
 
 esl_wrap.o: esl_wrap.cpp
        $(CXX) $(CXX_CFLAGS) $(LUA_CFLAGS) $(CXXFLAGS) $(LOCAL_CFLAGS) $(WRAP_GCC_WARNING_SILENCE) -c esl_wrap.cpp -o esl_wrap.o
index bb7a41a933f995a02b0674d580753b535d01dbec..d89b83e4451eb48d668526172cfacfd2c4398b60 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * 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
@@ -551,14 +551,14 @@ SWIG_MangledTypeQueryModule(swig_module_info *start,
   swig_module_info *iter = start;
   do {
     if (iter->size) {
-      register size_t l = 0;
-      register size_t r = iter->size - 1;
+      size_t l = 0;
+      size_t r = iter->size - 1;
       do {
        /* since l+r >= 0, we can (>> 1) instead (/ 2) */
-       register size_t i = (l + r) >> 1;
+       size_t i = (l + r) >> 1;
        const char *iname = iter->types[i]->name;
        if (iname) {
-         register int compare = strcmp(name, iname);
+         int compare = strcmp(name, iname);
          if (compare == 0) {
            return iter->types[i];
          } else if (compare < 0) {
@@ -602,7 +602,7 @@ SWIG_TypeQueryModule(swig_module_info *start,
        of the str field (the human readable name) */
     swig_module_info *iter = start;
     do {
-      register size_t i = 0;
+      size_t i = 0;
       for (; i < iter->size; ++i) {
        if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
          return iter->types[i];
@@ -621,10 +621,10 @@ SWIG_TypeQueryModule(swig_module_info *start,
 SWIGRUNTIME char *
 SWIG_PackData(char *c, void *ptr, size_t sz) {
   static const char hex[17] = "0123456789abcdef";
-  register const unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu =  u + sz;
+  const unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu =  u + sz;
   for (; u != eu; ++u) {
-    register unsigned char uu = *u;
+    unsigned char uu = *u;
     *(c++) = hex[(uu & 0xf0) >> 4];
     *(c++) = hex[uu & 0xf];
   }
@@ -636,11 +636,11 @@ SWIG_PackData(char *c, void *ptr, size_t sz) {
 */
 SWIGRUNTIME const char *
 SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
-  register unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu = u + sz;
+  unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu = u + sz;
   for (; u != eu; ++u) {
-    register char d = *(c++);
-    register unsigned char uu;
+    char d = *(c++);
+    unsigned char uu;
     if ((d >= '0') && (d <= '9'))
       uu = ((d - '0') << 4);
     else if ((d >= 'a') && (d <= 'f'))
@@ -747,23 +747,110 @@ extern "C" {
 # error SWIG_LUA_TARGET not defined
 #endif
 
+#if defined(SWIG_LUA_ELUA_EMULATE)
+
+struct swig_elua_entry;
+
+typedef struct swig_elua_key {
+  int type;
+  union {
+    const char* strkey;
+    lua_Number numkey;
+  } key;
+} swig_elua_key;
+
+typedef struct swig_elua_val {
+  int type;
+  union {
+    lua_Number number;
+    const struct swig_elua_entry *table;
+    const char *string;
+    lua_CFunction function;
+    struct {
+      char member;
+      long lvalue;
+      void *pvalue;
+      swig_type_info **ptype;
+    } userdata;
+  } value;
+} swig_elua_val;
+
+typedef struct swig_elua_entry {
+  swig_elua_key key;
+  swig_elua_val value;
+} swig_elua_entry;
+
+#define LSTRKEY(x) {LUA_TSTRING, {.strkey = x} }
+#define LNUMKEY(x) {LUA_TNUMBER, {.numkey = x} }
+#define LNILKEY {LUA_TNIL, {.strkey = 0} }
+
+#define LNUMVAL(x) {LUA_TNUMBER, {.number = x} }
+#define LFUNCVAL(x) {LUA_TFUNCTION, {.function = x} }
+#define LROVAL(x) {LUA_TTABLE, {.table = x} }
+#define LNILVAL {LUA_TNIL, {.string = 0} }
+#define LSTRVAL(x) {LUA_TSTRING, {.string = x} }
+
+#define LUA_REG_TYPE swig_elua_entry
+
+#define SWIG_LUA_ELUA_EMUL_METATABLE_KEY "__metatable"
+
+#define lua_pushrotable(L,p)\
+  lua_newtable(L);\
+  assert(p);\
+  SWIG_Lua_elua_emulate_register(L,(swig_elua_entry*)(p));
+
+#define SWIG_LUA_CONSTTAB_POINTER(B,C,D)\
+  LSTRKEY(B), {LUA_TUSERDATA, { .userdata={0,0,(void*)(C),&D} } }
+
+#define SWIG_LUA_CONSTTAB_BINARY(B,S,C,D)\
+  LSTRKEY(B), {LUA_TUSERDATA, { .userdata={1,S,(void*)(C),&D} } }
+#endif
+
 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
 #  define SWIG_LUA_CONSTTAB_INT(B, C) LSTRKEY(B), LNUMVAL(C)
 #  define SWIG_LUA_CONSTTAB_FLOAT(B, C) LSTRKEY(B), LNUMVAL(C)
 #  define SWIG_LUA_CONSTTAB_STRING(B, C) LSTRKEY(B), LSTRVAL(C)
 #  define SWIG_LUA_CONSTTAB_CHAR(B, C) LSTRKEY(B), LNUMVAL(C)
+    /* Those two types of constants are not supported in elua */
+
+#ifndef SWIG_LUA_CONSTTAB_POINTER
+#warning eLua does not support pointers as constants. By default, nil will be used as value
+#define SWIG_LUA_CONSTTAB_POINTER(B,C,D) LSTRKEY(B), LNILVAL
+#endif
+
+#ifndef SWIG_LUA_CONSTTAB_BINARY
+#warning eLua does not support pointers to member as constants. By default, nil will be used as value
+#define SWIG_LUA_CONSTTAB_BINARY(B, S, C, D) LSTRKEY(B), LNILVAL
+#endif
 #else /* SWIG_LUA_FLAVOR_LUA */
 #  define SWIG_LUA_CONSTTAB_INT(B, C) SWIG_LUA_INT, (char *)B, (long)C, 0, 0, 0
 #  define SWIG_LUA_CONSTTAB_FLOAT(B, C) SWIG_LUA_FLOAT, (char *)B, 0, (double)C, 0, 0
 #  define SWIG_LUA_CONSTTAB_STRING(B, C) SWIG_LUA_STRING, (char *)B, 0, 0, (void *)C, 0
 #  define SWIG_LUA_CONSTTAB_CHAR(B, C) SWIG_LUA_CHAR, (char *)B, (long)C, 0, 0, 0
+#  define SWIG_LUA_CONSTTAB_POINTER(B,C,D)\
+       SWIG_LUA_POINTER, (char *)B, 0, 0, (void *)C, &D
+#  define SWIG_LUA_CONSTTAB_BINARY(B, S, C, D)\
+       SWIG_LUA_BINARY,  (char *)B, S, 0, (void *)C, &D
 #endif
 
+#ifndef SWIG_LUA_ELUA_EMULATE
 #if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
 #  define LRO_STRVAL(v) {{.p = (char *) v}, LUA_TSTRING}
 #  define LSTRVAL LRO_STRVAL
 #endif
+#endif /* SWIG_LUA_ELUA_EMULATE*/
+
+#ifndef SWIG_LUA_ELUA_EMULATE
+#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
+
+#ifndef MIN_OPT_LEVEL
+#define MIN_OPT_LEVEL 2
+#endif
 
+#include "lrodefs.h"
+#include "lrotable.h"
+#endif
+#endif /* SWIG_LUA_ELUA_EMULATE*/
 /* -----------------------------------------------------------------------------
  * compatibility defines
  * ----------------------------------------------------------------------------- */
@@ -790,6 +877,23 @@ extern "C" {
 # define lua_pushglobaltable(L) lua_pushvalue(L, LUA_GLOBALSINDEX)
 #endif
 
+/* lua_absindex was introduced in Lua 5.2 */
+#if !defined(LUA_VERSION_NUM) || LUA_VERSION_NUM < 502
+# define lua_absindex(L,i) ((i)>0 || (i) <= LUA_REGISTRYINDEX ? (i) : lua_gettop(L) + (i) + 1)
+#endif
+
+/* lua_rawsetp was introduced in Lua 5.2 */
+#if !defined(LUA_VERSION_NUM) || LUA_VERSION_NUM < 502
+#define lua_rawsetp(L,index,ptr)\
+  lua_pushlightuserdata(L,(void*)(ptr));\
+  lua_insert(L,-2);\
+  lua_rawset(L,index);
+
+#define lua_rawgetp(L,index,ptr)\
+  lua_pushlightuserdata(L,(void*)(ptr));\
+  lua_rawget(L,index);
+
+#endif
 
 /* --------------------------------------------------------------------------
  * Helper functions for error handling
@@ -839,6 +943,12 @@ typedef struct {
   lua_CFunction set;
 } swig_lua_var_info;
 
+#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
+typedef const LUA_REG_TYPE swig_lua_method;
+typedef const LUA_REG_TYPE swig_lua_const_info;
+#else /* Normal lua */
+typedef luaL_Reg swig_lua_method;
+
 /* Constant information structure */
 typedef struct {
     int type;
@@ -849,10 +959,7 @@ typedef struct {
     swig_type_info **ptype;
 } swig_lua_const_info;
 
-typedef struct {
-  const char     *name;
-  lua_CFunction   method;
-} swig_lua_method;
+#endif
 
 typedef struct {
   const char     *name;
@@ -860,23 +967,28 @@ typedef struct {
   lua_CFunction   setmethod;
 } swig_lua_attribute;
 
-// Can be used to create namespaces. Currently used to
-// wrap class static methods/variables/constants
-typedef struct {
+
+struct swig_lua_class;
+/* Can be used to create namespaces. Currently used to wrap class static methods/variables/constants */
+typedef struct swig_lua_namespace {
   const char            *name;
   swig_lua_method       *ns_methods;
   swig_lua_attribute    *ns_attributes;
   swig_lua_const_info   *ns_constants;
+  struct swig_lua_class        **ns_classes;
+  struct swig_lua_namespace    **ns_namespaces;
 } swig_lua_namespace;
 
 typedef struct swig_lua_class {
-  const char    *name;
+  const char    *name; /* Name that this class has in Lua */
+  const char    *fqname; /* Fully qualified name - Scope + class name */
   swig_type_info   **type;
   lua_CFunction  constructor;
   void    (*destructor)(void *);
   swig_lua_method   *methods;
   swig_lua_attribute     *attributes;
-  swig_lua_namespace    cls_static;
+  swig_lua_namespace    *cls_static;
+  swig_lua_method   *metatable; /* 0 for -eluac */
   struct swig_lua_class **bases;
   const char **base_names;
 } swig_lua_class;
@@ -940,18 +1052,23 @@ typedef struct {
       lua_pushcfunction(L, f), \
       lua_rawset(L,-3))
 
+#define SWIG_Lua_add_boolean(L,n,b) \
+  (lua_pushstring(L, n), \
+      lua_pushboolean(L, b), \
+      lua_rawset(L,-3))
+
 /* special helper for allowing 'nil' for usertypes */
 #define SWIG_isptrtype(L,I) (lua_isuserdata(L,I) || lua_isnil(L,I))
 
 #ifdef __cplusplus
 /* Special helper for member function pointers 
 it gets the address, casts it, then dereferences it */
-//#define SWIG_mem_fn_as_voidptr(a)  (*((char**)&(a)))
+/*#define SWIG_mem_fn_as_voidptr(a)  (*((char**)&(a))) */
 #endif
 
 /* storing/access of swig_module_info */
 SWIGRUNTIME swig_module_info *
-SWIG_Lua_GetModule(lua_StateL) {
+SWIG_Lua_GetModule(lua_State *L) {
   swig_module_info *ret = 0;
   lua_pushstring(L,"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME);
   lua_rawget(L,LUA_REGISTRYINDEX);
@@ -962,7 +1079,7 @@ SWIG_Lua_GetModule(lua_State* L) {
 }
 
 SWIGRUNTIME void
-SWIG_Lua_SetModule(lua_StateL, swig_module_info *module) {
+SWIG_Lua_SetModule(lua_State *L, swig_module_info *module) {
   /* add this all into the Lua registry: */
   lua_pushstring(L,"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME);
   lua_pushlightuserdata(L,(void*)module);
@@ -976,7 +1093,7 @@ SWIG_Lua_SetModule(lua_State* L, swig_module_info *module) {
 /* this function is called when trying to set an immutable.
 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_StateL)
+SWIGINTERN int SWIG_Lua_set_immutable(lua_State *L)
 {
 /*  there should be 1 param passed in: the new value */
 #ifndef SWIGLUA_IGNORE_SET_IMMUTABLE
@@ -986,170 +1103,153 @@ SWIGINTERN int SWIG_Lua_set_immutable(lua_State* L)
     return 0;   /* should not return anything */
 }
 
-/* the module.get method used for getting linked data */
-SWIGINTERN int SWIG_Lua_module_get(lua_State* L)
-{
-/*  there should be 2 params passed in
-  (1) table (not the meta table)
-  (2) string name of the attribute
-  printf("SWIG_Lua_module_get %p(%s) '%s'\n",
-   lua_topointer(L,1),lua_typename(L,lua_type(L,1)),
-   lua_tostring(L,2));
-*/
-  /* get the metatable */
-#if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
-  assert(lua_isrotable(L,1)); /* just in case */
-#else
-  assert(lua_istable(L,1)); /* default Lua action */
-#endif
-  lua_getmetatable(L,1);  /* get the metatable */
-#if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
-  assert(lua_isrotable(L,-1));  /* just in case */
-#else
-  assert(lua_istable(L,-1));
-#endif
-  SWIG_Lua_get_table(L,".get");  /* get the .get table */
-  lua_remove(L,3);  /* remove metatable */
-#if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
-  if (lua_isrotable(L,-1))
-#else
-  if (lua_istable(L,-1))
-#endif
-  {
-    /* look for the key in the .get table */
-    lua_pushvalue(L,2);  /* key */
-    lua_rawget(L,-2);
-    lua_remove(L,3);  /* remove .get */
-    if (lua_iscfunction(L,-1))
-    {  /* found it so call the fn & return its value */
-      lua_call(L,0,1);
-      return 1;
-    }
-    lua_pop(L,1);  /* remove the top */
-  }
-  lua_pop(L,1);  /* remove the .get */
-  lua_pushnil(L);  /* return a nil */
-  return 1;
-}
+#ifdef SWIG_LUA_ELUA_EMULATE
 
-/* the module.set method used for setting linked data */
-SWIGINTERN int SWIG_Lua_module_set(lua_State* L)
+SWIGRUNTIME void SWIG_Lua_NewPointerObj(lua_State *L,void *ptr,swig_type_info *type, int own);
+SWIGRUNTIME void SWIG_Lua_NewPackedObj(lua_State *L,void *ptr,size_t size,swig_type_info *type);
+static int swig_lua_elua_emulate_unique_key;
+
+/* This function emulates eLua rotables behaviour. It loads a rotable definition into the usual lua table. */
+SWIGINTERN void SWIG_Lua_elua_emulate_register(lua_State *L, const swig_elua_entry *table)
 {
-/*  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
-*/
-  /* get the metatable */
-#if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
-  assert(lua_isrotable(L,1));  /* just in case */
-#else
-  assert(lua_istable(L,1)); /* default Lua action */
-#endif
-  lua_getmetatable(L,1);  /* get the metatable */
-#if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
-  assert(lua_isrotable(L,-1));  /* just in case */
-#else
+  int i, table_parsed, parsed_tables_array, target_table;
   assert(lua_istable(L,-1));
-#endif
-  SWIG_Lua_get_table(L,".set");  /* get the .set table */
-  lua_remove(L,4);  /* remove metatable */
-#if ((SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC))
-  if (lua_isrotable(L,-1))
-#else
-  if (lua_istable(L,-1))
-#endif
+  target_table = lua_gettop(L);
+  /* Get the registry where we put all parsed tables to avoid loops */
+  lua_rawgetp(L, LUA_REGISTRYINDEX, &swig_lua_elua_emulate_unique_key);
+  if(lua_isnil(L,-1)) {
+    lua_pop(L,1);
+    lua_newtable(L);
+    lua_pushvalue(L,-1);
+    lua_rawsetp(L,LUA_REGISTRYINDEX,(void*)(&swig_lua_elua_emulate_unique_key));
+  }
+  parsed_tables_array = lua_gettop(L);
+  lua_pushvalue(L,target_table);
+  lua_rawsetp(L, parsed_tables_array, table);
+  table_parsed = 0;
+  const int SWIGUNUSED pairs_start = lua_gettop(L);
+  for(i = 0;table[i].key.type != LUA_TNIL || table[i].value.type != LUA_TNIL;i++)
   {
-    /* look for the key in the .set table */
-    lua_pushvalue(L,2);  /* key */
-    lua_rawget(L,-2);
-    lua_remove(L,4);  /* remove .set */
-    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;
+    const swig_elua_entry *entry = table + i;
+    int is_metatable = 0;
+    switch(entry->key.type) {
+      case LUA_TSTRING:
+        lua_pushstring(L,entry->key.key.strkey);
+        if(strcmp(entry->key.key.strkey, SWIG_LUA_ELUA_EMUL_METATABLE_KEY) == 0)
+          is_metatable = 1;
+        break;
+      case  LUA_TNUMBER:
+        lua_pushnumber(L,entry->key.key.numkey);
+        break;
+      case LUA_TNIL:
+        lua_pushnil(L);
+        break;
+      default:
+        assert(0);
     }
-#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) 
-    else {
-      return 0; // Exits stoically if an invalid key is initialized.
+    switch(entry->value.type) {
+      case LUA_TSTRING:
+        lua_pushstring(L,entry->value.value.string);
+        break;
+      case  LUA_TNUMBER:
+        lua_pushnumber(L,entry->value.value.number);
+        break;
+      case LUA_TFUNCTION:
+        lua_pushcfunction(L,entry->value.value.function);
+        break;
+      case LUA_TTABLE:
+        lua_rawgetp(L,parsed_tables_array, entry->value.value.table);
+        table_parsed = !lua_isnil(L,-1);
+        if(!table_parsed) {
+          lua_pop(L,1); /*remove nil */
+          lua_newtable(L);
+          SWIG_Lua_elua_emulate_register(L,entry->value.value.table);
+        } 
+        if(is_metatable) {
+          assert(lua_istable(L,-1));
+          lua_pushvalue(L,-1);
+          lua_setmetatable(L,target_table);
+        }
+
+        break;
+      case LUA_TUSERDATA:
+        if(entry->value.value.userdata.member) 
+          SWIG_NewMemberObj(L,entry->value.value.userdata.pvalue,
+              entry->value.value.userdata.lvalue,
+              *(entry->value.value.userdata.ptype));
+        else 
+          SWIG_NewPointerObj(L,entry->value.value.userdata.pvalue,
+              *(entry->value.value.userdata.ptype),0);
+        break;
+      case LUA_TNIL:
+        lua_pushnil(L);
+        break;
+      default:
+        assert(0);
     }
-#endif
+    assert(lua_gettop(L) == pairs_start + 2);
+    lua_rawset(L,target_table);
   }
-  lua_settop(L,3);  /* reset back to start */
-  /* we now have the table, key & new value, so just set directly */
-  lua_rawset(L,1);  /* add direct */
-  return 0;
+  lua_pop(L,1); /* Removing parsed tables storage */
+  assert(lua_gettop(L) == target_table);
 }
 
-#if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC))
-/* registering a module in lua. Pushes the module table on the stack. */
-SWIGINTERN void  SWIG_Lua_module_begin(lua_State* L,const char* name)
+SWIGINTERN void SWIG_Lua_elua_emulate_register_clear(lua_State *L)
 {
-  assert(lua_istable(L,-1));  /* just in case */
-  lua_pushstring(L,name);
-  lua_newtable(L);   /* the table */
-  /* add meta table */
-  lua_newtable(L);    /* the meta table */
-  SWIG_Lua_add_function(L,"__index",SWIG_Lua_module_get);
-  SWIG_Lua_add_function(L,"__newindex",SWIG_Lua_module_set);
-  lua_pushstring(L,".get");
-  lua_newtable(L);    /* the .get table */
-  lua_rawset(L,-3);  /* add .get into metatable */
-  lua_pushstring(L,".set");
-  lua_newtable(L);    /* the .set table */
-  lua_rawset(L,-3);  /* add .set into metatable */
-  lua_setmetatable(L,-2);  /* sets meta table in module */
-#ifdef SWIG_LUA_MODULE_GLOBAL
-  /* If requested, install the module directly into the global namespace. */
-  lua_rawset(L,-3);        /* add module into parent */
-  SWIG_Lua_get_table(L,name);   /* get the table back out */
-#else
-  /* Do not install the module table as global name. The stack top has
-     the module table with the name below. We pop the top and replace
-     the name with it. */
-  lua_replace(L,-2);
-#endif
+  lua_pushnil(L);
+  lua_rawsetp(L, LUA_REGISTRYINDEX, &swig_lua_elua_emulate_unique_key);
 }
 
-/* ending the register */
-SWIGINTERN void  SWIG_Lua_module_end(lua_State* L)
-{
-  lua_pop(L,1);       /* tidy stack (remove module) */
-}
+SWIGINTERN void SWIG_Lua_get_class_registry(lua_State *L);
 
-/* adding a linked variable to the module */
-SWIGINTERN void SWIG_Lua_module_add_variable(lua_State* L,const char* name,lua_CFunction getFn,lua_CFunction setFn)
+SWIGINTERN int SWIG_Lua_emulate_elua_getmetatable(lua_State *L)
 {
-  assert(lua_istable(L,-1));  /* just in case */
-  lua_getmetatable(L,-1);  /* get the metatable */
-  assert(lua_istable(L,-1));  /* just in case */
-  SWIG_Lua_get_table(L,".get"); /* find the .get table */
-  assert(lua_istable(L,-1));  /* should be a table: */
-  SWIG_Lua_add_function(L,name,getFn);
-  lua_pop(L,1);       /* tidy stack (remove table) */
-  if (setFn)  /* if there is a set fn */
-  {
-    SWIG_Lua_get_table(L,".set"); /* find the .set table */
-    assert(lua_istable(L,-1));  /* should be a table: */
-    SWIG_Lua_add_function(L,name,setFn);
-    lua_pop(L,1);       /* tidy stack (remove table) */
+  SWIG_check_num_args("getmetatable(SWIG eLua emulation)", 1, 1);
+  SWIG_Lua_get_class_registry(L);
+  lua_getfield(L,-1,"lua_getmetatable");
+  lua_remove(L,-2); /* remove the registry*/
+  assert(!lua_isnil(L,-1));
+  lua_pushvalue(L,1);
+  assert(lua_gettop(L) == 3); /* object | function | object again */
+  lua_call(L,1,1);
+  if(!lua_isnil(L,-1)) /*There is an ordinary metatable */
+    return 1;
+  /*if it is a table, then emulate elua behaviour - check for __metatable attribute of a table*/
+  assert(lua_gettop(L) == 2);
+  if(lua_istable(L,-2)) {
+    lua_pop(L,1); /*remove the nil*/
+    lua_getfield(L,-1, SWIG_LUA_ELUA_EMUL_METATABLE_KEY);
   }
-  lua_pop(L,1);       /* tidy stack (remove meta) */
+  assert(lua_gettop(L) == 2);
+  return 1;
+  
+fail:
+  lua_error(L);
+  return 0;
 }
-#endif
 
-/* adding a function module */
-SWIGINTERN void  SWIG_Lua_module_add_function(lua_State* L,const char* name,lua_CFunction fn)
+SWIGINTERN void SWIG_Lua_emulate_elua_swap_getmetatable(lua_State *L)
 {
-  SWIG_Lua_add_function(L,name,fn);
+  SWIG_Lua_get_class_registry(L);
+  lua_pushglobaltable(L);
+  lua_pushstring(L,"lua_getmetatable");
+  lua_getfield(L,-2,"getmetatable");
+  assert(!lua_isnil(L,-1));
+  lua_rawset(L,-4);
+  lua_pushstring(L, "getmetatable");
+  lua_pushcfunction(L, SWIG_Lua_emulate_elua_getmetatable);
+  lua_rawset(L,-3);
+  lua_pop(L,2);
+      
 }
+/* END OF REMOVE */
 
+#endif
 /* -----------------------------------------------------------------------------
- * global variable support code: namespaces
+ * global variable support code: namespaces and modules (which are the same thing)
  * ----------------------------------------------------------------------------- */
 
-SWIGINTERN int SWIG_Lua_namespace_get(lua_StateL)
+SWIGINTERN int SWIG_Lua_namespace_get(lua_State *L)
 {
 /*  there should be 2 params passed in
   (1) table (not the meta table)
@@ -1186,7 +1286,7 @@ SWIGINTERN int SWIG_Lua_namespace_get(lua_State* L)
   return 0;
 }
 
-SWIGINTERN int SWIG_Lua_namespace_set(lua_StateL)
+SWIGINTERN int SWIG_Lua_namespace_set(lua_State *L)
 {
 /*  there should be 3 params passed in
   (1) table (not the meta table)
@@ -1213,46 +1313,70 @@ SWIGINTERN int SWIG_Lua_namespace_set(lua_State* L)
     lua_pop(L,1);  /* remove the value */
   }
   lua_pop(L,1);  /* remove the value .set table */
+  lua_pop(L,1); /* remote metatable */
+  lua_rawset(L,-3);
   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
+#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA) /* In elua this is useless */
+SWIGINTERN void SWIG_Lua_InstallConstants(lua_State *L, swig_lua_const_info constants[]); /* forward declaration */
+SWIGINTERN void  SWIG_Lua_add_variable(lua_State *L,const char *name,lua_CFunction getFn,lua_CFunction setFn); /* forward declaration */
+SWIGINTERN void  SWIG_Lua_class_register(lua_State *L,swig_lua_class *clss);
 
 /* helper function - register namespace methods and attributes into namespace */
-SWIGINTERN int SWIG_Lua_add_namespace_details(lua_State* L, swig_lua_namespace* ns)
+SWIGINTERN int SWIG_Lua_add_namespace_details(lua_State *L, swig_lua_namespace *ns)
 {
-  int i = 0;
+  int i;
+  /* There must be namespace table (not metatable) at the top of the stack */
   assert(lua_istable(L,-1));
-  /* There must be table at the top of the stack */
   SWIG_Lua_InstallConstants(L, ns->ns_constants);
 
+  /* add methods to the namespace/module table */
+  for(i=0;ns->ns_methods[i].name;i++){
+    SWIG_Lua_add_function(L,ns->ns_methods[i].name,ns->ns_methods[i].func);
+  }
   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);
+    SWIG_Lua_add_variable(L,ns->ns_attributes[i].name,ns->ns_attributes[i].getmethod,ns->ns_attributes[i].setmethod);
   }
-  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)
+/* Register all classes in the namespace */
+SWIGINTERN void SWIG_Lua_add_namespace_classes(lua_State *L, swig_lua_namespace *ns)
 {
-  assert(lua_istable(L,-1)); /* just in case. This is supposed to be module table */
+  swig_lua_class **classes;
+
+  /* There must be a module/namespace table at the top of the stack */
+  assert(lua_istable(L,-1));
+
+  classes = ns->ns_classes;
+
+  if( classes != 0 ) {
+    while(*classes != 0) {
+      SWIG_Lua_class_register(L, *classes);
+      classes++;
+    }
+  }
+}
+
+/* Helper function. Creates namespace table and adds it to module table
+   if 'reg' is true, then will register namespace table to parent one (must be on top of the stack
+   when function is called).
+   Function always returns newly registered table on top of the stack.
+*/
+SWIGINTERN void SWIG_Lua_namespace_register(lua_State *L, swig_lua_namespace *ns, int reg)
+{
+  swig_lua_namespace **sub_namespace;
+  /* 1 argument - table on the top of the stack */
+  const int SWIGUNUSED begin = lua_gettop(L);
+  assert(lua_istable(L,-1)); /* just in case. This is supposed to be module table or parent namespace table */
   lua_checkstack(L,5);
-  lua_pushstring(L, ns->name);
   lua_newtable(L); /* namespace itself */
   lua_newtable(L); /* metatable for namespace */
 
@@ -1274,47 +1398,179 @@ SWIGINTERN int SWIG_Lua_namespace_register(lua_State* L, swig_lua_namespace* ns)
   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;
+
+  /* Register all functions, variables etc */
+  SWIG_Lua_add_namespace_details(L,ns);
+  /* Register classes */
+  SWIG_Lua_add_namespace_classes(L,ns);
+
+  sub_namespace = ns->ns_namespaces;
+  if( sub_namespace != 0) {
+    while(*sub_namespace != 0) {
+      SWIG_Lua_namespace_register(L, *sub_namespace, 1);
+      lua_pop(L,1); /* removing sub-namespace table */
+      sub_namespace++;
+    }
+  }
+
+  if (reg) {
+    lua_pushstring(L,ns->name);
+    lua_pushvalue(L,-2);
+    lua_rawset(L,-4); /* add namespace to module table */
+  }
+  assert(lua_gettop(L) == begin+1);
 }
+#endif /* SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA */
+
 /* -----------------------------------------------------------------------------
  * global variable support code: classes
  * ----------------------------------------------------------------------------- */
 
-/* the class.get method, performs the lookup of class attributes */
-SWIGINTERN int  SWIG_Lua_class_get(lua_State* L)
+SWIGINTERN void  SWIG_Lua_get_class_metatable(lua_State *L,const char *cname);
+
+typedef int (*swig_lua_base_iterator_func)(lua_State*,swig_type_info*, int, int *ret);
+
+SWIGINTERN int SWIG_Lua_iterate_bases(lua_State *L, swig_type_info * SWIGUNUSED swig_type,
+  int first_arg, swig_lua_base_iterator_func func, int  *const ret)
+{
+    /* first_arg - position of the object in stack. Everything that is above are arguments
+     * and is passed to every evocation of the func */
+    int last_arg = lua_gettop(L);/* position of last argument */
+    int original_metatable = last_arg + 1;
+    size_t bases_count;
+    int result = SWIG_ERROR;
+    int bases_table;
+    (void)swig_type;
+    lua_getmetatable(L,first_arg);
+
+    /* initialise base search */
+#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
+    SWIG_Lua_get_table(L,".bases");
+    assert(lua_istable(L,-1));
+    bases_count = lua_rawlen(L,-1);
+    bases_table = lua_gettop(L);
+#else
+    /* In elua .bases table doesn't exist. Use table from swig_lua_class */
+    (void)bases_table;
+    assert(swig_type!=0);
+    swig_module_info *module=SWIG_GetModule(L);
+    swig_lua_class **bases= ((swig_lua_class*)(swig_type->clientdata))->bases;
+    const char **base_names= ((swig_lua_class*)(swig_type->clientdata))->base_names;
+    bases_count = 0;
+    for(;base_names[bases_count];
+      bases_count++);/* get length of bases */
+#endif
+
+    if(ret)
+      *ret = 0;
+    if(bases_count>0)
+    {
+      int to_remove;
+      size_t i;
+      int j;
+      int subcall_last_arg;
+      int subcall_first_arg = lua_gettop(L) + 1;/* Here a copy of first_arg and arguments begin */
+      int valid = 1;
+      swig_type_info *base_swig_type = 0;
+      for(j=first_arg;j<=last_arg;j++)
+        lua_pushvalue(L,j);
+      subcall_last_arg = lua_gettop(L);
+
+      /* Trick: temporarily replacing original metatable with metatable for base class and call getter */
+      for(i=0;i<bases_count;i++) {
+        /* Iteration through class bases */
+#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
+        lua_rawgeti(L,bases_table,i+1);
+        base_swig_type = 0;
+        if(lua_isnil(L,-1)) {
+          valid = 0;
+          lua_pop(L,1);
+        } else {
+          valid = 1;
+        }
+#else /* In elua .bases table doesn't exist. Use table from swig_lua_class */
+        swig_lua_class *base_class = bases[i];
+        if(!base_class) {
+          valid = 0;
+        } else {
+          valid = 1;
+          SWIG_Lua_get_class_metatable(L,base_class->fqname);
+          base_swig_type = SWIG_TypeQueryModule(module,module,base_names[i]);
+          assert(base_swig_type != 0);
+        }
+#endif
+
+        if(!valid)
+          continue;
+        assert(lua_isuserdata(L, subcall_first_arg));
+        assert(lua_istable(L,-1));
+        lua_setmetatable(L,subcall_first_arg); /* Set new metatable */
+        assert(lua_gettop(L) == subcall_last_arg);
+        result = func(L, base_swig_type,subcall_first_arg, ret); /* Forward call */
+        if(result != SWIG_ERROR) {
+          break;
+        }
+      }
+      /* Restore original metatable */
+      lua_pushvalue(L,original_metatable);
+      lua_setmetatable(L,first_arg);
+      /* Clear - remove everything between last_arg and subcall_last_arg including */
+      to_remove = subcall_last_arg - last_arg;
+      for(j=0;j<to_remove;j++)
+        lua_remove(L,last_arg+1);
+    } else {
+      /* Remove everything after last_arg */
+      lua_pop(L, lua_gettop(L) - last_arg);
+    }
+    if(ret) assert(lua_gettop(L) == last_arg + *ret);
+    return result;
+}
+
+/* The class.get method helper, performs the lookup of class attributes.
+ * It returns an error code. Number of function return values is passed inside 'ret'.
+ * first_arg is not used in this function because function always has 2 arguments.
+ */
+SWIGINTERN int  SWIG_Lua_class_do_get(lua_State *L, swig_type_info *type, int SWIGUNUSED first_arg, int *ret)
 {
 /*  there should be 2 params passed in
   (1) userdata (not the meta table)
   (2) string name of the attribute
 */
+  int bases_search_result;
+  int substack_start = lua_gettop(L)-2;
+  assert(first_arg == substack_start+1);
+  lua_checkstack(L,5);
   assert(lua_isuserdata(L,-2));  /* just in case */
   lua_getmetatable(L,-2);    /* get the meta table */
   assert(lua_istable(L,-1));  /* just in case */
   SWIG_Lua_get_table(L,".get"); /* find the .get table */
   assert(lua_istable(L,-1));  /* just in case */
   /* look for the key in the .get table */
-  lua_pushvalue(L,2);  /* key */
+  lua_pushvalue(L,substack_start+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_pushvalue(L,1);  /* the userdata */
+    lua_pushvalue(L,substack_start+1);  /* the userdata */
     lua_call(L,1,1);  /* 1 value in (userdata),1 out (result) */
     lua_remove(L,-2); /* stack tidy, remove metatable */
-    return 1;
+    if(ret)
+      *ret = 1;
+    return SWIG_OK;
   }
   lua_pop(L,1);  /* remove whatever was there */
   /* ok, so try the .fn table */
-  SWIG_Lua_get_table(L,".fn"); /* find the .get table */
+  SWIG_Lua_get_table(L,".fn"); /* find the .fn table */
   assert(lua_istable(L,-1));  /* just in case */
-  lua_pushvalue(L,2);  /* key */
+  lua_pushvalue(L,substack_start+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: if its 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;
+    if(ret)
+      *ret = 1;
+    return SWIG_OK;
   }
   lua_pop(L,1);  /* remove whatever was there */
   /* NEW: looks for the __getitem() fn
@@ -1322,69 +1578,139 @@ SWIGINTERN int  SWIG_Lua_class_get(lua_State* L)
   SWIG_Lua_get_table(L,"__getitem"); /* find the __getitem fn */
   if (lua_iscfunction(L,-1))  /* if its there */
   {  /* found it so call the fn & return its value */
-    lua_pushvalue(L,1);  /* the userdata */
-    lua_pushvalue(L,2);  /* the parameter */
+    lua_pushvalue(L,substack_start+1);  /* the userdata */
+    lua_pushvalue(L,substack_start+2);  /* the parameter */
     lua_call(L,2,1);  /* 2 value in (userdata),1 out (result) */
     lua_remove(L,-2); /* stack tidy, remove metatable */
-    return 1;
+    if(ret) *ret = 1;
+    return SWIG_OK;
   }
-  return 0;  /* sorry not known */
+  lua_pop(L,1);
+  /* Remove the metatable */
+  lua_pop(L,1);
+  /* Search in base classes */
+  bases_search_result = SWIG_Lua_iterate_bases(L,type,substack_start+1,SWIG_Lua_class_do_get,ret);
+  return bases_search_result;  /* sorry not known */
+}
+
+/* the class.get method, performs the lookup of class attributes
+ */
+SWIGINTERN int  SWIG_Lua_class_get(lua_State *L)
+{
+/*  there should be 2 params passed in
+  (1) userdata (not the meta table)
+  (2) string name of the attribute
+*/
+  int result;
+  swig_lua_userdata *usr;
+  swig_type_info *type;
+  int ret = 0;
+  assert(lua_isuserdata(L,1));
+  usr=(swig_lua_userdata*)lua_touserdata(L,1);  /* get data */
+  type = usr->type;
+  result = SWIG_Lua_class_do_get(L,type,1,&ret);
+  if(result == SWIG_OK)
+    return ret;
+
+  return 0;
 }
 
-/* the class.set method, performs the lookup of class attributes */
-SWIGINTERN int  SWIG_Lua_class_set(lua_State* L)
+/* helper for the class.set method, performs the lookup of class attributes
+ * It returns error code. Number of function return values is passed inside 'ret'
+ */
+SWIGINTERN int  SWIG_Lua_class_do_set(lua_State *L, swig_type_info *type, int first_arg, int *ret)
 {
 /*  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
-printf("SWIG_Lua_class_set %p(%s) '%s' %p(%s)\n",
-      lua_topointer(L,1),lua_typename(L,lua_type(L,1)),
-      lua_tostring(L,2),
-      lua_topointer(L,3),lua_typename(L,lua_type(L,3)));*/
+  */
 
-  assert(lua_isuserdata(L,1));  /* just in case */
-  lua_getmetatable(L,1);    /* get the meta table */
+  int bases_search_result;
+  int substack_start = lua_gettop(L) - 3;
+  lua_checkstack(L,5);
+  assert(lua_isuserdata(L,substack_start+1));  /* just in case */
+  lua_getmetatable(L,substack_start+1);    /* get the meta table */
   assert(lua_istable(L,-1));  /* just in case */
+  if(ret)
+    *ret = 0; /* it is setter - number of return values is always 0 */
 
   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_pushvalue(L,substack_start+2);  /* key */
     lua_rawget(L,-2);
+    lua_remove(L,-2); /* tidy stack, remove .set table */
     if (lua_iscfunction(L,-1))
     {  /* found it so call the fn & return its value */
-      lua_pushvalue(L,1);  /* userdata */
-      lua_pushvalue(L,3);  /* value */
+      lua_pushvalue(L,substack_start+1);  /* userdata */
+      lua_pushvalue(L,substack_start+3);  /* value */
       lua_call(L,2,0);
-      return 0;
+      lua_remove(L,substack_start+4); /*remove metatable*/
+      return SWIG_OK;
     }
     lua_pop(L,1);  /* remove the value */
+  } else {
+    lua_pop(L,1);  /* remove the answer for .set table request*/
   }
-  lua_pop(L,1);  /* remove the value .set table */
   /* NEW: looks for the __setitem() fn
   this is a user provided set fn */
   SWIG_Lua_get_table(L,"__setitem"); /* find the fn */
   if (lua_iscfunction(L,-1))  /* if its there */
   {  /* found it so call the fn & return its value */
-    lua_pushvalue(L,1);  /* the userdata */
-    lua_pushvalue(L,2);  /* the parameter */
-    lua_pushvalue(L,3);  /* the value */
+    lua_pushvalue(L,substack_start+1);  /* the userdata */
+    lua_pushvalue(L,substack_start+2);  /* the parameter */
+    lua_pushvalue(L,substack_start+3);  /* the value */
     lua_call(L,3,0);  /* 3 values in ,0 out */
     lua_remove(L,-2); /* stack tidy, remove metatable */
-    return 1;
+    return SWIG_OK;
+  }
+  lua_pop(L,1); /* remove value */
+
+  lua_pop(L,1); /* remove metatable */
+  /* Search among bases */
+  bases_search_result = SWIG_Lua_iterate_bases(L,type,first_arg,SWIG_Lua_class_do_set,ret);
+  if(ret)
+    assert(*ret == 0);
+  assert(lua_gettop(L) == substack_start + 3);
+  return bases_search_result;
+}
+
+/* This is the actual method exported to Lua. It calls SWIG_Lua_class_do_set and correctly
+ * handles return values.
+ */
+SWIGINTERN int  SWIG_Lua_class_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
+  */
+  int ret = 0;
+  int result;
+  swig_lua_userdata *usr;
+  swig_type_info *type;
+  assert(lua_isuserdata(L,1));
+  usr=(swig_lua_userdata*)lua_touserdata(L,1);  /* get data */
+  type = usr->type;
+  result = SWIG_Lua_class_do_set(L,type,1,&ret);
+  if(result != SWIG_OK) {
+   SWIG_Lua_pushferrstring(L,"Assignment not possible. No setter/member with this name. For custom assignments implement __setitem method.");
+   lua_error(L);
+  } else {
+    assert(ret==0);
   }
   return 0;
 }
 
 /* the class.destruct method called by the interpreter */
-SWIGINTERN int  SWIG_Lua_class_destruct(lua_StateL)
+SWIGINTERN int  SWIG_Lua_class_destruct(lua_State *L)
 {
 /*  there should be 1 params passed in
   (1) userdata (not the meta table) */
-  swig_lua_userdatausr;
-  swig_lua_classclss;
+  swig_lua_userdata *usr;
+  swig_lua_class *clss;
   assert(lua_isuserdata(L,-1));  /* just in case */
   usr=(swig_lua_userdata*)lua_touserdata(L,-1);  /* get it */
   /* if must be destroyed & has a destructor */
@@ -1400,31 +1726,30 @@ SWIGINTERN int  SWIG_Lua_class_destruct(lua_State* L)
 }
 
 /* the class.__tostring method called by the interpreter and print */
-SWIGINTERN int  SWIG_Lua_class_tostring(lua_StateL)
+SWIGINTERN int  SWIG_Lua_class_tostring(lua_State *L)
 {
 /*  there should be 1 param passed in
   (1) userdata (not the metatable) */
+  const char *className;
+  void* userData;
   assert(lua_isuserdata(L,1));  /* just in case */
-  unsigned long userData = (unsigned long)lua_touserdata(L,1); /* get the userdata address for later */
+  userData = lua_touserdata(L,1); /* get the userdata address for later */
   lua_getmetatable(L,1);    /* get the meta table */
   assert(lua_istable(L,-1));  /* just in case */
-  
+
   lua_getfield(L, -1, ".type");
-  const char* className = lua_tostring(L, -1);
-  
-  char output[256];
-  sprintf(output, "<%s userdata: %lX>", className, userData);
-  
-  lua_pushstring(L, (const char*)output);
+  className = lua_tostring(L, -1);
+
+  lua_pushfstring(L, "<%s userdata: %p>", className, userData);
   return 1;
 }
 
 /* to manually disown some userdata */
-SWIGINTERN int  SWIG_Lua_class_disown(lua_StateL)
+SWIGINTERN int  SWIG_Lua_class_disown(lua_State *L)
 {
 /*  there should be 1 params passed in
   (1) userdata (not the meta table) */
-  swig_lua_userdatausr;
+  swig_lua_userdata *usr;
   assert(lua_isuserdata(L,-1));  /* just in case */
   usr=(swig_lua_userdata*)lua_touserdata(L,-1);  /* get it */
   
@@ -1432,25 +1757,69 @@ SWIGINTERN int  SWIG_Lua_class_disown(lua_State* L)
   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)
+/* lua callable function to compare userdata's value
+the issue is that two userdata may point to the same thing
+but to lua, they are different objects */
+SWIGRUNTIME int SWIG_Lua_class_equal(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;
+  int result;
+  swig_lua_userdata *usr1,*usr2;
+  if (!lua_isuserdata(L,1) || !lua_isuserdata(L,2))  /* just in case */
+    return 0;  /* nil reply */
+  usr1=(swig_lua_userdata*)lua_touserdata(L,1);  /* get data */
+  usr2=(swig_lua_userdata*)lua_touserdata(L,2);  /* get data */
+  /*result=(usr1->ptr==usr2->ptr && usr1->type==usr2->type); only works if type is the same*/
+  result=(usr1->ptr==usr2->ptr);
+   lua_pushboolean(L,result);
+  return 1;
+}
+
+/* populate table at the top of the stack with metamethods that ought to be inherited */
+SWIGINTERN void SWIG_Lua_populate_inheritable_metamethods(lua_State *L)
+{
+  SWIG_Lua_add_boolean(L, "__add", 1);
+  SWIG_Lua_add_boolean(L, "__sub", 1);
+  SWIG_Lua_add_boolean(L, "__mul", 1);
+  SWIG_Lua_add_boolean(L, "__div", 1);
+  SWIG_Lua_add_boolean(L, "__mod", 1);
+  SWIG_Lua_add_boolean(L, "__pow", 1);
+  SWIG_Lua_add_boolean(L, "__unm", 1);
+  SWIG_Lua_add_boolean(L, "__len", 1 );
+  SWIG_Lua_add_boolean(L, "__concat", 1 );
+  SWIG_Lua_add_boolean(L, "__eq", 1);
+  SWIG_Lua_add_boolean(L, "__lt", 1);
+  SWIG_Lua_add_boolean(L, "__le", 1);
+  SWIG_Lua_add_boolean(L, "__call", 1);
+  SWIG_Lua_add_boolean(L, "__tostring", 1);
+  SWIG_Lua_add_boolean(L, "__gc", 0);
+}
+
+/* creates the swig registry */
+SWIGINTERN void SWIG_Lua_create_class_registry(lua_State *L)
+{
+  /* create main SWIG registry table */
+  lua_pushstring(L,"SWIG");
+  lua_newtable(L);
+  /* populate it with some predefined data */
+
+  /* .library table. Placeholder */
+  lua_pushstring(L,".library");
+  lua_newtable(L);
+  {
+    /* list of metamethods that class inherits from its bases */
+    lua_pushstring(L,"inheritable_metamethods");
+    lua_newtable(L);
+    /* populate with list of metamethods */
+    SWIG_Lua_populate_inheritable_metamethods(L);
+    lua_rawset(L,-3);
+  }
+  lua_rawset(L,-3);
+
+  lua_rawset(L,LUA_REGISTRYINDEX);
 }
 
-/* gets the swig class registry (or creates it) */
-SWIGINTERN void  SWIG_Lua_get_class_registry(lua_StateL)
+/* gets the swig registry (or creates it) */
+SWIGINTERN void  SWIG_Lua_get_class_registry(lua_State *L)
 {
   /* add this all into the swig registry: */
   lua_pushstring(L,"SWIG");
@@ -1458,17 +1827,29 @@ SWIGINTERN void  SWIG_Lua_get_class_registry(lua_State* L)
   if (!lua_istable(L,-1))  /* not there */
   {  /* must be first time, so add it */
     lua_pop(L,1);  /* remove the result */
-    lua_pushstring(L,"SWIG");
-    lua_newtable(L);
-    lua_rawset(L,LUA_REGISTRYINDEX);
+    SWIG_Lua_create_class_registry(L);
     /* then get it */
     lua_pushstring(L,"SWIG");
     lua_rawget(L,LUA_REGISTRYINDEX);
   }
 }
 
-/* helper fn to get the classes metatable from the register */
-SWIGINTERN void  SWIG_Lua_get_class_metatable(lua_State* L,const char* cname)
+SWIGINTERN void SWIG_Lua_get_inheritable_metamethods(lua_State *L)
+{
+  SWIG_Lua_get_class_registry(L);
+  lua_pushstring(L, ".library");
+  lua_rawget(L,-2);
+  assert( !lua_isnil(L,-1) );
+  lua_pushstring(L, "inheritable_metamethods");
+  lua_rawget(L,-2);
+
+  /* Remove class registry and library table */
+  lua_remove(L,-2);
+  lua_remove(L,-2);
+}
+
+/* Helper function to get the classes metatable from the register */
+SWIGINTERN void  SWIG_Lua_get_class_metatable(lua_State *L,const char *cname)
 {
   SWIG_Lua_get_class_registry(L);  /* get the registry */
   lua_pushstring(L,cname);  /* get the name */
@@ -1476,8 +1857,96 @@ SWIGINTERN void  SWIG_Lua_get_class_metatable(lua_State* L,const char* cname)
   lua_remove(L,-2);    /* tidy up (remove registry) */
 }
 
+/* Set up the base classes pointers.
+Each class structure has a list of pointers to the base class structures.
+This function fills them.
+It cannot be done at compile time, as this will not work with hireachies
+spread over more than one swig file. 
+Therefore it must be done at runtime, querying the SWIG type system.
+*/
+SWIGINTERN void SWIG_Lua_init_base_class(lua_State *L,swig_lua_class *clss)
+{
+  int i=0;
+  swig_module_info *module=SWIG_GetModule(L);
+  for(i=0;clss->base_names[i];i++)
+  {
+    if (clss->bases[i]==0) /* not found yet */
+    {
+      /* lookup and cache the base class */
+      swig_type_info *info = SWIG_TypeQueryModule(module,module,clss->base_names[i]);
+      if (info) clss->bases[i] = (swig_lua_class *) info->clientdata;
+    }
+  }
+}
+
+#if defined(SWIG_LUA_SQUASH_BASES) && (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
+/* Merges two tables  */
+SWIGINTERN int SWIG_Lua_merge_tables_by_index(lua_State *L, int target, int source)
+{
+  /* iterating */
+  lua_pushnil(L);
+  while (lua_next(L,source) != 0) {
+    /* -1 - value, -2 - index */
+    /* have to copy to assign */
+    lua_pushvalue(L,-2); /* copy of index */
+    lua_pushvalue(L,-2); /* copy of value */
+    lua_rawset(L, target);
+    lua_pop(L,1);
+    /* only key is left */
+  }
+}
+
+/* Merges two tables with given name. original - index of target metatable, base - index of source metatable */
+SWIGINTERN int SWIG_Lua_merge_tables(lua_State *L, const char* name, int original, int base)
+{
+  /* push original[name], then base[name] */
+  lua_pushstring(L,name);
+  lua_rawget(L,original);
+  int original_table = lua_gettop(L);
+  lua_pushstring(L,name);
+  lua_rawget(L,base);
+  int base_table = lua_gettop(L);
+  SWIG_Lua_merge_tables_by_index(L, original_table, base_table);
+  /* clearing stack */
+  lua_pop(L,2);
+}
+
+/* Function takes all symbols from base and adds it to derived class. It's just a helper. */
+SWIGINTERN int SWIG_Lua_class_squash_base(lua_State *L, swig_lua_class *base_cls)
+{
+  /* There is one parameter - original, i.e. 'derived' class metatable */
+  assert(lua_istable(L,-1));
+  int original = lua_gettop(L);
+  SWIG_Lua_get_class_metatable(L,base_cls->fqname);
+  int base = lua_gettop(L);
+  SWIG_Lua_merge_tables(L, ".fn", original, base );
+  SWIG_Lua_merge_tables(L, ".set", original, base );
+  SWIG_Lua_merge_tables(L, ".get", original, base );
+  lua_pop(L,1);
+}
+
+/* Function squashes all symbols from 'clss' bases into itself */
+SWIGINTERN int  SWIG_Lua_class_squash_bases(lua_State *L, swig_lua_class *clss)
+{
+  int i;
+  SWIG_Lua_get_class_metatable(L,clss->fqname);
+  for(i=0;clss->base_names[i];i++)
+  {
+    if (clss->bases[i]==0) /* Somehow it's not found. Skip it */
+      continue;
+    /* Thing is: all bases are already registered. Thus they have already executed
+     * this function. So we just need to squash them into us, because their bases
+     * are already squashed into them. No need for recursion here!
+     */
+    SWIG_Lua_class_squash_base(L, clss->bases[i]);
+  }
+  lua_pop(L,1); /*tidy stack*/
+}
+#endif
+
+#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA) /* In elua this is useless */
 /* helper add a variable to a registered class */
-SWIGINTERN void  SWIG_Lua_add_class_variable(lua_State* L,const char* name,lua_CFunction getFn,lua_CFunction setFn)
+SWIGINTERN void  SWIG_Lua_add_variable(lua_State *L,const char *name,lua_CFunction getFn,lua_CFunction setFn)
 {
   assert(lua_istable(L,-1));  /* just in case */
   SWIG_Lua_get_table(L,".get"); /* find the .get table */
@@ -1494,7 +1963,7 @@ SWIGINTERN void  SWIG_Lua_add_class_variable(lua_State* L,const char* name,lua_C
 }
 
 /* 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)
+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 */
@@ -1505,72 +1974,269 @@ SWIGINTERN void SWIG_Lua_add_class_static_details(lua_State* L, swig_lua_class*
     SWIG_Lua_add_class_static_details(L,clss->bases[i]);
   }
 
-  SWIG_Lua_add_namespace_details(L, &clss->cls_static);
+  SWIG_Lua_add_namespace_details(L, clss->cls_static);
 }
 
+SWIGINTERN void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class *clss); /* forward declaration */
+
 /* helper to recursively add class details (attributes & operations) */
-SWIGINTERN void  SWIG_Lua_add_class_details(lua_State* L,swig_lua_class* clss)
+SWIGINTERN void  SWIG_Lua_add_class_instance_details(lua_State *L, swig_lua_class *clss)
 {
   int i;
-  /* call all the base classes first: we can then override these later: */
+  size_t bases_count = 0;
+  /* Add bases to .bases table */
+  SWIG_Lua_get_table(L,".bases");
+  assert(lua_istable(L,-1));  /* just in case */
   for(i=0;clss->bases[i];i++)
   {
-    SWIG_Lua_add_class_details(L,clss->bases[i]);
+    SWIG_Lua_get_class_metatable(L,clss->bases[i]->fqname);
+    /* Base class must be already registered */
+    assert(lua_istable(L,-1));
+    lua_rawseti(L,-2,i+1); /* In lua indexing starts from 1 */
+    bases_count++;
   }
-  /* add fns */
+  assert(lua_rawlen(L,-1) == bases_count);
+  lua_pop(L,1); /* remove .bases table */
+  /* add attributes */
   for(i=0;clss->attributes[i].name;i++){
-    SWIG_Lua_add_class_variable(L,clss->attributes[i].name,clss->attributes[i].getmethod,clss->attributes[i].setmethod);
+    SWIG_Lua_add_variable(L,clss->attributes[i].name,clss->attributes[i].getmethod,clss->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;clss->methods[i].name;i++){
-    SWIG_Lua_add_function(L,clss->methods[i].name,clss->methods[i].method);
+    SWIG_Lua_add_function(L,clss->methods[i].name,clss->methods[i].func);
   }
   lua_pop(L,1);       /* tidy stack (remove table) */
-  /*   add operator overloads
-    these look ANY method which start with "__" and assume they
-    are operator overloads & add them to the metatable
-    (this might mess up is someone defines a method __gc (the destructor)*/
-  for(i=0;clss->methods[i].name;i++){
-    if (clss->methods[i].name[0]=='_' && clss->methods[i].name[1]=='_'){
-      SWIG_Lua_add_function(L,clss->methods[i].name,clss->methods[i].method);
+  /* add operator overloads
+    This adds methods from metatable array to metatable. Can mess up garbage
+    collectind if someone defines __gc method
+    */
+  if(clss->metatable) {
+    for(i=0;clss->metatable[i].name;i++) {
+      SWIG_Lua_add_function(L,clss->metatable[i].name,clss->metatable[i].func);
     }
   }
+
+#if !defined(SWIG_LUA_SQUASH_BASES)
+  /* Adding metamethods that are defined in base classes. If bases were squashed
+   * then it is obviously unnecessary
+   */
+  SWIG_Lua_add_class_user_metamethods(L, clss);
+#endif
 }
 
-/* set up the base classes pointers.
-Each class structure has a list of pointers to the base class structures.
-This function fills them.
-It cannot be done at compile time, as this will not work with hireachies
-spread over more than one swig file. 
-Therefore it must be done at runtime, querying the SWIG type system.
+/* Helpers to add user defined class metamedhods - __add, __sub etc. The helpers are needed
+   for the following issue: Lua runtime checks for metamethod existence with rawget function
+   ignoring our SWIG-provided __index and __newindex functions. Thus our inheritance-aware method
+   search algorithm doesn't work in such case. (Not to say that Lua runtime queries metamethod directly
+   in metatable and not in object).
+   Current solution is this: if somewhere in hierarchy metamethod __x is defined, then all descendants
+   are automatically given a special proxy __x that calls the real __x method.
+   Obvious idea - to copy __x instead of creating __x-proxy is wrong because if someone changes __x in runtime,
+   those changes must be reflected in all descendants.
 */
-SWIGINTERN void SWIG_Lua_init_base_class(lua_State* L,swig_lua_class* clss)
+
+SWIGRUNTIME int SWIG_Lua_resolve_metamethod(lua_State *L); /*forward declaration*/
+
+/* The real function that resolves a metamethod.
+ * Function searches given class and all it's bases(recursively) for first instance of something that is
+ * not equal to SWIG_Lua_resolve_metatmethod. (Almost always this 'something' is actual metamethod implementation
+ * and it is a SWIG-generated C function.). It returns value on the top of the L and there is no garbage below the
+ * answer.
+ * Returns 1 if found, 0 otherwise.
+ * clss is class which metatable we will search for method
+ * metamethod_name_idx is index in L where metamethod name (as string) lies
+ * skip_check allows to skip searching metamethod in givel clss and immideatelly go to searching in bases. skip_check
+ * is not caried to subsequent recursive calls - false is always passed. It is set to true only at first call from
+ * SWIG_Lua_resolve_metamethod
+ * */
+SWIGINTERN int SWIG_Lua_do_resolve_metamethod(lua_State *L, const swig_lua_class *clss, int metamethod_name_idx,
+    int skip_check)
 {
-  int i=0;
-  swig_module_info* module=SWIG_GetModule(L);
-  for(i=0;clss->base_names[i];i++)
+  /* This function is called recursively */
+  int result = 0;
+  int i = 0;
+
+  if (!skip_check) {
+    SWIG_Lua_get_class_metatable(L, clss->fqname);
+    lua_pushvalue(L, metamethod_name_idx);
+    lua_rawget(L,-2);
+    /* If this is cfunction and it is equal to SWIG_Lua_resolve_metamethod then
+     * this isn't the function we are looking for :)
+     * lua_tocfunction will return NULL if not cfunction
+     */
+    if (!lua_isnil(L,-1) && lua_tocfunction(L,-1) != SWIG_Lua_resolve_metamethod ) {
+      lua_remove(L,-2); /* removing class metatable */
+      return 1;
+    }
+    lua_pop(L,2); /* remove class metatable and query result */
+  }
+
+  /* Forwarding calls to bases */
+  for(i=0;clss->bases[i];i++)
   {
-    if (clss->bases[i]==0) /* not found yet */
-    {
-      /* lookup and cache the base class */
-      swig_type_info *info = SWIG_TypeQueryModule(module,module,clss->base_names[i]);
-      if (info) clss->bases[i] = (swig_lua_class *) info->clientdata;
+    result = SWIG_Lua_do_resolve_metamethod(L, clss->bases[i], metamethod_name_idx, 0);
+    if (result)
+      break;
+  }
+
+  return result;
+}
+
+/* The proxy function for metamethod. All parameters are passed as cclosure. Searches for actual method
+ * and calls it */
+SWIGRUNTIME int SWIG_Lua_resolve_metamethod(lua_State *L)
+{
+  int numargs;
+  int metamethod_name_idx;
+  const swig_lua_class* clss;
+  int result;
+
+  lua_checkstack(L,5);
+  numargs = lua_gettop(L); /* number of arguments to pass to actual metamethod */
+  
+  /* Get upvalues from closure */
+  lua_pushvalue(L, lua_upvalueindex(1)); /*Get function name*/
+  metamethod_name_idx = lua_gettop(L);
+  
+  lua_pushvalue(L, lua_upvalueindex(2));
+  clss = (const swig_lua_class*)(lua_touserdata(L,-1));
+  lua_pop(L,1); /* remove lightuserdata with clss from stack */
+
+  /* Actual work */
+  result = SWIG_Lua_do_resolve_metamethod(L, clss, metamethod_name_idx, 1);
+  if (!result) {
+   SWIG_Lua_pushferrstring(L,"The metamethod proxy is set, but it failed to find actual metamethod. Memory corruption is most likely explanation.");
+   lua_error(L);
+   return 0;
+  }
+
+  lua_remove(L,-2); /* remove metamethod key */
+  lua_insert(L,1); /* move function to correct position */
+  lua_call(L, numargs, LUA_MULTRET);
+  return lua_gettop(L); /* return all results */
+}
+
+
+/* If given metamethod must be present in given class, then creates appropriate proxy
+ * Returns 1 if successfully added, 0 if not added because no base class has it, -1
+ * if method is defined in the class metatable itself
+ */
+SWIGINTERN int SWIG_Lua_add_class_user_metamethod(lua_State *L, swig_lua_class *clss, const int metatable_index)
+{
+  int key_index;
+  int success = 0;
+  int i = 0;
+
+  /* metamethod name - on the top of the stack */
+  assert(lua_isstring(L,-1));
+  
+  key_index = lua_gettop(L);
+
+  /* Check whether method is already defined in metatable */
+  lua_pushvalue(L,key_index); /* copy of the key */
+  lua_gettable(L,metatable_index);
+  if( !lua_isnil(L,-1) ) {
+    lua_pop(L,1);
+    return -1;
+  }
+  lua_pop(L,1); 
+
+  /* Iterating over immediate bases */
+  for(i=0;clss->bases[i];i++)
+  {
+    const swig_lua_class *base = clss->bases[i];
+    SWIG_Lua_get_class_metatable(L, base->fqname);
+    lua_pushvalue(L, key_index);
+    lua_rawget(L, -2);
+    if( !lua_isnil(L,-1) ) {
+      lua_pushvalue(L, key_index); 
+
+      /* Add proxy function */
+      lua_pushvalue(L, key_index); /* first closure value is function name */
+      lua_pushlightuserdata(L, clss); /* second closure value is swig_lua_class structure */
+      lua_pushcclosure(L, SWIG_Lua_resolve_metamethod, 2);
+      
+      lua_rawset(L, metatable_index);
+      success = 1;
     }
+    lua_pop(L,1); /* remove function or nil */
+    lua_pop(L,1); /* remove base class metatable */
+
+    if( success )
+      break;
   }
+
+  return success; 
+}
+
+SWIGINTERN void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class *clss)
+{
+  int metatable_index;
+  int metamethods_info_index;
+  int tostring_undefined;
+  int eq_undefined = 0;
+
+  SWIG_Lua_get_class_metatable(L, clss->fqname);
+  metatable_index = lua_gettop(L);
+  SWIG_Lua_get_inheritable_metamethods(L);
+  assert(lua_istable(L,-1));
+  metamethods_info_index = lua_gettop(L);
+  lua_pushnil(L); /* first key */
+  while(lua_next(L, metamethods_info_index) != 0 ) {
+    /* key at index -2, value at index -1 */
+    const int is_inheritable = lua_toboolean(L,-2);
+    lua_pop(L,1); /* remove value - we don't need it anymore */
+
+    if(is_inheritable) { /* if metamethod is inheritable */
+      SWIG_Lua_add_class_user_metamethod(L,clss,metatable_index);
+    }
+  }
+
+  lua_pop(L,1); /* remove inheritable metatmethods table */
+
+  /* Special handling for __tostring method */
+  lua_pushstring(L, "__tostring");
+  lua_pushvalue(L,-1);
+  lua_rawget(L,metatable_index);
+  tostring_undefined = lua_isnil(L,-1);
+  lua_pop(L,1);
+  if( tostring_undefined ) {
+    lua_pushcfunction(L, SWIG_Lua_class_tostring);
+    lua_rawset(L, metatable_index);
+  } else {
+    lua_pop(L,1); /* remove copy of the key */
+  }
+
+  /* Special handling for __eq method */
+  lua_pushstring(L, "__eq");
+  lua_pushvalue(L,-1);
+  lua_rawget(L,metatable_index);
+  eq_undefined = lua_isnil(L,-1);
+  lua_pop(L,1);
+  if( eq_undefined ) {
+    lua_pushcfunction(L, SWIG_Lua_class_equal);
+    lua_rawset(L, metatable_index);
+  } else {
+    lua_pop(L,1); /* remove copy of the key */
+  }
+  /* Warning: __index and __newindex are SWIG-defined. For user-defined operator[]
+   * a __getitem/__setitem method should be defined
+   */
+  lua_pop(L,1); /* pop class metatable */
 }
 
 /* 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)
+SWIGINTERN void SWIG_Lua_class_register_static(lua_State *L, swig_lua_class *clss)
 {
+  const int SWIGUNUSED begin = lua_gettop(L);
   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 */
+  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_namespace_register(L,clss->cls_static, 1);
 
-  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
@@ -1579,10 +2245,9 @@ SWIGINTERN void SWIG_Lua_class_register_static(lua_State* L, swig_lua_class* cls
   (this overcomes the problem of pure virtual classes without constructors)*/
   if (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);
+    SWIG_Lua_add_function(L,"__call", clss->constructor);
     lua_pop(L,1);
   }
 
@@ -1591,19 +2256,60 @@ SWIGINTERN void SWIG_Lua_class_register_static(lua_State* L, swig_lua_class* cls
 
   /* clear stack */
   lua_pop(L,1);
+  assert( lua_gettop(L) == begin );
 }
 
-/* performs the entire class registration process */
-SWIGINTERN void  SWIG_Lua_class_register(lua_State* L,swig_lua_class* clss)
+/* Performs the instance (non-static) class registration process. Metatable for class is created
+ * and added to the class registry.
+ */
+SWIGINTERN void  SWIG_Lua_class_register_instance(lua_State *L,swig_lua_class *clss)
 {
-  SWIG_Lua_class_register_static(L,clss);
-
+  const int SWIGUNUSED begin = lua_gettop(L);
+  int i;
+  /* if name already there (class is already registered) then do nothing */
+  SWIG_Lua_get_class_registry(L);  /* get the registry */
+  lua_pushstring(L,clss->fqname);  /* get the name */
+  lua_rawget(L,-2);
+  if(!lua_isnil(L,-1)) {
+    lua_pop(L,2);
+    assert(lua_gettop(L)==begin);
+    return;
+  }
+  lua_pop(L,2); /* tidy stack */
+  /* Recursively initialize all bases */
+  for(i=0;clss->bases[i];i++)
+  {
+    SWIG_Lua_class_register_instance(L,clss->bases[i]);
+  }
+  /* Again, get registry and push name */
   SWIG_Lua_get_class_registry(L);  /* get the registry */
-  lua_pushstring(L,clss->name);  /* get the name */
+  lua_pushstring(L,clss->fqname);  /* get the name */
   lua_newtable(L);    /* create the metatable */
+#if defined(SWIG_LUA_SQUASH_BASES) && (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
+  /* If squashing is requested, then merges all bases metatable into this one.
+   * It would get us all special methods: __getitem, __add etc.
+   * This would set .fn, .type, and other .xxx incorrectly, but we will overwrite it right away
+   */
+  {
+    int new_metatable_index = lua_absindex(L,-1);
+    for(i=0;clss->bases[i];i++)
+    {
+      int base_metatable;
+      SWIG_Lua_get_class_metatable(L,clss->bases[i]->fqname);
+      base_metatable = lua_absindex(L,-1);
+      SWIG_Lua_merge_tables_by_index(L,new_metatable_index, base_metatable);
+      lua_pop(L,1);
+    }
+  }
+  /* And now we will overwrite all incorrectly set data */
+#endif
   /* add string of class name called ".type" */
   lua_pushstring(L,".type");
-  lua_pushstring(L,clss->name);
+  lua_pushstring(L,clss->fqname);
+  lua_rawset(L,-3);
+  /* add a table called bases */
+  lua_pushstring(L,".bases");
+  lua_newtable(L);
   lua_rawset(L,-3);
   /* add a table called ".get" */
   lua_pushstring(L,".get");
@@ -1623,27 +2329,99 @@ SWIGINTERN void  SWIG_Lua_class_register(lua_State* L,swig_lua_class* clss)
   SWIG_Lua_add_function(L,"__index",SWIG_Lua_class_get);
   SWIG_Lua_add_function(L,"__newindex",SWIG_Lua_class_set);
   SWIG_Lua_add_function(L,"__gc",SWIG_Lua_class_destruct);
-  /* add tostring method for better output */
-  SWIG_Lua_add_function(L,"__tostring",SWIG_Lua_class_tostring);
   /* add it */
   lua_rawset(L,-3);  /* metatable into registry */
   lua_pop(L,1);      /* tidy stack (remove registry) */
+  assert(lua_gettop(L) == begin);
 
-  SWIG_Lua_get_class_metatable(L,clss->name);
-  SWIG_Lua_add_class_details(L,clss);  /* recursive adding of details (atts & ops) */
+#if defined(SWIG_LUA_SQUASH_BASES) && (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
+  /* Now merge all symbols from .fn, .set, .get etc from bases to our tables */
+  SWIG_Lua_class_squash_bases(L,clss);
+#endif
+  SWIG_Lua_get_class_metatable(L,clss->fqname);
+  SWIG_Lua_add_class_instance_details(L,clss);  /* recursive adding of details (atts & ops) */
   lua_pop(L,1);      /* tidy stack (remove class metatable) */
+  assert( lua_gettop(L) == begin );
 }
 
+SWIGINTERN void  SWIG_Lua_class_register(lua_State *L,swig_lua_class *clss)
+{
+  int SWIGUNUSED begin;
+  assert(lua_istable(L,-1)); /* This is a table (module or namespace) where classes will be added */
+  SWIG_Lua_class_register_instance(L,clss);
+  SWIG_Lua_class_register_static(L,clss);
+
+  /* Add links from static part to instance part and vice versa */
+  /* [SWIG registry]                                   [Module]
+   *    "MyClass" ----> [MyClass metatable] <=====     "MyClass" -+> [static part]
+   *                     ".get" ----> ...        |                |     getmetatable()----|
+   *                     ".set" ----> ...        |                |                       |
+   *                     ".static" --------------)----------------/           [static part metatable]
+   *                                             |                                ".get" --> ...
+   *                                             |                                ".set" --> ....
+   *                                             |=============================== ".instance"
+   */
+  begin = lua_gettop(L);
+  lua_pushstring(L,clss->cls_static->name);
+  lua_rawget(L,-2); /* get class static table */
+  assert(lua_istable(L,-1));
+  lua_getmetatable(L,-1);
+  assert(lua_istable(L,-1)); /* get class static metatable */
+  lua_pushstring(L,".instance"); /* prepare key */
+
+  SWIG_Lua_get_class_metatable(L,clss->fqname); /* get class metatable */
+  assert(lua_istable(L,-1));
+  lua_pushstring(L,".static"); /* prepare key */
+  lua_pushvalue(L, -4); /* push static class TABLE */
+  assert(lua_istable(L,-1));
+  lua_rawset(L,-3); /* assign static class table(!NOT metatable) as ".static" member of class metatable */
+  lua_rawset(L,-3); /* assign class metatable as ".instance" member of class static METATABLE */
+  lua_pop(L,2);
+  assert(lua_gettop(L) == begin);
+}
+#endif /* SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA */
+
+#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
+SWIGINTERN void SWIG_Lua_elua_class_register_instance(lua_State *L, swig_lua_class *clss)
+{
+  const int SWIGUNUSED begin = lua_gettop(L);
+  int i;
+  /* if name already there (class is already registered) then do nothing */
+  SWIG_Lua_get_class_registry(L);  /* get the registry */
+  lua_pushstring(L,clss->fqname);  /* get the name */
+  lua_rawget(L,-2);
+  if(!lua_isnil(L,-1)) {
+    lua_pop(L,2);
+    assert(lua_gettop(L)==begin);
+    return;
+  }
+  lua_pop(L,2); /* tidy stack */
+  /* Recursively initialize all bases */
+  for(i=0;clss->bases[i];i++)
+  {
+    SWIG_Lua_elua_class_register_instance(L,clss->bases[i]);
+  }
+  /* Again, get registry and push name */
+  SWIG_Lua_get_class_registry(L);  /* get the registry */
+  lua_pushstring(L,clss->fqname);  /* get the name */
+  assert(clss->metatable);
+  lua_pushrotable(L, (void*)(clss->metatable));    /* create the metatable */
+  lua_rawset(L,-3);
+  lua_pop(L,1);
+  assert(lua_gettop(L) == begin);
+}
+#endif /* elua && eluac */
+
 /* -----------------------------------------------------------------------------
  * Class/structure conversion fns
  * ----------------------------------------------------------------------------- */
 
 /* helper to add metatable to new lua object */
-SWIGINTERN void _SWIG_Lua_AddMetatable(lua_State* L,swig_type_info *type)
+SWIGINTERN void SWIG_Lua_AddMetatable(lua_State *L,swig_type_info *type)
 {
   if (type->clientdata)  /* there is clientdata: so add the metatable */
   {
-    SWIG_Lua_get_class_metatable(L,((swig_lua_class*)(type->clientdata))->name);
+    SWIG_Lua_get_class_metatable(L,((swig_lua_class*)(type->clientdata))->fqname);
     if (lua_istable(L,-1))
     {
       lua_setmetatable(L,-2);
@@ -1656,9 +2434,9 @@ SWIGINTERN void _SWIG_Lua_AddMetatable(lua_State* L,swig_type_info *type)
 }
 
 /* pushes a new object into the lua stack */
-SWIGRUNTIME void SWIG_Lua_NewPointerObj(lua_State* L,void* ptr,swig_type_info *type, int own)
+SWIGRUNTIME void SWIG_Lua_NewPointerObj(lua_State *L,void *ptr,swig_type_info *type, int own)
 {
-  swig_lua_userdatausr;
+  swig_lua_userdata *usr;
   if (!ptr){
     lua_pushnil(L);
     return;
@@ -1668,15 +2446,15 @@ SWIGRUNTIME void SWIG_Lua_NewPointerObj(lua_State* L,void* ptr,swig_type_info *t
   usr->type=type;
   usr->own=own;
 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)
-  _SWIG_Lua_AddMetatable(L,type); /* add metatable */
+  SWIG_Lua_AddMetatable(L,type); /* add metatable */
 #endif
 }
 
 /* takes a object from the lua stack & converts it into an object of the correct type
  (if possible) */
-SWIGRUNTIME int  SWIG_Lua_ConvertPtr(lua_State* L,int index,void** ptr,swig_type_info *type,int flags)
+SWIGRUNTIME int  SWIG_Lua_ConvertPtr(lua_State *L,int index,void **ptr,swig_type_info *type,int flags)
 {
-  swig_lua_userdatausr;
+  swig_lua_userdata *usr;
   swig_cast_info *cast;
   if (lua_isnil(L,index)){*ptr=0; return SWIG_OK;}    /* special case: lua nil => NULL pointer */
   usr=(swig_lua_userdata*)lua_touserdata(L,index);  /* get data */
@@ -1703,9 +2481,9 @@ SWIGRUNTIME int  SWIG_Lua_ConvertPtr(lua_State* L,int index,void** ptr,swig_type
   return SWIG_ERROR;  /* error */
 }
 
-SWIGRUNTIME void* SWIG_Lua_MustGetPtr(lua_StateL,int index,swig_type_info *type,int flags,
-       int argnum,const charfunc_name){
-  voidresult;
+SWIGRUNTIME void* SWIG_Lua_MustGetPtr(lua_State *L,int index,swig_type_info *type,int flags,
+       int argnum,const char *func_name){
+  void *result;
   if (!SWIG_IsOK(SWIG_ConvertPtr(L,index,&result,type,flags))){
     luaL_error (L,"Error in %s, expected a %s at argument number %d\n",
                func_name,(type && type->str)?type->str:"void*",argnum);
@@ -1714,21 +2492,21 @@ SWIGRUNTIME void* SWIG_Lua_MustGetPtr(lua_State* L,int index,swig_type_info *typ
 }
 
 /* pushes a packed userdata. user for member fn pointers only */
-SWIGRUNTIME void SWIG_Lua_NewPackedObj(lua_State* L,void* ptr,size_t size,swig_type_info *type)
+SWIGRUNTIME void SWIG_Lua_NewPackedObj(lua_State *L,void *ptr,size_t size,swig_type_info *type)
 {
-  swig_lua_rawdataraw;
+  swig_lua_rawdata *raw;
   assert(ptr); /* not acceptable to pass in a NULL value */
   raw=(swig_lua_rawdata*)lua_newuserdata(L,sizeof(swig_lua_rawdata)-1+size);  /* alloc data */
   raw->type=type;
   raw->own=0;
   memcpy(raw->data,ptr,size); /* copy the data */
-  _SWIG_Lua_AddMetatable(L,type); /* add metatable */
+  SWIG_Lua_AddMetatable(L,type); /* add metatable */
 }
     
 /* converts a packed userdata. user for member fn pointers only */
-SWIGRUNTIME int  SWIG_Lua_ConvertPacked(lua_State* L,int index,void* ptr,size_t size,swig_type_info *type)
+SWIGRUNTIME int  SWIG_Lua_ConvertPacked(lua_State *L,int index,void *ptr,size_t size,swig_type_info *type)
 {
-  swig_lua_rawdataraw;
+  swig_lua_rawdata *raw;
   raw=(swig_lua_rawdata*)lua_touserdata(L,index);  /* get data */
   if (!raw) return SWIG_ERROR;  /* error */
   if (type==0 || type==raw->type) /* void* or identical type */
@@ -1742,7 +2520,7 @@ SWIGRUNTIME int  SWIG_Lua_ConvertPacked(lua_State* L,int index,void* ptr,size_t
 /* a function to get the typestring of a piece of data */
 SWIGRUNTIME const char *SWIG_Lua_typename(lua_State *L, int tp)
 {
-  swig_lua_userdatausr;
+  swig_lua_userdata *usr;
   if (lua_isuserdata(L,tp))
   {
     usr=(swig_lua_userdata*)lua_touserdata(L,tp);  /* get data */
@@ -1754,29 +2532,12 @@ SWIGRUNTIME const char *SWIG_Lua_typename(lua_State *L, int tp)
 }
 
 /* lua callable function to get the userdata's type */
-SWIGRUNTIME int SWIG_Lua_type(lua_StateL)
+SWIGRUNTIME int SWIG_Lua_type(lua_State *L)
 {
   lua_pushstring(L,SWIG_Lua_typename(L,1));
   return 1;
 }
 
-/* lua callable function to compare userdata's value
-the issue is that two userdata may point to the same thing
-but to lua, they are different objects */
-SWIGRUNTIME int SWIG_Lua_equal(lua_State* L)
-{
-  int result;
-  swig_lua_userdata *usr1,*usr2;
-  if (!lua_isuserdata(L,1) || !lua_isuserdata(L,2))  /* just in case */
-    return 0;  /* nil reply */
-  usr1=(swig_lua_userdata*)lua_touserdata(L,1);  /* get data */
-  usr2=(swig_lua_userdata*)lua_touserdata(L,2);  /* get data */
-  /*result=(usr1->ptr==usr2->ptr && usr1->type==usr2->type); only works if type is the same*/
-  result=(usr1->ptr==usr2->ptr);
-   lua_pushboolean(L,result);
-  return 1;
-}
-
 /* -----------------------------------------------------------------------------
  * global variable support code: class/struct typemap functions
  * ----------------------------------------------------------------------------- */
@@ -1784,7 +2545,7 @@ SWIGRUNTIME int SWIG_Lua_equal(lua_State* L)
 #if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC))
 /* Install Constants */
 SWIGINTERN void
-SWIG_Lua_InstallConstants(lua_StateL, swig_lua_const_info constants[]) {
+SWIG_Lua_InstallConstants(lua_State *L, swig_lua_const_info constants[]) {
   int i;
   for (i = 0; constants[i].type; i++) {
     switch(constants[i].type) {
@@ -1834,11 +2595,11 @@ SWIG_Lua_InstallConstants(lua_State* L, swig_lua_const_info constants[]) {
 #endif
 /* 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()
+In lua 5.0.X it's lua_dostring()
+In lua 5.1.X it's luaL_dostring()
 */
 SWIGINTERN int 
-SWIG_Lua_dostring(lua_State *L, const charstr) {
+SWIG_Lua_dostring(lua_State *L, const char *str) {
   int ok,top;
   if (str==0 || str[0]==0) return 0; /* nothing to do */
   top=lua_gettop(L); /* save stack */
@@ -2547,39 +3308,63 @@ static void swig_delete_ESLevent(void *obj) {
 ESLevent *arg1 = (ESLevent *) obj;
 delete arg1;
 }
-static swig_lua_method swig_ESLevent_methods[] = {
-    {"serialize", _wrap_ESLevent_serialize}, 
-    {"setPriority", _wrap_ESLevent_setPriority}, 
-    {"getHeader", _wrap_ESLevent_getHeader}, 
-    {"getBody", _wrap_ESLevent_getBody}, 
-    {"getType", _wrap_ESLevent_getType}, 
-    {"addBody", _wrap_ESLevent_addBody}, 
-    {"addHeader", _wrap_ESLevent_addHeader}, 
-    {"pushHeader", _wrap_ESLevent_pushHeader}, 
-    {"unshiftHeader", _wrap_ESLevent_unshiftHeader}, 
-    {"delHeader", _wrap_ESLevent_delHeader}, 
-    {"firstHeader", _wrap_ESLevent_firstHeader}, 
-    {"nextHeader", _wrap_ESLevent_nextHeader}, 
-    {0,0}
-};
+static int _proxy__wrap_new_ESLevent(lua_State *L) {
+    assert(lua_istable(L,1));
+    lua_pushcfunction(L,_wrap_new_ESLevent);
+    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;
+}
 static swig_lua_attribute swig_ESLevent_attributes[] = {
-    { "event", _wrap_ESLevent_event_get, _wrap_ESLevent_event_set},
-    { "serialized_string", _wrap_ESLevent_serialized_string_get, _wrap_ESLevent_serialized_string_set},
-    { "mine", _wrap_ESLevent_mine_get, _wrap_ESLevent_mine_set},
+    { "event", _wrap_ESLevent_event_get, _wrap_ESLevent_event_set },
+    { "serialized_string", _wrap_ESLevent_serialized_string_get, _wrap_ESLevent_serialized_string_set },
+    { "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_methods[]= {
+    { "serialize", _wrap_ESLevent_serialize},
+    { "setPriority", _wrap_ESLevent_setPriority},
+    { "getHeader", _wrap_ESLevent_getHeader},
+    { "getBody", _wrap_ESLevent_getBody},
+    { "getType", _wrap_ESLevent_getType},
+    { "addBody", _wrap_ESLevent_addBody},
+    { "addHeader", _wrap_ESLevent_addHeader},
+    { "pushHeader", _wrap_ESLevent_pushHeader},
+    { "unshiftHeader", _wrap_ESLevent_unshiftHeader},
+    { "delHeader", _wrap_ESLevent_delHeader},
+    { "firstHeader", _wrap_ESLevent_firstHeader},
+    { "nextHeader", _wrap_ESLevent_nextHeader},
+    {0,0}
 };
-static swig_lua_method swig_ESLevent_cls_methods[] = {
+static swig_lua_method swig_ESLevent_meta[] = {
     {0,0}
 };
-static swig_lua_const_info swig_ESLevent_cls_constants[] = {
+
+static swig_lua_attribute swig_ESLevent_Sf_SwigStatic_attributes[] = {
+    {0,0,0}
+};
+static swig_lua_const_info swig_ESLevent_Sf_SwigStatic_constants[]= {
     {0,0,0,0,0,0}
 };
+static swig_lua_method swig_ESLevent_Sf_SwigStatic_methods[]= {
+    {0,0}
+};
+static swig_lua_class* swig_ESLevent_Sf_SwigStatic_classes[]= {
+    0
+};
+
+static swig_lua_namespace swig_ESLevent_Sf_SwigStatic = {
+    "ESLevent",
+    swig_ESLevent_Sf_SwigStatic_methods,
+    swig_ESLevent_Sf_SwigStatic_attributes,
+    swig_ESLevent_Sf_SwigStatic_constants,
+    swig_ESLevent_Sf_SwigStatic_classes,
+    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, { "ESLevent", swig_ESLevent_cls_methods, swig_ESLevent_cls_attributes, swig_ESLevent_cls_constants }, swig_ESLevent_bases, swig_ESLevent_base_names };
+static swig_lua_class _wrap_class_ESLevent = { "ESLevent", "ESLevent", &SWIGTYPE_p_ESLevent,_proxy__wrap_new_ESLevent, swig_delete_ESLevent, swig_ESLevent_methods, swig_ESLevent_attributes, &swig_ESLevent_Sf_SwigStatic, swig_ESLevent_meta, swig_ESLevent_bases, swig_ESLevent_base_names };
 
 static int _wrap_new_ESLconnection__SWIG_0(lua_State* L) {
   int SWIG_arg = 0;
@@ -3354,42 +4139,66 @@ static void swig_delete_ESLconnection(void *obj) {
 ESLconnection *arg1 = (ESLconnection *) obj;
 delete arg1;
 }
-static swig_lua_method swig_ESLconnection_methods[] = {
-    {"socketDescriptor", _wrap_ESLconnection_socketDescriptor}, 
-    {"connected", _wrap_ESLconnection_connected}, 
-    {"getInfo", _wrap_ESLconnection_getInfo}, 
-    {"send", _wrap_ESLconnection_send}, 
-    {"sendRecv", _wrap_ESLconnection_sendRecv}, 
-    {"api", _wrap_ESLconnection_api}, 
-    {"bgapi", _wrap_ESLconnection_bgapi}, 
-    {"sendEvent", _wrap_ESLconnection_sendEvent}, 
-    {"sendMSG", _wrap_ESLconnection_sendMSG}, 
-    {"recvEvent", _wrap_ESLconnection_recvEvent}, 
-    {"recvEventTimed", _wrap_ESLconnection_recvEventTimed}, 
-    {"filter", _wrap_ESLconnection_filter}, 
-    {"events", _wrap_ESLconnection_events}, 
-    {"execute", _wrap_ESLconnection_execute}, 
-    {"executeAsync", _wrap_ESLconnection_executeAsync}, 
-    {"setAsyncExecute", _wrap_ESLconnection_setAsyncExecute}, 
-    {"setEventLock", _wrap_ESLconnection_setEventLock}, 
-    {"disconnect", _wrap_ESLconnection_disconnect}, 
-    {0,0}
-};
+static int _proxy__wrap_new_ESLconnection(lua_State *L) {
+    assert(lua_istable(L,1));
+    lua_pushcfunction(L,_wrap_new_ESLconnection);
+    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;
+}
 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_methods[]= {
+    { "socketDescriptor", _wrap_ESLconnection_socketDescriptor},
+    { "connected", _wrap_ESLconnection_connected},
+    { "getInfo", _wrap_ESLconnection_getInfo},
+    { "send", _wrap_ESLconnection_send},
+    { "sendRecv", _wrap_ESLconnection_sendRecv},
+    { "api", _wrap_ESLconnection_api},
+    { "bgapi", _wrap_ESLconnection_bgapi},
+    { "sendEvent", _wrap_ESLconnection_sendEvent},
+    { "sendMSG", _wrap_ESLconnection_sendMSG},
+    { "recvEvent", _wrap_ESLconnection_recvEvent},
+    { "recvEventTimed", _wrap_ESLconnection_recvEventTimed},
+    { "filter", _wrap_ESLconnection_filter},
+    { "events", _wrap_ESLconnection_events},
+    { "execute", _wrap_ESLconnection_execute},
+    { "executeAsync", _wrap_ESLconnection_executeAsync},
+    { "setAsyncExecute", _wrap_ESLconnection_setAsyncExecute},
+    { "setEventLock", _wrap_ESLconnection_setEventLock},
+    { "disconnect", _wrap_ESLconnection_disconnect},
+    {0,0}
 };
-static swig_lua_method swig_ESLconnection_cls_methods[] = {
+static swig_lua_method swig_ESLconnection_meta[] = {
     {0,0}
 };
-static swig_lua_const_info swig_ESLconnection_cls_constants[] = {
+
+static swig_lua_attribute swig_ESLconnection_Sf_SwigStatic_attributes[] = {
+    {0,0,0}
+};
+static swig_lua_const_info swig_ESLconnection_Sf_SwigStatic_constants[]= {
     {0,0,0,0,0,0}
 };
+static swig_lua_method swig_ESLconnection_Sf_SwigStatic_methods[]= {
+    {0,0}
+};
+static swig_lua_class* swig_ESLconnection_Sf_SwigStatic_classes[]= {
+    0
+};
+
+static swig_lua_namespace swig_ESLconnection_Sf_SwigStatic = {
+    "ESLconnection",
+    swig_ESLconnection_Sf_SwigStatic_methods,
+    swig_ESLconnection_Sf_SwigStatic_attributes,
+    swig_ESLconnection_Sf_SwigStatic_constants,
+    swig_ESLconnection_Sf_SwigStatic_classes,
+    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, { "ESLconnection", swig_ESLconnection_cls_methods, swig_ESLconnection_cls_attributes, swig_ESLconnection_cls_constants }, swig_ESLconnection_bases, swig_ESLconnection_base_names };
+static swig_lua_class _wrap_class_ESLconnection = { "ESLconnection", "ESLconnection", &SWIGTYPE_p_ESLconnection,_proxy__wrap_new_ESLconnection, swig_delete_ESLconnection, swig_ESLconnection_methods, swig_ESLconnection_attributes, &swig_ESLconnection_Sf_SwigStatic, swig_ESLconnection_meta, swig_ESLconnection_bases, swig_ESLconnection_base_names };
 
 static int _wrap_eslSetLogLevel(lua_State* L) {
   int SWIG_arg = 0;
@@ -3410,22 +4219,36 @@ fail:
 }
 
 
-#ifdef __cplusplus
-}
-#endif
-
-static const struct luaL_Reg swig_commands[] = {
+static swig_lua_attribute swig_SwigModule_attributes[] = {
+    {0,0,0}
+};
+static swig_lua_const_info swig_SwigModule_constants[]= {
+    {0,0,0,0,0,0}
+};
+static swig_lua_method swig_SwigModule_methods[]= {
     { "eslSetLogLevel", _wrap_eslSetLogLevel},
     {0,0}
 };
-
-static swig_lua_var_info swig_variables[] = {
-    {0,0,0}
+static swig_lua_class* swig_SwigModule_classes[]= {
+&_wrap_class_ESLevent,
+&_wrap_class_ESLconnection,
+    0
+};
+static swig_lua_namespace* swig_SwigModule_namespaces[] = {
+    0
 };
 
-static swig_lua_const_info swig_constants[] = {
-    {0,0,0,0,0,0}
+static swig_lua_namespace swig_SwigModule = {
+    "ESL",
+    swig_SwigModule_methods,
+    swig_SwigModule_attributes,
+    swig_SwigModule_constants,
+    swig_SwigModule_classes,
+    swig_SwigModule_namespaces
 };
+#ifdef __cplusplus
+}
+#endif
 
 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */
 
@@ -3469,7 +4292,7 @@ static swig_cast_info *swig_cast_initial[] = {
  * 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 statically 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
@@ -3711,27 +4534,18 @@ SWIGEXPORT int SWIG_init(lua_State* L) /* default Lua action */
 {
 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC) /* valid for both Lua and eLua */
   int i;
+  int globalRegister = 0;
   /* start with global table */
   lua_pushglobaltable (L);
-  /* SWIG's internal initalisation */
+  /* SWIG's internal initialisation */
   SWIG_InitializeModule((void*)L);
   SWIG_PropagateClientData();
 #endif
 
-#if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC))
+#if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)) || defined(SWIG_LUA_ELUA_EMULATE)
   /* add a global fn */
   SWIG_Lua_add_function(L,"swig_type",SWIG_Lua_type);
-  SWIG_Lua_add_function(L,"swig_equals",SWIG_Lua_equal);
-  /* begin the module (its a table with the same name as the module) */
-  SWIG_Lua_module_begin(L,SWIG_name);
-  /* add commands/functions */
-  for (i = 0; swig_commands[i].name; i++){
-    SWIG_Lua_module_add_function(L,swig_commands[i].name,swig_commands[i].func);
-  }
-  /* add variables */
-  for (i = 0; swig_variables[i].name; i++){
-    SWIG_Lua_module_add_variable(L,swig_variables[i].name,swig_variables[i].get,swig_variables[i].set);
-  }
+  SWIG_Lua_add_function(L,"swig_equals",SWIG_Lua_class_equal);
 #endif
 
 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)
@@ -3741,17 +4555,34 @@ SWIGEXPORT int SWIG_init(lua_State* L) /* default Lua action */
       SWIG_Lua_init_base_class(L,(swig_lua_class*)(swig_types[i]->clientdata));
     }
   }
-  /* additional registration structs & classes in lua */
+#ifdef SWIG_LUA_MODULE_GLOBAL
+  globalRegister = 1;
+#endif
+
+
+#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA)
+  SWIG_Lua_namespace_register(L,&swig_SwigModule, globalRegister);
+#endif
+
+#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUA) || (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_ELUAC)
   for (i = 0; swig_types[i]; i++){
     if (swig_types[i]->clientdata){
-      SWIG_Lua_class_register(L,(swig_lua_class*)(swig_types[i]->clientdata));
+      SWIG_Lua_elua_class_register_instance(L,(swig_lua_class*)(swig_types[i]->clientdata));
     }
   }
 #endif
 
-#if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC))
-  /* constants */
-  SWIG_Lua_InstallConstants(L,swig_constants);
+#if defined(SWIG_LUA_ELUA_EMULATE)
+  lua_newtable(L);
+  SWIG_Lua_elua_emulate_register(L,swig_SwigModule.ns_methods);
+  SWIG_Lua_elua_emulate_register_clear(L);
+  if(globalRegister) {
+    lua_pushstring(L,swig_SwigModule.name);
+    lua_pushvalue(L,-2);
+    lua_rawset(L,-4);
+  }
+#endif
+
 #endif
 
 #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)
index 55955ccf9c92bcfe842a7dcd6947f849b9c63260..870e86b840db4f4f0a3a673fee5f3339629a2e73 100644 (file)
@@ -1,15 +1,12 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
  * ----------------------------------------------------------------------------- */
 
 
-using System;
-using System.Runtime.InteropServices;
-
 public class ESL {
   public static void eslSetLogLevel(int level) {
     ESLPINVOKE.eslSetLogLevel(level);
index 8613a4a32231d16607b6bbc58016fca470b26191..b00dad06ec6bbd4f5e74032087e91e44fe4f317e 100644 (file)
@@ -1,15 +1,12 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
  * ----------------------------------------------------------------------------- */
 
 
-using System;
-using System.Runtime.InteropServices;
-
 class ESLPINVOKE {
 
   protected class SWIGExceptionHelper {
@@ -33,7 +30,7 @@ class ESLPINVOKE {
     static ExceptionArgumentDelegate argumentNullDelegate = new ExceptionArgumentDelegate(SetPendingArgumentNullException);
     static ExceptionArgumentDelegate argumentOutOfRangeDelegate = new ExceptionArgumentDelegate(SetPendingArgumentOutOfRangeException);
 
-    [DllImport("ESL", EntryPoint="SWIGRegisterExceptionCallbacks_ESL")]
+    [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="SWIGRegisterExceptionCallbacks_ESL")]
     public static extern void SWIGRegisterExceptionCallbacks_ESL(
                                 ExceptionDelegate applicationDelegate,
                                 ExceptionDelegate arithmeticDelegate,
@@ -47,58 +44,58 @@ class ESLPINVOKE {
                                 ExceptionDelegate overflowDelegate, 
                                 ExceptionDelegate systemExceptionDelegate);
 
-    [DllImport("ESL", EntryPoint="SWIGRegisterExceptionArgumentCallbacks_ESL")]
+    [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="SWIGRegisterExceptionArgumentCallbacks_ESL")]
     public static extern void SWIGRegisterExceptionCallbacksArgument_ESL(
                                 ExceptionArgumentDelegate argumentDelegate,
                                 ExceptionArgumentDelegate argumentNullDelegate,
                                 ExceptionArgumentDelegate argumentOutOfRangeDelegate);
 
     static void SetPendingApplicationException(string message) {
-      SWIGPendingException.Set(new System.ApplicationException(message, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.ApplicationException(message, SWIGPendingException.Retrieve()));
     }
     static void SetPendingArithmeticException(string message) {
-      SWIGPendingException.Set(new System.ArithmeticException(message, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.ArithmeticException(message, SWIGPendingException.Retrieve()));
     }
     static void SetPendingDivideByZeroException(string message) {
-      SWIGPendingException.Set(new System.DivideByZeroException(message, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.DivideByZeroException(message, SWIGPendingException.Retrieve()));
     }
     static void SetPendingIndexOutOfRangeException(string message) {
-      SWIGPendingException.Set(new System.IndexOutOfRangeException(message, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.IndexOutOfRangeException(message, SWIGPendingException.Retrieve()));
     }
     static void SetPendingInvalidCastException(string message) {
-      SWIGPendingException.Set(new System.InvalidCastException(message, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.InvalidCastException(message, SWIGPendingException.Retrieve()));
     }
     static void SetPendingInvalidOperationException(string message) {
-      SWIGPendingException.Set(new System.InvalidOperationException(message, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.InvalidOperationException(message, SWIGPendingException.Retrieve()));
     }
     static void SetPendingIOException(string message) {
-      SWIGPendingException.Set(new System.IO.IOException(message, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.IO.IOException(message, SWIGPendingException.Retrieve()));
     }
     static void SetPendingNullReferenceException(string message) {
-      SWIGPendingException.Set(new System.NullReferenceException(message, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.NullReferenceException(message, SWIGPendingException.Retrieve()));
     }
     static void SetPendingOutOfMemoryException(string message) {
-      SWIGPendingException.Set(new System.OutOfMemoryException(message, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.OutOfMemoryException(message, SWIGPendingException.Retrieve()));
     }
     static void SetPendingOverflowException(string message) {
-      SWIGPendingException.Set(new System.OverflowException(message, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.OverflowException(message, SWIGPendingException.Retrieve()));
     }
     static void SetPendingSystemException(string message) {
-      SWIGPendingException.Set(new System.SystemException(message, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.SystemException(message, SWIGPendingException.Retrieve()));
     }
 
     static void SetPendingArgumentException(string message, string paramName) {
-      SWIGPendingException.Set(new System.ArgumentException(message, paramName, SWIGPendingException.Retrieve()));
+      SWIGPendingException.Set(new global::System.ArgumentException(message, paramName, SWIGPendingException.Retrieve()));
     }
     static void SetPendingArgumentNullException(string message, string paramName) {
-      Exception e = SWIGPendingException.Retrieve();
+      global::System.Exception e = SWIGPendingException.Retrieve();
       if (e != null) message = message + " Inner Exception: " + e.Message;
-      SWIGPendingException.Set(new System.ArgumentNullException(paramName, message));
+      SWIGPendingException.Set(new global::System.ArgumentNullException(paramName, message));
     }
     static void SetPendingArgumentOutOfRangeException(string message, string paramName) {
-      Exception e = SWIGPendingException.Retrieve();
+      global::System.Exception e = SWIGPendingException.Retrieve();
       if (e != null) message = message + " Inner Exception: " + e.Message;
-      SWIGPendingException.Set(new System.ArgumentOutOfRangeException(paramName, message));
+      SWIGPendingException.Set(new global::System.ArgumentOutOfRangeException(paramName, message));
     }
 
     static SWIGExceptionHelper() {
@@ -125,8 +122,8 @@ class ESLPINVOKE {
   protected static SWIGExceptionHelper swigExceptionHelper = new SWIGExceptionHelper();
 
   public class SWIGPendingException {
-    [ThreadStatic]
-    private static Exception pendingException = null;
+    [global::System.ThreadStatic]
+    private static global::System.Exception pendingException = null;
     private static int numExceptionsPending = 0;
 
     public static bool Pending {
@@ -139,17 +136,17 @@ class ESLPINVOKE {
       } 
     }
 
-    public static void Set(Exception e) {
+    public static void Set(global::System.Exception e) {
       if (pendingException != null)
-        throw new ApplicationException("FATAL: An earlier pending exception from unmanaged code was missed and thus not thrown (" + pendingException.ToString() + ")", e);
+        throw new global::System.ApplicationException("FATAL: An earlier pending exception from unmanaged code was missed and thus not thrown (" + pendingException.ToString() + ")", e);
       pendingException = e;
       lock(typeof(ESLPINVOKE)) {
         numExceptionsPending++;
       }
     }
 
-    public static Exception Retrieve() {
-      Exception e = null;
+    public static global::System.Exception Retrieve() {
+      global::System.Exception e = null;
       if (numExceptionsPending > 0) {
         if (pendingException != null) {
           e = pendingException;
@@ -169,7 +166,7 @@ class ESLPINVOKE {
     public delegate string SWIGStringDelegate(string message);
     static SWIGStringDelegate stringDelegate = new SWIGStringDelegate(CreateString);
 
-    [DllImport("ESL", EntryPoint="SWIGRegisterStringCallback_ESL")]
+    [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="SWIGRegisterStringCallback_ESL")]
     public static extern void SWIGRegisterStringCallback_ESL(SWIGStringDelegate stringDelegate);
 
     static string CreateString(string cString) {
@@ -188,144 +185,144 @@ class ESLPINVOKE {
   }
 
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_Event_set")]
-  public static extern void ESLevent_Event_set(HandleRef jarg1, HandleRef jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_Event_set")]
+  public static extern void ESLevent_Event_set(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_Event_get")]
-  public static extern IntPtr ESLevent_Event_get(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_Event_get")]
+  public static extern global::System.IntPtr ESLevent_Event_get(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_SerializedString_set")]
-  public static extern void ESLevent_SerializedString_set(HandleRef jarg1, string jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_SerializedString_set")]
+  public static extern void ESLevent_SerializedString_set(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_SerializedString_get")]
-  public static extern string ESLevent_SerializedString_get(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_SerializedString_get")]
+  public static extern string ESLevent_SerializedString_get(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_Mine_set")]
-  public static extern void ESLevent_Mine_set(HandleRef jarg1, int jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_Mine_set")]
+  public static extern void ESLevent_Mine_set(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_Mine_get")]
-  public static extern int ESLevent_Mine_get(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_Mine_get")]
+  public static extern int ESLevent_Mine_get(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_new_ESLevent__SWIG_0")]
-  public static extern IntPtr new_ESLevent__SWIG_0(string jarg1, string jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_new_ESLevent__SWIG_0")]
+  public static extern global::System.IntPtr new_ESLevent__SWIG_0(string jarg1, string jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_new_ESLevent__SWIG_1")]
-  public static extern IntPtr new_ESLevent__SWIG_1(HandleRef jarg1, int jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_new_ESLevent__SWIG_1")]
+  public static extern global::System.IntPtr new_ESLevent__SWIG_1(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_new_ESLevent__SWIG_2")]
-  public static extern IntPtr new_ESLevent__SWIG_2(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_new_ESLevent__SWIG_2")]
+  public static extern global::System.IntPtr new_ESLevent__SWIG_2(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_delete_ESLevent")]
-  public static extern void delete_ESLevent(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_delete_ESLevent")]
+  public static extern void delete_ESLevent(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_Serialize")]
-  public static extern string ESLevent_Serialize(HandleRef jarg1, string jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_Serialize")]
+  public static extern string ESLevent_Serialize(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_SetPriority")]
-  public static extern bool ESLevent_SetPriority(HandleRef jarg1, HandleRef jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_SetPriority")]
+  public static extern bool ESLevent_SetPriority(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_GetHeader")]
-  public static extern string ESLevent_GetHeader(HandleRef jarg1, string jarg2, int jarg3);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_GetHeader")]
+  public static extern string ESLevent_GetHeader(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2, int jarg3);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_GetBody")]
-  public static extern string ESLevent_GetBody(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_GetBody")]
+  public static extern string ESLevent_GetBody(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_getType")]
-  public static extern string ESLevent_getType(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_getType")]
+  public static extern string ESLevent_getType(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_AddBody")]
-  public static extern bool ESLevent_AddBody(HandleRef jarg1, string jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_AddBody")]
+  public static extern bool ESLevent_AddBody(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_AddHeader")]
-  public static extern bool ESLevent_AddHeader(HandleRef jarg1, string jarg2, string jarg3);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_AddHeader")]
+  public static extern bool ESLevent_AddHeader(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2, string jarg3);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_pushHeader")]
-  public static extern bool ESLevent_pushHeader(HandleRef jarg1, string jarg2, string jarg3);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_pushHeader")]
+  public static extern bool ESLevent_pushHeader(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2, string jarg3);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_unshiftHeader")]
-  public static extern bool ESLevent_unshiftHeader(HandleRef jarg1, string jarg2, string jarg3);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_unshiftHeader")]
+  public static extern bool ESLevent_unshiftHeader(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2, string jarg3);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_DelHeader")]
-  public static extern bool ESLevent_DelHeader(HandleRef jarg1, string jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_DelHeader")]
+  public static extern bool ESLevent_DelHeader(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_FirstHeader")]
-  public static extern string ESLevent_FirstHeader(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_FirstHeader")]
+  public static extern string ESLevent_FirstHeader(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLevent_NextHeader")]
-  public static extern string ESLevent_NextHeader(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLevent_NextHeader")]
+  public static extern string ESLevent_NextHeader(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_new_ESLconnection__SWIG_0")]
-  public static extern IntPtr new_ESLconnection__SWIG_0(string jarg1, int jarg2, string jarg3, string jarg4);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_new_ESLconnection__SWIG_0")]
+  public static extern global::System.IntPtr new_ESLconnection__SWIG_0(string jarg1, int jarg2, string jarg3, string jarg4);
 
-  [DllImport("ESL", EntryPoint="CSharp_new_ESLconnection__SWIG_1")]
-  public static extern IntPtr new_ESLconnection__SWIG_1(string jarg1, int jarg2, string jarg3);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_new_ESLconnection__SWIG_1")]
+  public static extern global::System.IntPtr new_ESLconnection__SWIG_1(string jarg1, int jarg2, string jarg3);
 
-  [DllImport("ESL", EntryPoint="CSharp_new_ESLconnection__SWIG_2")]
-  public static extern IntPtr new_ESLconnection__SWIG_2(string jarg1, string jarg2, string jarg3, string jarg4);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_new_ESLconnection__SWIG_2")]
+  public static extern global::System.IntPtr new_ESLconnection__SWIG_2(string jarg1, string jarg2, string jarg3, string jarg4);
 
-  [DllImport("ESL", EntryPoint="CSharp_new_ESLconnection__SWIG_3")]
-  public static extern IntPtr new_ESLconnection__SWIG_3(string jarg1, string jarg2, string jarg3);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_new_ESLconnection__SWIG_3")]
+  public static extern global::System.IntPtr new_ESLconnection__SWIG_3(string jarg1, string jarg2, string jarg3);
 
-  [DllImport("ESL", EntryPoint="CSharp_new_ESLconnection__SWIG_4")]
-  public static extern IntPtr new_ESLconnection__SWIG_4(int jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_new_ESLconnection__SWIG_4")]
+  public static extern global::System.IntPtr new_ESLconnection__SWIG_4(int jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_delete_ESLconnection")]
-  public static extern void delete_ESLconnection(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_delete_ESLconnection")]
+  public static extern void delete_ESLconnection(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_SocketDescriptor")]
-  public static extern int ESLconnection_SocketDescriptor(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_SocketDescriptor")]
+  public static extern int ESLconnection_SocketDescriptor(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_Connected")]
-  public static extern int ESLconnection_Connected(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_Connected")]
+  public static extern int ESLconnection_Connected(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_GetInfo")]
-  public static extern IntPtr ESLconnection_GetInfo(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_GetInfo")]
+  public static extern global::System.IntPtr ESLconnection_GetInfo(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_Send")]
-  public static extern int ESLconnection_Send(HandleRef jarg1, string jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_Send")]
+  public static extern int ESLconnection_Send(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_SendRecv")]
-  public static extern IntPtr ESLconnection_SendRecv(HandleRef jarg1, string jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_SendRecv")]
+  public static extern global::System.IntPtr ESLconnection_SendRecv(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_Api")]
-  public static extern IntPtr ESLconnection_Api(HandleRef jarg1, string jarg2, string jarg3);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_Api")]
+  public static extern global::System.IntPtr ESLconnection_Api(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2, string jarg3);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_Bgapi")]
-  public static extern IntPtr ESLconnection_Bgapi(HandleRef jarg1, string jarg2, string jarg3, string jarg4);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_Bgapi")]
+  public static extern global::System.IntPtr ESLconnection_Bgapi(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2, string jarg3, string jarg4);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_SendEvent")]
-  public static extern IntPtr ESLconnection_SendEvent(HandleRef jarg1, HandleRef jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_SendEvent")]
+  public static extern global::System.IntPtr ESLconnection_SendEvent(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_sendMSG")]
-  public static extern int ESLconnection_sendMSG(HandleRef jarg1, HandleRef jarg2, string jarg3);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_sendMSG")]
+  public static extern int ESLconnection_sendMSG(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2, string jarg3);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_RecvEvent")]
-  public static extern IntPtr ESLconnection_RecvEvent(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_RecvEvent")]
+  public static extern global::System.IntPtr ESLconnection_RecvEvent(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_RecvEventTimed")]
-  public static extern IntPtr ESLconnection_RecvEventTimed(HandleRef jarg1, int jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_RecvEventTimed")]
+  public static extern global::System.IntPtr ESLconnection_RecvEventTimed(global::System.Runtime.InteropServices.HandleRef jarg1, int jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_Filter")]
-  public static extern IntPtr ESLconnection_Filter(HandleRef jarg1, string jarg2, string jarg3);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_Filter")]
+  public static extern global::System.IntPtr ESLconnection_Filter(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2, string jarg3);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_Events")]
-  public static extern int ESLconnection_Events(HandleRef jarg1, string jarg2, string jarg3);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_Events")]
+  public static extern int ESLconnection_Events(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2, string jarg3);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_Execute")]
-  public static extern IntPtr ESLconnection_Execute(HandleRef jarg1, string jarg2, string jarg3, string jarg4);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_Execute")]
+  public static extern global::System.IntPtr ESLconnection_Execute(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2, string jarg3, string jarg4);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_ExecuteAsync")]
-  public static extern IntPtr ESLconnection_ExecuteAsync(HandleRef jarg1, string jarg2, string jarg3, string jarg4);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_ExecuteAsync")]
+  public static extern global::System.IntPtr ESLconnection_ExecuteAsync(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2, string jarg3, string jarg4);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_SetAsyncExecute")]
-  public static extern int ESLconnection_SetAsyncExecute(HandleRef jarg1, string jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_SetAsyncExecute")]
+  public static extern int ESLconnection_SetAsyncExecute(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_SetEventLock")]
-  public static extern int ESLconnection_SetEventLock(HandleRef jarg1, string jarg2);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_SetEventLock")]
+  public static extern int ESLconnection_SetEventLock(global::System.Runtime.InteropServices.HandleRef jarg1, string jarg2);
 
-  [DllImport("ESL", EntryPoint="CSharp_ESLconnection_Disconnect")]
-  public static extern int ESLconnection_Disconnect(HandleRef jarg1);
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_ESLconnection_Disconnect")]
+  public static extern int ESLconnection_Disconnect(global::System.Runtime.InteropServices.HandleRef jarg1);
 
-  [DllImport("ESL", EntryPoint="CSharp_eslSetLogLevel")]
+  [global::System.Runtime.InteropServices.DllImport("ESL", EntryPoint="CSharp_eslSetLogLevel")]
   public static extern void eslSetLogLevel(int jarg1);
 }
index c199528f6c1558bb3c6234b73cc304782a1e17e7..e1c43d6b32cf7097003707bf6ab7aa503e0b6312 100644 (file)
@@ -1,26 +1,23 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
  * ----------------------------------------------------------------------------- */
 
 
-using System;
-using System.Runtime.InteropServices;
-
-public class ESLconnection : IDisposable {
-  private HandleRef swigCPtr;
+public class ESLconnection : global::System.IDisposable {
+  private global::System.Runtime.InteropServices.HandleRef swigCPtr;
   protected bool swigCMemOwn;
 
-  internal ESLconnection(IntPtr cPtr, bool cMemoryOwn) {
+  internal ESLconnection(global::System.IntPtr cPtr, bool cMemoryOwn) {
     swigCMemOwn = cMemoryOwn;
-    swigCPtr = new HandleRef(this, cPtr);
+    swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
   }
 
-  internal static HandleRef getCPtr(ESLconnection obj) {
-    return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
+  internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ESLconnection obj) {
+    return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
   }
 
   ~ESLconnection() {
@@ -29,14 +26,14 @@ public class ESLconnection : IDisposable {
 
   public virtual void Dispose() {
     lock(this) {
-      if (swigCPtr.Handle != IntPtr.Zero) {
+      if (swigCPtr.Handle != global::System.IntPtr.Zero) {
         if (swigCMemOwn) {
           swigCMemOwn = false;
           ESLPINVOKE.delete_ESLconnection(swigCPtr);
         }
-        swigCPtr = new HandleRef(null, IntPtr.Zero);
+        swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
       }
-      GC.SuppressFinalize(this);
+      global::System.GC.SuppressFinalize(this);
     }
   }
 
@@ -66,8 +63,8 @@ public class ESLconnection : IDisposable {
   }
 
   public ESLevent GetInfo() {
-    IntPtr cPtr = ESLPINVOKE.ESLconnection_GetInfo(swigCPtr);
-    ESLevent ret = (cPtr == IntPtr.Zero) ? null : new ESLevent(cPtr, true);
+    global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_GetInfo(swigCPtr);
+    ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
     return ret;
   }
 
@@ -77,26 +74,26 @@ public class ESLconnection : IDisposable {
   }
 
   public ESLevent SendRecv(string cmd) {
-    IntPtr cPtr = ESLPINVOKE.ESLconnection_SendRecv(swigCPtr, cmd);
-    ESLevent ret = (cPtr == IntPtr.Zero) ? null : new ESLevent(cPtr, true);
+    global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_SendRecv(swigCPtr, cmd);
+    ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
     return ret;
   }
 
   public ESLevent Api(string cmd, string arg) {
-    IntPtr cPtr = ESLPINVOKE.ESLconnection_Api(swigCPtr, cmd, arg);
-    ESLevent ret = (cPtr == IntPtr.Zero) ? null : new ESLevent(cPtr, true);
+    global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_Api(swigCPtr, cmd, arg);
+    ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
     return ret;
   }
 
   public ESLevent Bgapi(string cmd, string arg, string job_uuid) {
-    IntPtr cPtr = ESLPINVOKE.ESLconnection_Bgapi(swigCPtr, cmd, arg, job_uuid);
-    ESLevent ret = (cPtr == IntPtr.Zero) ? null : new ESLevent(cPtr, true);
+    global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_Bgapi(swigCPtr, cmd, arg, job_uuid);
+    ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
     return ret;
   }
 
   public ESLevent SendEvent(ESLevent send_me) {
-    IntPtr cPtr = ESLPINVOKE.ESLconnection_SendEvent(swigCPtr, ESLevent.getCPtr(send_me));
-    ESLevent ret = (cPtr == IntPtr.Zero) ? null : new ESLevent(cPtr, true);
+    global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_SendEvent(swigCPtr, ESLevent.getCPtr(send_me));
+    ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
     return ret;
   }
 
@@ -106,20 +103,20 @@ public class ESLconnection : IDisposable {
   }
 
   public ESLevent RecvEvent() {
-    IntPtr cPtr = ESLPINVOKE.ESLconnection_RecvEvent(swigCPtr);
-    ESLevent ret = (cPtr == IntPtr.Zero) ? null : new ESLevent(cPtr, true);
+    global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_RecvEvent(swigCPtr);
+    ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
     return ret;
   }
 
   public ESLevent RecvEventTimed(int ms) {
-    IntPtr cPtr = ESLPINVOKE.ESLconnection_RecvEventTimed(swigCPtr, ms);
-    ESLevent ret = (cPtr == IntPtr.Zero) ? null : new ESLevent(cPtr, true);
+    global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_RecvEventTimed(swigCPtr, ms);
+    ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
     return ret;
   }
 
   public ESLevent Filter(string header, string value) {
-    IntPtr cPtr = ESLPINVOKE.ESLconnection_Filter(swigCPtr, header, value);
-    ESLevent ret = (cPtr == IntPtr.Zero) ? null : new ESLevent(cPtr, true);
+    global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_Filter(swigCPtr, header, value);
+    ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
     return ret;
   }
 
@@ -129,14 +126,14 @@ public class ESLconnection : IDisposable {
   }
 
   public ESLevent Execute(string app, string arg, string uuid) {
-    IntPtr cPtr = ESLPINVOKE.ESLconnection_Execute(swigCPtr, app, arg, uuid);
-    ESLevent ret = (cPtr == IntPtr.Zero) ? null : new ESLevent(cPtr, true);
+    global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_Execute(swigCPtr, app, arg, uuid);
+    ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
     return ret;
   }
 
   public ESLevent ExecuteAsync(string app, string arg, string uuid) {
-    IntPtr cPtr = ESLPINVOKE.ESLconnection_ExecuteAsync(swigCPtr, app, arg, uuid);
-    ESLevent ret = (cPtr == IntPtr.Zero) ? null : new ESLevent(cPtr, true);
+    global::System.IntPtr cPtr = ESLPINVOKE.ESLconnection_ExecuteAsync(swigCPtr, app, arg, uuid);
+    ESLevent ret = (cPtr == global::System.IntPtr.Zero) ? null : new ESLevent(cPtr, true);
     return ret;
   }
 
index f7f464f8dc6392a1d2720948daf67ab8f7136320..2fcb062c856054dec55e269c7d4d8e9e84b3f660 100644 (file)
@@ -1,26 +1,23 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
  * ----------------------------------------------------------------------------- */
 
 
-using System;
-using System.Runtime.InteropServices;
-
-public class ESLevent : IDisposable {
-  private HandleRef swigCPtr;
+public class ESLevent : global::System.IDisposable {
+  private global::System.Runtime.InteropServices.HandleRef swigCPtr;
   protected bool swigCMemOwn;
 
-  internal ESLevent(IntPtr cPtr, bool cMemoryOwn) {
+  internal ESLevent(global::System.IntPtr cPtr, bool cMemoryOwn) {
     swigCMemOwn = cMemoryOwn;
-    swigCPtr = new HandleRef(this, cPtr);
+    swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
   }
 
-  internal static HandleRef getCPtr(ESLevent obj) {
-    return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
+  internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ESLevent obj) {
+    return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
   }
 
   ~ESLevent() {
@@ -29,14 +26,14 @@ public class ESLevent : IDisposable {
 
   public virtual void Dispose() {
     lock(this) {
-      if (swigCPtr.Handle != IntPtr.Zero) {
+      if (swigCPtr.Handle != global::System.IntPtr.Zero) {
         if (swigCMemOwn) {
           swigCMemOwn = false;
           ESLPINVOKE.delete_ESLevent(swigCPtr);
         }
-        swigCPtr = new HandleRef(null, IntPtr.Zero);
+        swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
       }
-      GC.SuppressFinalize(this);
+      global::System.GC.SuppressFinalize(this);
     }
   }
 
@@ -45,8 +42,8 @@ public class ESLevent : IDisposable {
       ESLPINVOKE.ESLevent_Event_set(swigCPtr, SWIGTYPE_p_esl_event_t.getCPtr(value));
     } 
     get {
-      IntPtr cPtr = ESLPINVOKE.ESLevent_Event_get(swigCPtr);
-      SWIGTYPE_p_esl_event_t ret = (cPtr == IntPtr.Zero) ? null : new SWIGTYPE_p_esl_event_t(cPtr, false);
+      global::System.IntPtr cPtr = ESLPINVOKE.ESLevent_Event_get(swigCPtr);
+      SWIGTYPE_p_esl_event_t ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_esl_event_t(cPtr, false);
       return ret;
     } 
   }
index 0b2e0d28fc341d5687f6e911f20232ddd9772e33..fb8c36ba6764eef5ebc456d09c416b3d2316bb0d 100644 (file)
@@ -5,7 +5,7 @@ WRAP_GCC_WARNING_SILENCE=-Wno-unused-function
 all: ESL.so
 
 esl_wrap.cpp:
-       swig2.0 -module ESL -csharp -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
+       swig3.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
index 137b989bcffbf54e94968f9b3226ad9cea915e0a..9e257c5e8cac68101f1b5734cd8c674525069576 100644 (file)
@@ -1,27 +1,24 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
  * ----------------------------------------------------------------------------- */
 
 
-using System;
-using System.Runtime.InteropServices;
-
 public class SWIGTYPE_p_esl_event_t {
-  private HandleRef swigCPtr;
+  private global::System.Runtime.InteropServices.HandleRef swigCPtr;
 
-  internal SWIGTYPE_p_esl_event_t(IntPtr cPtr, bool futureUse) {
-    swigCPtr = new HandleRef(this, cPtr);
+  internal SWIGTYPE_p_esl_event_t(global::System.IntPtr cPtr, bool futureUse) {
+    swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
   }
 
   protected SWIGTYPE_p_esl_event_t() {
-    swigCPtr = new HandleRef(null, IntPtr.Zero);
+    swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
   }
 
-  internal static HandleRef getCPtr(SWIGTYPE_p_esl_event_t obj) {
-    return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
+  internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SWIGTYPE_p_esl_event_t obj) {
+    return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
   }
 }
index 9adb170e804351577d2300a4105149ac5fc0b8c0..0ed478d2e244b2e051f5204b4a0c11a970b088ff 100644 (file)
@@ -1,27 +1,24 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * Do not make changes to this file unless you know what you are doing--modify
  * the SWIG interface file instead.
  * ----------------------------------------------------------------------------- */
 
 
-using System;
-using System.Runtime.InteropServices;
-
 public class SWIGTYPE_p_esl_priority_t {
-  private HandleRef swigCPtr;
+  private global::System.Runtime.InteropServices.HandleRef swigCPtr;
 
-  internal SWIGTYPE_p_esl_priority_t(IntPtr cPtr, bool futureUse) {
-    swigCPtr = new HandleRef(this, cPtr);
+  internal SWIGTYPE_p_esl_priority_t(global::System.IntPtr cPtr, bool futureUse) {
+    swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
   }
 
   protected SWIGTYPE_p_esl_priority_t() {
-    swigCPtr = new HandleRef(null, IntPtr.Zero);
+    swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
   }
 
-  internal static HandleRef getCPtr(SWIGTYPE_p_esl_priority_t obj) {
-    return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr;
+  internal static global::System.Runtime.InteropServices.HandleRef getCPtr(SWIGTYPE_p_esl_priority_t obj) {
+    return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
   }
 }
index 8ca19a8de3b9b2971acdcc3a065bd37ac1862a01..9c36dd75c44b951d30ce776ae4a8a8e6fdf2ee54 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * 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
index c114f98a37eec54faf69cbfc0dc9006c75728221..39a8fd9558cba58f91107233754b7c8bb19fbd6d 100644 (file)
@@ -1,5 +1,5 @@
 # This file was automatically generated by SWIG (http://www.swig.org).
-# Version 2.0.12
+# Version 3.0.2
 #
 # Do not make changes to this file unless you know what you are doing--modify
 # the SWIG interface file instead.
index 3af0e6df0acf34e2a7f7980dc36b97c220b436ee..7caf8ad271858b187ce054e0ee1c4a0399310355 100644 (file)
@@ -21,7 +21,7 @@ endif
        $(MAKE) -C ..
 
 esl_wrap.cpp:
-       swig2.0 -module ESL -shadow -perl5 -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
+       swig3.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
index e10b0682bce2cc6db386484f452361b161830592..1d9485572c281d46f2e8bea82733aea53615f38f 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * 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
@@ -550,14 +550,14 @@ SWIG_MangledTypeQueryModule(swig_module_info *start,
   swig_module_info *iter = start;
   do {
     if (iter->size) {
-      register size_t l = 0;
-      register size_t r = iter->size - 1;
+      size_t l = 0;
+      size_t r = iter->size - 1;
       do {
        /* since l+r >= 0, we can (>> 1) instead (/ 2) */
-       register size_t i = (l + r) >> 1;
+       size_t i = (l + r) >> 1;
        const char *iname = iter->types[i]->name;
        if (iname) {
-         register int compare = strcmp(name, iname);
+         int compare = strcmp(name, iname);
          if (compare == 0) {
            return iter->types[i];
          } else if (compare < 0) {
@@ -601,7 +601,7 @@ SWIG_TypeQueryModule(swig_module_info *start,
        of the str field (the human readable name) */
     swig_module_info *iter = start;
     do {
-      register size_t i = 0;
+      size_t i = 0;
       for (; i < iter->size; ++i) {
        if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
          return iter->types[i];
@@ -620,10 +620,10 @@ SWIG_TypeQueryModule(swig_module_info *start,
 SWIGRUNTIME char *
 SWIG_PackData(char *c, void *ptr, size_t sz) {
   static const char hex[17] = "0123456789abcdef";
-  register const unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu =  u + sz;
+  const unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu =  u + sz;
   for (; u != eu; ++u) {
-    register unsigned char uu = *u;
+    unsigned char uu = *u;
     *(c++) = hex[(uu & 0xf0) >> 4];
     *(c++) = hex[uu & 0xf];
   }
@@ -635,11 +635,11 @@ SWIG_PackData(char *c, void *ptr, size_t sz) {
 */
 SWIGRUNTIME const char *
 SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
-  register unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu = u + sz;
+  unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu = u + sz;
   for (; u != eu; ++u) {
-    register char d = *(c++);
-    register unsigned char uu;
+    char d = *(c++);
+    unsigned char uu;
     if ((d >= '0') && (d <= '9'))
       uu = ((d - '0') << 4);
     else if ((d >= 'a') && (d <= 'f'))
@@ -894,6 +894,7 @@ SWIG_Perl_ErrorType(int code) {
 #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)
+#define swig_owntype                                    int
 
 /* for raw packed data */
 #define SWIG_ConvertPacked(obj, p, s, type)             SWIG_Perl_ConvertPacked(SWIG_PERL_OBJECT_CALL obj, p, s, type)
@@ -1162,7 +1163,11 @@ SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_
     /* Now see if the types match */
     char *_c = HvNAME(SvSTASH(SvRV(sv)));
     tc = SWIG_TypeProxyCheck(_c,_t);
+#ifdef SWIG_DIRECTORS
+    if (!tc && !sv_derived_from(sv,SWIG_Perl_TypeProxyName(_t))) {
+#else
     if (!tc) {
+#endif
       return SWIG_ERROR;
     }
     {
@@ -1520,7 +1525,7 @@ static swig_module_info swig_module = {swig_types, 5, 0, 0, 0, 0};
 #define SWIG_name   "ESLc::boot_ESL"
 #define SWIG_prefix "ESLc::"
 
-#define SWIGVERSION 0x02001
+#define SWIGVERSION 0x03000
 #define SWIG_VERSION SWIGVERSION
 
 
@@ -4129,7 +4134,7 @@ static swig_command_info swig_commands[] = {
  * 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 statically 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
index 3a4258a1ab4d56c3e3ad678a602b060090e6f291..4ac5499c320bf544df4057d922de3169b88648e0 100644 (file)
@@ -2,7 +2,7 @@
 
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * 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
@@ -44,12 +44,6 @@ class ESLevent {
                $this->_pData[$var] = $value;
        }
 
-       function __isset($var) {
-               if (function_exists('ESLevent_'.$var.'_set')) return true;
-               if ($var === 'thisown') return true;
-               return array_key_exists($var, $this->_pData);
-       }
-
        function __get($var) {
                $func = 'ESLevent_'.$var.'_get';
                if (function_exists($func)) return call_user_func($func,$this->_cPtr);
@@ -57,6 +51,12 @@ class ESLevent {
                return $this->_pData[$var];
        }
 
+       function __isset($var) {
+               if (function_exists('ESLevent_'.$var.'_get')) return true;
+               if ($var === 'thisown') return true;
+               return array_key_exists($var, $this->_pData);
+       }
+
        function __construct($type_or_wrap_me_or_me,$subclass_name_or_free_me=null) {
                if (is_resource($type_or_wrap_me_or_me) && get_resource_type($type_or_wrap_me_or_me) === '_p_ESLevent') {
                        $this->_cPtr=$type_or_wrap_me_or_me;
@@ -134,16 +134,16 @@ class ESLconnection {
                $this->_pData[$var] = $value;
        }
 
-       function __isset($var) {
-               if ($var === 'thisown') return true;
-               return array_key_exists($var, $this->_pData);
-       }
-
        function __get($var) {
                if ($var === 'thisown') return swig_ESL_get_newobject($this->_cPtr);
                return $this->_pData[$var];
        }
 
+       function __isset($var) {
+               if ($var === 'thisown') return true;
+               return array_key_exists($var, $this->_pData);
+       }
+
        function __construct($host_or_socket,$port=null,$user_or_password=null,$password=null) {
                if (is_resource($host_or_socket) && get_resource_type($host_or_socket) === '_p_ESLconnection') {
                        $this->_cPtr=$host_or_socket;
index d2c04c55c0f6dacf07b226d2d2ef72cf3891f716..bdcd2725804aeb3adc5b9114cbf5981513ff48f0 100644 (file)
@@ -3,7 +3,7 @@ WRAP_GCC_WARNING_SILENCE=-Wno-unused-label -Wno-unused-function
 all: ESL.so
 
 esl_wrap.cpp:
-       swig2.0 -module ESL -php5 -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
+       swig3.0 -module ESL -php5 -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
        sed -e 's/  char \*type_name;/  const char \*type_name;/' -i esl_wrap.cpp
 
 esl_wrap.o: esl_wrap.cpp
index e78b05ca9eeb8a29617aa610aa7f0fbfb731be06..75566f95320b8012fc119e88d1b0b3612be2ab36 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * 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
@@ -551,14 +551,14 @@ SWIG_MangledTypeQueryModule(swig_module_info *start,
   swig_module_info *iter = start;
   do {
     if (iter->size) {
-      register size_t l = 0;
-      register size_t r = iter->size - 1;
+      size_t l = 0;
+      size_t r = iter->size - 1;
       do {
        /* since l+r >= 0, we can (>> 1) instead (/ 2) */
-       register size_t i = (l + r) >> 1;
+       size_t i = (l + r) >> 1;
        const char *iname = iter->types[i]->name;
        if (iname) {
-         register int compare = strcmp(name, iname);
+         int compare = strcmp(name, iname);
          if (compare == 0) {
            return iter->types[i];
          } else if (compare < 0) {
@@ -602,7 +602,7 @@ SWIG_TypeQueryModule(swig_module_info *start,
        of the str field (the human readable name) */
     swig_module_info *iter = start;
     do {
-      register size_t i = 0;
+      size_t i = 0;
       for (; i < iter->size; ++i) {
        if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
          return iter->types[i];
@@ -621,10 +621,10 @@ SWIG_TypeQueryModule(swig_module_info *start,
 SWIGRUNTIME char *
 SWIG_PackData(char *c, void *ptr, size_t sz) {
   static const char hex[17] = "0123456789abcdef";
-  register const unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu =  u + sz;
+  const unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu =  u + sz;
   for (; u != eu; ++u) {
-    register unsigned char uu = *u;
+    unsigned char uu = *u;
     *(c++) = hex[(uu & 0xf0) >> 4];
     *(c++) = hex[uu & 0xf];
   }
@@ -636,11 +636,11 @@ SWIG_PackData(char *c, void *ptr, size_t sz) {
 */
 SWIGRUNTIME const char *
 SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
-  register unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu = u + sz;
+  unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu = u + sz;
   for (; u != eu; ++u) {
-    register char d = *(c++);
-    register unsigned char uu;
+    char d = *(c++);
+    unsigned char uu;
     if ((d >= '0') && (d <= '9'))
       uu = ((d - '0') << 4);
     else if ((d >= 'a') && (d <= 'f'))
@@ -799,7 +799,7 @@ static int default_error_code = E_ERROR;
   if (!(expr) ) { zend_printf("Contract Assert Failed %s\n",msg ); } else
 
 /* Standard SWIG API */
-#define SWIG_GetModule(clientdata) SWIG_Php_GetModule(clientdata)
+#define SWIG_GetModule(clientdata) SWIG_Php_GetModule()
 #define SWIG_SetModule(clientdata, pointer) SWIG_Php_SetModule(pointer)
 
 /* used to wrap returned objects in so we know whether they are newobject
@@ -972,7 +972,7 @@ SWIG_ZTS_ConvertPtr(zval *z, void **ptr, swig_type_info *ty, int flags TSRMLS_DC
 }
 
 static char const_name[] = "swig_runtime_data_type_pointer";
-static swig_module_info *SWIG_Php_GetModule(void *SWIGUNUSEDPARM(clientdata)) {
+static swig_module_info *SWIG_Php_GetModule() {
   zval *pointer;
   swig_module_info *ret = 0;
   TSRMLS_FETCH();
@@ -1022,11 +1022,10 @@ ZEND_DECLARE_MODULE_GLOBALS(ESL)
 #endif
 
 #ifdef __GNUC__
-static void SWIG_FAIL() __attribute__ ((__noreturn__));
+static void SWIG_FAIL(TSRMLS_D) __attribute__ ((__noreturn__));
 #endif
 
-static void SWIG_FAIL() {
-    TSRMLS_FETCH();
+static void SWIG_FAIL(TSRMLS_D) {
     zend_error(SWIG_ErrorCode(), "%s", SWIG_ErrorMsg());
     abort();
 }
@@ -1037,8 +1036,7 @@ static void ESL_init_globals(zend_ESL_globals *globals ) {
 }
 static void ESL_destroy_globals(zend_ESL_globals * globals) { (void)globals; }
 
-static void SWIG_ResetError() {
-  TSRMLS_FETCH();
+static void SWIG_ResetError(TSRMLS_D) {
   SWIG_ErrorMsg() = default_error_msg;
   SWIG_ErrorCode() = default_error_code;
 }
@@ -1047,9 +1045,8 @@ ZEND_NAMED_FUNCTION(_wrap_swig_ESL_alter_newobject) {
   zval **args[2];
   swig_object_wrapper *value;
   int type;
-  int thisown;
 
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1064,7 +1061,7 @@ ZEND_NAMED_FUNCTION(_wrap_swig_ESL_get_newobject) {
   swig_object_wrapper *value;
   int type;
 
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1133,7 +1130,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_event_set) {
   esl_event_t *arg2 = (esl_event_t *) 0 ;
   zval **args[2];
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1153,7 +1150,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_event_set) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1162,7 +1159,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_event_get) {
   zval **args[1];
   esl_event_t *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1179,7 +1176,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_event_get) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1188,7 +1185,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_serialized_string_set) {
   char *arg2 = (char *) 0 ;
   zval **args[2];
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1200,7 +1197,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_serialized_string_set) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -1221,7 +1218,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_serialized_string_set) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1230,7 +1227,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_serialized_string_get) {
   zval **args[1];
   char *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1251,7 +1248,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_serialized_string_get) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1260,7 +1257,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_mine_set) {
   int arg2 ;
   zval **args[2];
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1272,7 +1269,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_mine_set) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,7,CONVERT_INT_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,7,CONVERT_INT_IN@*/
   convert_to_long_ex(args[1]);
   arg2 = (int) Z_LVAL_PP(args[1]);
   /*@SWIG@*/;
@@ -1281,7 +1278,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_mine_set) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1290,7 +1287,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_mine_get) {
   zval **args[1];
   int result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1307,7 +1304,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_mine_get) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1318,14 +1315,14 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLevent__SWIG_0) {
   int arg_count;
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   arg_count = ZEND_NUM_ARGS();
   if(arg_count<1 || arg_count>2 ||
     zend_get_parameters_array_ex(arg_count,args)!=SUCCESS)
   WRONG_PARAM_COUNT;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[0])->type==IS_NULL) {
     arg1 = (char *) 0;
   } else {
@@ -1335,7 +1332,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLevent__SWIG_0) {
   /*@SWIG@*/;
   
   if(arg_count > 1) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
     if ((*args[1])->type==IS_NULL) {
       arg2 = (char *) 0;
     } else {
@@ -1351,7 +1348,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLevent__SWIG_0) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1362,7 +1359,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLevent__SWIG_1) {
   int arg_count;
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   arg_count = ZEND_NUM_ARGS();
   if(arg_count<1 || arg_count>2 ||
     zend_get_parameters_array_ex(arg_count,args)!=SUCCESS)
@@ -1374,7 +1371,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLevent__SWIG_1) {
     }
   }
   if(arg_count > 1) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,7,CONVERT_INT_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,7,CONVERT_INT_IN@*/
     convert_to_long_ex(args[1]);
     arg2 = (int) Z_LVAL_PP(args[1]);
     /*@SWIG@*/;
@@ -1386,7 +1383,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLevent__SWIG_1) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1395,7 +1392,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLevent__SWIG_2) {
   zval **args[1];
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1411,7 +1408,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLevent__SWIG_2) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1463,7 +1460,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLevent) {
   
   SWIG_ErrorCode() = E_ERROR;
   SWIG_ErrorMsg() = "No matching function for overloaded 'new_ESLevent'";
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1482,7 +1479,7 @@ static void __wrap_delete_ESLevent(zend_rsrc_list_entry *rsrc, const char *type_
   delete arg1;
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1493,7 +1490,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_serialize) {
   int arg_count;
   char *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   arg_count = ZEND_NUM_ARGS();
   if(arg_count<1 || arg_count>2 ||
     zend_get_parameters_array_ex(arg_count,args)!=SUCCESS)
@@ -1506,7 +1503,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_serialize) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   if(arg_count > 1) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
     if ((*args[1])->type==IS_NULL) {
       arg2 = (char *) 0;
     } else {
@@ -1526,7 +1523,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_serialize) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1538,7 +1535,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_setPriority) {
   int arg_count;
   bool result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   arg_count = ZEND_NUM_ARGS();
   if(arg_count<1 || arg_count>2 ||
     zend_get_parameters_array_ex(arg_count,args)!=SUCCESS)
@@ -1564,7 +1561,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_setPriority) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1576,7 +1573,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_getHeader) {
   int arg_count;
   char *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   arg_count = ZEND_NUM_ARGS();
   if(arg_count<2 || arg_count>3 ||
     zend_get_parameters_array_ex(arg_count,args)!=SUCCESS)
@@ -1589,7 +1586,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_getHeader) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -1599,7 +1596,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_getHeader) {
   /*@SWIG@*/;
   
   if(arg_count > 2) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,7,CONVERT_INT_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,7,CONVERT_INT_IN@*/
     convert_to_long_ex(args[2]);
     arg3 = (int) Z_LVAL_PP(args[2]);
     /*@SWIG@*/;
@@ -1615,7 +1612,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_getHeader) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1624,7 +1621,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_getBody) {
   zval **args[1];
   char *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1645,7 +1642,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_getBody) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1654,7 +1651,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_getType) {
   zval **args[1];
   char *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1675,7 +1672,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_getType) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1685,7 +1682,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_addBody) {
   zval **args[2];
   bool result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1697,7 +1694,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_addBody) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -1712,7 +1709,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_addBody) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1723,7 +1720,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_addHeader) {
   zval **args[3];
   bool result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 3 || zend_get_parameters_array_ex(3, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1735,7 +1732,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_addHeader) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -1745,7 +1742,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_addHeader) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[2])->type==IS_NULL) {
     arg3 = (char *) 0;
   } else {
@@ -1760,7 +1757,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_addHeader) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1771,7 +1768,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_pushHeader) {
   zval **args[3];
   bool result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 3 || zend_get_parameters_array_ex(3, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1783,7 +1780,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_pushHeader) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -1793,7 +1790,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_pushHeader) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[2])->type==IS_NULL) {
     arg3 = (char *) 0;
   } else {
@@ -1808,7 +1805,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_pushHeader) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1819,7 +1816,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_unshiftHeader) {
   zval **args[3];
   bool result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 3 || zend_get_parameters_array_ex(3, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1831,7 +1828,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_unshiftHeader) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -1841,7 +1838,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_unshiftHeader) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[2])->type==IS_NULL) {
     arg3 = (char *) 0;
   } else {
@@ -1856,7 +1853,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_unshiftHeader) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1866,7 +1863,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_delHeader) {
   zval **args[2];
   bool result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1878,7 +1875,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_delHeader) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -1893,7 +1890,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_delHeader) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1902,7 +1899,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_firstHeader) {
   zval **args[1];
   char *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1923,7 +1920,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_firstHeader) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1932,7 +1929,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_nextHeader) {
   zval **args[1];
   char *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -1953,7 +1950,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLevent_nextHeader) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -1965,13 +1962,13 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_0) {
   zval **args[4];
   ESLconnection *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 4 || zend_get_parameters_array_ex(4, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[0])->type==IS_NULL) {
     arg1 = (char *) 0;
   } else {
@@ -1981,13 +1978,13 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_0) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,7,CONVERT_INT_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,7,CONVERT_INT_IN@*/
   convert_to_long_ex(args[1]);
   arg2 = (int) Z_LVAL_PP(args[1]);
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[2])->type==IS_NULL) {
     arg3 = (char *) 0;
   } else {
@@ -1997,7 +1994,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_0) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[3])->type==IS_NULL) {
     arg4 = (char *) 0;
   } else {
@@ -2012,7 +2009,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_0) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2023,13 +2020,13 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_1) {
   zval **args[3];
   ESLconnection *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 3 || zend_get_parameters_array_ex(3, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[0])->type==IS_NULL) {
     arg1 = (char *) 0;
   } else {
@@ -2039,13 +2036,13 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_1) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,7,CONVERT_INT_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,7,CONVERT_INT_IN@*/
   convert_to_long_ex(args[1]);
   arg2 = (int) Z_LVAL_PP(args[1]);
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[2])->type==IS_NULL) {
     arg3 = (char *) 0;
   } else {
@@ -2060,7 +2057,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_1) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2072,13 +2069,13 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_2) {
   zval **args[4];
   ESLconnection *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 4 || zend_get_parameters_array_ex(4, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[0])->type==IS_NULL) {
     arg1 = (char *) 0;
   } else {
@@ -2088,7 +2085,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_2) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2098,7 +2095,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_2) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[2])->type==IS_NULL) {
     arg3 = (char *) 0;
   } else {
@@ -2108,7 +2105,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_2) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[3])->type==IS_NULL) {
     arg4 = (char *) 0;
   } else {
@@ -2123,7 +2120,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_2) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2134,13 +2131,13 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_3) {
   zval **args[3];
   ESLconnection *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 3 || zend_get_parameters_array_ex(3, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[0])->type==IS_NULL) {
     arg1 = (char *) 0;
   } else {
@@ -2150,7 +2147,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_3) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2160,7 +2157,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_3) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[2])->type==IS_NULL) {
     arg3 = (char *) 0;
   } else {
@@ -2175,7 +2172,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_3) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2184,13 +2181,13 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_4) {
   zval **args[1];
   ESLconnection *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,7,CONVERT_INT_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,7,CONVERT_INT_IN@*/
   convert_to_long_ex(args[0]);
   arg1 = (int) Z_LVAL_PP(args[0]);
   /*@SWIG@*/;
@@ -2201,7 +2198,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection__SWIG_4) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2279,7 +2276,7 @@ ZEND_NAMED_FUNCTION(_wrap_new_ESLconnection) {
   
   SWIG_ErrorCode() = E_ERROR;
   SWIG_ErrorMsg() = "No matching function for overloaded 'new_ESLconnection'";
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2298,7 +2295,7 @@ static void __wrap_delete_ESLconnection(zend_rsrc_list_entry *rsrc, const char *
   delete arg1;
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2307,7 +2304,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_socketDescriptor) {
   zval **args[1];
   int result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2324,7 +2321,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_socketDescriptor) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2333,7 +2330,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_connected) {
   zval **args[1];
   int result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2350,7 +2347,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_connected) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2359,7 +2356,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_getInfo) {
   zval **args[1];
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2376,7 +2373,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_getInfo) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2386,7 +2383,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_send) {
   zval **args[2];
   int result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2398,7 +2395,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_send) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2413,7 +2410,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_send) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2423,7 +2420,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_sendRecv) {
   zval **args[2];
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2435,7 +2432,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_sendRecv) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2450,7 +2447,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_sendRecv) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2462,7 +2459,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_api) {
   int arg_count;
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   arg_count = ZEND_NUM_ARGS();
   if(arg_count<2 || arg_count>3 ||
     zend_get_parameters_array_ex(arg_count,args)!=SUCCESS)
@@ -2475,7 +2472,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_api) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2485,7 +2482,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_api) {
   /*@SWIG@*/;
   
   if(arg_count > 2) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
     if ((*args[2])->type==IS_NULL) {
       arg3 = (char *) 0;
     } else {
@@ -2501,7 +2498,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_api) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2514,7 +2511,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_bgapi) {
   int arg_count;
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   arg_count = ZEND_NUM_ARGS();
   if(arg_count<2 || arg_count>4 ||
     zend_get_parameters_array_ex(arg_count,args)!=SUCCESS)
@@ -2527,7 +2524,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_bgapi) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2537,7 +2534,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_bgapi) {
   /*@SWIG@*/;
   
   if(arg_count > 2) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
     if ((*args[2])->type==IS_NULL) {
       arg3 = (char *) 0;
     } else {
@@ -2548,7 +2545,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_bgapi) {
     
   }
   if(arg_count > 3) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
     if ((*args[3])->type==IS_NULL) {
       arg4 = (char *) 0;
     } else {
@@ -2564,7 +2561,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_bgapi) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2574,7 +2571,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_sendEvent) {
   zval **args[2];
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2596,7 +2593,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_sendEvent) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2608,7 +2605,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_sendMSG) {
   int arg_count;
   int result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   arg_count = ZEND_NUM_ARGS();
   if(arg_count<2 || arg_count>3 ||
     zend_get_parameters_array_ex(arg_count,args)!=SUCCESS)
@@ -2626,7 +2623,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_sendMSG) {
     }
   }
   if(arg_count > 2) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
     if ((*args[2])->type==IS_NULL) {
       arg3 = (char *) 0;
     } else {
@@ -2642,7 +2639,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_sendMSG) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2651,7 +2648,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_recvEvent) {
   zval **args[1];
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2668,7 +2665,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_recvEvent) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2678,7 +2675,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_recvEventTimed) {
   zval **args[2];
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2690,7 +2687,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_recvEventTimed) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,7,CONVERT_INT_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,7,CONVERT_INT_IN@*/
   convert_to_long_ex(args[1]);
   arg2 = (int) Z_LVAL_PP(args[1]);
   /*@SWIG@*/;
@@ -2701,7 +2698,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_recvEventTimed) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2712,7 +2709,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_filter) {
   zval **args[3];
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 3 || zend_get_parameters_array_ex(3, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2724,7 +2721,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_filter) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2734,7 +2731,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_filter) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[2])->type==IS_NULL) {
     arg3 = (char *) 0;
   } else {
@@ -2749,7 +2746,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_filter) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2760,7 +2757,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_events) {
   zval **args[3];
   int result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 3 || zend_get_parameters_array_ex(3, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2772,7 +2769,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_events) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2782,7 +2779,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_events) {
   /*@SWIG@*/;
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[2])->type==IS_NULL) {
     arg3 = (char *) 0;
   } else {
@@ -2797,7 +2794,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_events) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2810,7 +2807,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_execute) {
   int arg_count;
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   arg_count = ZEND_NUM_ARGS();
   if(arg_count<2 || arg_count>4 ||
     zend_get_parameters_array_ex(arg_count,args)!=SUCCESS)
@@ -2823,7 +2820,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_execute) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2833,7 +2830,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_execute) {
   /*@SWIG@*/;
   
   if(arg_count > 2) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
     if ((*args[2])->type==IS_NULL) {
       arg3 = (char *) 0;
     } else {
@@ -2844,7 +2841,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_execute) {
     
   }
   if(arg_count > 3) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
     if ((*args[3])->type==IS_NULL) {
       arg4 = (char *) 0;
     } else {
@@ -2860,7 +2857,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_execute) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2873,7 +2870,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_executeAsync) {
   int arg_count;
   ESLevent *result = 0 ;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   arg_count = ZEND_NUM_ARGS();
   if(arg_count<2 || arg_count>4 ||
     zend_get_parameters_array_ex(arg_count,args)!=SUCCESS)
@@ -2886,7 +2883,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_executeAsync) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2896,7 +2893,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_executeAsync) {
   /*@SWIG@*/;
   
   if(arg_count > 2) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
     if ((*args[2])->type==IS_NULL) {
       arg3 = (char *) 0;
     } else {
@@ -2907,7 +2904,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_executeAsync) {
     
   }
   if(arg_count > 3) {
-    /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+    /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
     if ((*args[3])->type==IS_NULL) {
       arg4 = (char *) 0;
     } else {
@@ -2923,7 +2920,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_executeAsync) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2933,7 +2930,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_setAsyncExecute) {
   zval **args[2];
   int result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2945,7 +2942,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_setAsyncExecute) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2960,7 +2957,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_setAsyncExecute) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -2970,7 +2967,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_setEventLock) {
   zval **args[2];
   int result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_array_ex(2, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -2982,7 +2979,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_setEventLock) {
   }
   if(!arg1) SWIG_PHP_Error(E_ERROR, "this pointer is NULL");
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,62,CONVERT_STRING_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,62,CONVERT_STRING_IN@*/
   if ((*args[1])->type==IS_NULL) {
     arg2 = (char *) 0;
   } else {
@@ -2997,7 +2994,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_setEventLock) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -3006,7 +3003,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_disconnect) {
   zval **args[1];
   int result;
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
@@ -3023,7 +3020,7 @@ ZEND_NAMED_FUNCTION(_wrap_ESLconnection_disconnect) {
   }
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -3031,13 +3028,13 @@ ZEND_NAMED_FUNCTION(_wrap_eslSetLogLevel) {
   int arg1 ;
   zval **args[1];
   
-  SWIG_ResetError();
+  SWIG_ResetError(TSRMLS_C);
   if(ZEND_NUM_ARGS() != 1 || zend_get_parameters_array_ex(1, args) != SUCCESS) {
     WRONG_PARAM_COUNT;
   }
   
   
-  /*@SWIG:/usr/share/swig2.0/php/utils.i,7,CONVERT_INT_IN@*/
+  /*@SWIG:/usr/share/swig3.0/php/utils.i,7,CONVERT_INT_IN@*/
   convert_to_long_ex(args[0]);
   arg1 = (int) Z_LVAL_PP(args[0]);
   /*@SWIG@*/;
@@ -3046,7 +3043,7 @@ ZEND_NAMED_FUNCTION(_wrap_eslSetLogLevel) {
   
   return;
 fail:
-  SWIG_FAIL();
+  SWIG_FAIL(TSRMLS_C);
 }
 
 
@@ -3068,48 +3065,206 @@ static ZEND_RSRC_DTOR_FUNC(_wrap_destroy_p_ESLconnection) {
 /* class entry subsection */
 
 
+/* arginfo subsection */
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_event_set, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_event_get, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_serialized_string_set, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_serialized_string_get, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_mine_set, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_mine_get, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_new_eslevent, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_serialize, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_setpriority, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_getheader, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_getbody, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_gettype, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_addbody, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_addheader, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_pushheader, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_unshiftheader, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_delheader, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_firstheader, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslevent_nextheader, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_new_eslconnection, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_socketdescriptor, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_connected, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_getinfo, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_send, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_sendrecv, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_api, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_bgapi, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_sendevent, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_sendmsg, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_recvevent, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_recveventtimed, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_filter, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_events, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_execute, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_executeasync, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_setasyncexecute, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_seteventlock, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslconnection_disconnect, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+ZEND_BEGIN_ARG_INFO_EX(swig_arginfo_eslsetloglevel, 0, 0, 0)
+ ZEND_ARG_PASS_INFO(0)
+ZEND_END_ARG_INFO()
+
+
 /* entry subsection */
 /* Every non-class user visible function must have an entry here */
 static zend_function_entry ESL_functions[] = {
- SWIG_ZEND_NAMED_FE(eslevent_event_set,_wrap_ESLevent_event_set,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_event_get,_wrap_ESLevent_event_get,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_serialized_string_set,_wrap_ESLevent_serialized_string_set,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_serialized_string_get,_wrap_ESLevent_serialized_string_get,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_mine_set,_wrap_ESLevent_mine_set,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_mine_get,_wrap_ESLevent_mine_get,NULL)
- SWIG_ZEND_NAMED_FE(new_eslevent,_wrap_new_ESLevent,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_serialize,_wrap_ESLevent_serialize,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_setpriority,_wrap_ESLevent_setPriority,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_getheader,_wrap_ESLevent_getHeader,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_getbody,_wrap_ESLevent_getBody,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_gettype,_wrap_ESLevent_getType,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_addbody,_wrap_ESLevent_addBody,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_addheader,_wrap_ESLevent_addHeader,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_pushheader,_wrap_ESLevent_pushHeader,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_unshiftheader,_wrap_ESLevent_unshiftHeader,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_delheader,_wrap_ESLevent_delHeader,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_firstheader,_wrap_ESLevent_firstHeader,NULL)
- SWIG_ZEND_NAMED_FE(eslevent_nextheader,_wrap_ESLevent_nextHeader,NULL)
- SWIG_ZEND_NAMED_FE(new_eslconnection,_wrap_new_ESLconnection,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_socketdescriptor,_wrap_ESLconnection_socketDescriptor,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_connected,_wrap_ESLconnection_connected,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_getinfo,_wrap_ESLconnection_getInfo,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_send,_wrap_ESLconnection_send,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_sendrecv,_wrap_ESLconnection_sendRecv,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_api,_wrap_ESLconnection_api,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_bgapi,_wrap_ESLconnection_bgapi,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_sendevent,_wrap_ESLconnection_sendEvent,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_sendmsg,_wrap_ESLconnection_sendMSG,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_recvevent,_wrap_ESLconnection_recvEvent,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_recveventtimed,_wrap_ESLconnection_recvEventTimed,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_filter,_wrap_ESLconnection_filter,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_events,_wrap_ESLconnection_events,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_execute,_wrap_ESLconnection_execute,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_executeasync,_wrap_ESLconnection_executeAsync,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_setasyncexecute,_wrap_ESLconnection_setAsyncExecute,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_seteventlock,_wrap_ESLconnection_setEventLock,NULL)
- SWIG_ZEND_NAMED_FE(eslconnection_disconnect,_wrap_ESLconnection_disconnect,NULL)
- SWIG_ZEND_NAMED_FE(eslsetloglevel,_wrap_eslSetLogLevel,NULL)
+ SWIG_ZEND_NAMED_FE(eslevent_event_set,_wrap_ESLevent_event_set,swig_arginfo_eslevent_event_set)
+ SWIG_ZEND_NAMED_FE(eslevent_event_get,_wrap_ESLevent_event_get,swig_arginfo_eslevent_event_get)
+ SWIG_ZEND_NAMED_FE(eslevent_serialized_string_set,_wrap_ESLevent_serialized_string_set,swig_arginfo_eslevent_serialized_string_set)
+ SWIG_ZEND_NAMED_FE(eslevent_serialized_string_get,_wrap_ESLevent_serialized_string_get,swig_arginfo_eslevent_serialized_string_get)
+ SWIG_ZEND_NAMED_FE(eslevent_mine_set,_wrap_ESLevent_mine_set,swig_arginfo_eslevent_mine_set)
+ SWIG_ZEND_NAMED_FE(eslevent_mine_get,_wrap_ESLevent_mine_get,swig_arginfo_eslevent_mine_get)
+ SWIG_ZEND_NAMED_FE(new_eslevent,_wrap_new_ESLevent,swig_arginfo_new_eslevent)
+ SWIG_ZEND_NAMED_FE(eslevent_serialize,_wrap_ESLevent_serialize,swig_arginfo_eslevent_serialize)
+ SWIG_ZEND_NAMED_FE(eslevent_setpriority,_wrap_ESLevent_setPriority,swig_arginfo_eslevent_setpriority)
+ SWIG_ZEND_NAMED_FE(eslevent_getheader,_wrap_ESLevent_getHeader,swig_arginfo_eslevent_getheader)
+ SWIG_ZEND_NAMED_FE(eslevent_getbody,_wrap_ESLevent_getBody,swig_arginfo_eslevent_getbody)
+ SWIG_ZEND_NAMED_FE(eslevent_gettype,_wrap_ESLevent_getType,swig_arginfo_eslevent_gettype)
+ SWIG_ZEND_NAMED_FE(eslevent_addbody,_wrap_ESLevent_addBody,swig_arginfo_eslevent_addbody)
+ SWIG_ZEND_NAMED_FE(eslevent_addheader,_wrap_ESLevent_addHeader,swig_arginfo_eslevent_addheader)
+ SWIG_ZEND_NAMED_FE(eslevent_pushheader,_wrap_ESLevent_pushHeader,swig_arginfo_eslevent_pushheader)
+ SWIG_ZEND_NAMED_FE(eslevent_unshiftheader,_wrap_ESLevent_unshiftHeader,swig_arginfo_eslevent_unshiftheader)
+ SWIG_ZEND_NAMED_FE(eslevent_delheader,_wrap_ESLevent_delHeader,swig_arginfo_eslevent_delheader)
+ SWIG_ZEND_NAMED_FE(eslevent_firstheader,_wrap_ESLevent_firstHeader,swig_arginfo_eslevent_firstheader)
+ SWIG_ZEND_NAMED_FE(eslevent_nextheader,_wrap_ESLevent_nextHeader,swig_arginfo_eslevent_nextheader)
+ SWIG_ZEND_NAMED_FE(new_eslconnection,_wrap_new_ESLconnection,swig_arginfo_new_eslconnection)
+ SWIG_ZEND_NAMED_FE(eslconnection_socketdescriptor,_wrap_ESLconnection_socketDescriptor,swig_arginfo_eslconnection_socketdescriptor)
+ SWIG_ZEND_NAMED_FE(eslconnection_connected,_wrap_ESLconnection_connected,swig_arginfo_eslconnection_connected)
+ SWIG_ZEND_NAMED_FE(eslconnection_getinfo,_wrap_ESLconnection_getInfo,swig_arginfo_eslconnection_getinfo)
+ SWIG_ZEND_NAMED_FE(eslconnection_send,_wrap_ESLconnection_send,swig_arginfo_eslconnection_send)
+ SWIG_ZEND_NAMED_FE(eslconnection_sendrecv,_wrap_ESLconnection_sendRecv,swig_arginfo_eslconnection_sendrecv)
+ SWIG_ZEND_NAMED_FE(eslconnection_api,_wrap_ESLconnection_api,swig_arginfo_eslconnection_api)
+ SWIG_ZEND_NAMED_FE(eslconnection_bgapi,_wrap_ESLconnection_bgapi,swig_arginfo_eslconnection_bgapi)
+ SWIG_ZEND_NAMED_FE(eslconnection_sendevent,_wrap_ESLconnection_sendEvent,swig_arginfo_eslconnection_sendevent)
+ SWIG_ZEND_NAMED_FE(eslconnection_sendmsg,_wrap_ESLconnection_sendMSG,swig_arginfo_eslconnection_sendmsg)
+ SWIG_ZEND_NAMED_FE(eslconnection_recvevent,_wrap_ESLconnection_recvEvent,swig_arginfo_eslconnection_recvevent)
+ SWIG_ZEND_NAMED_FE(eslconnection_recveventtimed,_wrap_ESLconnection_recvEventTimed,swig_arginfo_eslconnection_recveventtimed)
+ SWIG_ZEND_NAMED_FE(eslconnection_filter,_wrap_ESLconnection_filter,swig_arginfo_eslconnection_filter)
+ SWIG_ZEND_NAMED_FE(eslconnection_events,_wrap_ESLconnection_events,swig_arginfo_eslconnection_events)
+ SWIG_ZEND_NAMED_FE(eslconnection_execute,_wrap_ESLconnection_execute,swig_arginfo_eslconnection_execute)
+ SWIG_ZEND_NAMED_FE(eslconnection_executeasync,_wrap_ESLconnection_executeAsync,swig_arginfo_eslconnection_executeasync)
+ SWIG_ZEND_NAMED_FE(eslconnection_setasyncexecute,_wrap_ESLconnection_setAsyncExecute,swig_arginfo_eslconnection_setasyncexecute)
+ SWIG_ZEND_NAMED_FE(eslconnection_seteventlock,_wrap_ESLconnection_setEventLock,swig_arginfo_eslconnection_seteventlock)
+ SWIG_ZEND_NAMED_FE(eslconnection_disconnect,_wrap_ESLconnection_disconnect,swig_arginfo_eslconnection_disconnect)
+ SWIG_ZEND_NAMED_FE(eslsetloglevel,_wrap_eslSetLogLevel,swig_arginfo_eslsetloglevel)
  SWIG_ZEND_NAMED_FE(swig_ESL_alter_newobject,_wrap_swig_ESL_alter_newobject,NULL)
  SWIG_ZEND_NAMED_FE(swig_ESL_get_newobject,_wrap_swig_ESL_get_newobject,NULL)
 {NULL, NULL, NULL}
@@ -3156,7 +3311,7 @@ SWIGEXPORT zend_module_entry *get_module(void) { return &ESL_module_entry; }
  * 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 statically 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
index 4c996f502b901197e3125d179928e81c93099b38..d6420ea75dfd3a7c6b8b7d17b4fc9719ae2971a4 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * 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
index 15c6f152641d9747b4777a684c4a993d8330656b..cd9b7c4f3feac8d2c6cedbb78e3e1f93a8d4af7f 100644 (file)
@@ -1,5 +1,5 @@
 # This file was automatically generated by SWIG (http://www.swig.org).
-# Version 2.0.12
+# Version 3.0.2
 #
 # Do not make changes to this file unless you know what you are doing--modify
 # the SWIG interface file instead.
index 09b3876f79a2059ce434035d377d3248cd73499b..71396dd4ba517c370026efec10b8a16bc3d95ed6 100644 (file)
@@ -5,7 +5,7 @@ SITE_DIR=$(DESTDIR)/`python -c "from distutils.sysconfig import get_python_lib;
 all: _ESL.so
 
 esl_wrap.cpp:
-       swig2.0 -module ESL -classic -python -c++ -DMULTIPLICITY -threads -I../src/include -o esl_wrap.cpp ../ESL.i
+       swig3.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
index 09c89729f16a860c8343b78659c645c4013d78ca..b67be5488a4e5ac38ebd7ebbe9f68aae7bb5adc0 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * 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
@@ -562,14 +562,14 @@ SWIG_MangledTypeQueryModule(swig_module_info *start,
   swig_module_info *iter = start;
   do {
     if (iter->size) {
-      register size_t l = 0;
-      register size_t r = iter->size - 1;
+      size_t l = 0;
+      size_t r = iter->size - 1;
       do {
        /* since l+r >= 0, we can (>> 1) instead (/ 2) */
-       register size_t i = (l + r) >> 1;
+       size_t i = (l + r) >> 1;
        const char *iname = iter->types[i]->name;
        if (iname) {
-         register int compare = strcmp(name, iname);
+         int compare = strcmp(name, iname);
          if (compare == 0) {
            return iter->types[i];
          } else if (compare < 0) {
@@ -613,7 +613,7 @@ SWIG_TypeQueryModule(swig_module_info *start,
        of the str field (the human readable name) */
     swig_module_info *iter = start;
     do {
-      register size_t i = 0;
+      size_t i = 0;
       for (; i < iter->size; ++i) {
        if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
          return iter->types[i];
@@ -632,10 +632,10 @@ SWIG_TypeQueryModule(swig_module_info *start,
 SWIGRUNTIME char *
 SWIG_PackData(char *c, void *ptr, size_t sz) {
   static const char hex[17] = "0123456789abcdef";
-  register const unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu =  u + sz;
+  const unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu =  u + sz;
   for (; u != eu; ++u) {
-    register unsigned char uu = *u;
+    unsigned char uu = *u;
     *(c++) = hex[(uu & 0xf0) >> 4];
     *(c++) = hex[uu & 0xf];
   }
@@ -647,11 +647,11 @@ SWIG_PackData(char *c, void *ptr, size_t sz) {
 */
 SWIGRUNTIME const char *
 SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
-  register unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu = u + sz;
+  unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu = u + sz;
   for (; u != eu; ++u) {
-    register char d = *(c++);
-    register unsigned char uu;
+    char d = *(c++);
+    unsigned char uu;
     if ((d >= '0') && (d <= '9'))
       uu = ((d - '0') << 4);
     else if ((d >= 'a') && (d <= 'f'))
@@ -1328,7 +1328,7 @@ SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssi
   }  
   if (!PyTuple_Check(args)) {
     if (min <= 1 && max >= 1) {
-      register int i;
+      int i;
       objs[0] = args;
       for (i = 1; i < max; ++i) {
        objs[i] = 0;
@@ -1338,7 +1338,7 @@ SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssi
     PyErr_SetString(PyExc_SystemError, "UnpackTuple() argument list is not a tuple");
     return 0;
   } else {
-    register Py_ssize_t l = PyTuple_GET_SIZE(args);
+    Py_ssize_t l = PyTuple_GET_SIZE(args);
     if (l < min) {
       PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got %d", 
                   name, (min == max ? "" : "at least "), (int)min, (int)l);
@@ -1348,7 +1348,7 @@ SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssi
                   name, (min == max ? "" : "at most "), (int)max, (int)l);
       return 0;
     } else {
-      register int i;
+      int i;
       for (i = 0; i < l; ++i) {
        objs[i] = PyTuple_GET_ITEM(args, i);
       }
@@ -2463,7 +2463,7 @@ SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this)
     }
   } else {
 #if PY_VERSION_HEX >= 0x03000000
-    inst = PyBaseObject_Type.tp_new((PyTypeObject*) data->newargs, Py_None, Py_None);
+    inst = ((PyTypeObject*) data->newargs)->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;
@@ -2966,7 +2966,7 @@ static swig_module_info swig_module = {swig_types, 5, 0, 0, 0, 0};
 #endif
 #define SWIG_name    "_ESL"
 
-#define SWIGVERSION 0x02001
+#define SWIGVERSION 0x03000
 #define SWIG_VERSION SWIGVERSION
 
 
@@ -3145,7 +3145,11 @@ SWIG_FromCharPtrAndSize(const char* carray, size_t size)
        SWIG_InternalNewPointerObj(const_cast< char * >(carray), pchar_descriptor, 0) : SWIG_Py_Void();
     } else {
 #if PY_VERSION_HEX >= 0x03000000
+#if PY_VERSION_HEX >= 0x03010000
+      return PyUnicode_DecodeUTF8(carray, static_cast< int >(size), "surrogateescape");
+#else
       return PyUnicode_FromStringAndSize(carray, static_cast< int >(size));
+#endif
 #else
       return PyString_FromStringAndSize(carray, static_cast< int >(size));
 #endif
@@ -5452,7 +5456,7 @@ static swig_const_info swig_const_table[] = {
  * 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 statically 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
@@ -5782,7 +5786,7 @@ extern "C" {
       var = var->next;
     }
     if (res == NULL && !PyErr_Occurred()) {
-      PyErr_SetString(PyExc_NameError,"Unknown C global variable");
+      PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n);
     }
     return res;
   }
@@ -5799,7 +5803,7 @@ extern "C" {
       var = var->next;
     }
     if (res == 1 && !PyErr_Occurred()) {
-      PyErr_SetString(PyExc_NameError,"Unknown C global variable");
+      PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n);
     }
     return res;
   }
index e6ce4731f3fcb9f6a477f221e4fbe6c80bedf505..ae3d2a10d3145fe00f031c3e320e7b3fb593b174 100644 (file)
@@ -6,7 +6,7 @@ RUBY_GEM_DIR=$(shell $(RUBY) -e 'puts RbConfig::CONFIG["rubylibdir"]')
 all: ESL.so
 
 esl_wrap.cpp:
-       swig2.0 -module ESL -ruby -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
+       swig3.0 -module ESL -ruby -c++ -DMULTIPLICITY -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
index 27eaf201eb810e1e9903418fa1c0cb30aa822886..92aa37fb8093cdd2467b89d2a13b7cfe69e042c7 100644 (file)
@@ -1,6 +1,6 @@
 /* ----------------------------------------------------------------------------
  * This file was automatically generated by SWIG (http://www.swig.org).
- * Version 2.0.12
+ * Version 3.0.2
  *
  * 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
@@ -658,14 +658,14 @@ SWIG_MangledTypeQueryModule(swig_module_info *start,
   swig_module_info *iter = start;
   do {
     if (iter->size) {
-      register size_t l = 0;
-      register size_t r = iter->size - 1;
+      size_t l = 0;
+      size_t r = iter->size - 1;
       do {
        /* since l+r >= 0, we can (>> 1) instead (/ 2) */
-       register size_t i = (l + r) >> 1;
+       size_t i = (l + r) >> 1;
        const char *iname = iter->types[i]->name;
        if (iname) {
-         register int compare = strcmp(name, iname);
+         int compare = strcmp(name, iname);
          if (compare == 0) {
            return iter->types[i];
          } else if (compare < 0) {
@@ -709,7 +709,7 @@ SWIG_TypeQueryModule(swig_module_info *start,
        of the str field (the human readable name) */
     swig_module_info *iter = start;
     do {
-      register size_t i = 0;
+      size_t i = 0;
       for (; i < iter->size; ++i) {
        if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
          return iter->types[i];
@@ -728,10 +728,10 @@ SWIG_TypeQueryModule(swig_module_info *start,
 SWIGRUNTIME char *
 SWIG_PackData(char *c, void *ptr, size_t sz) {
   static const char hex[17] = "0123456789abcdef";
-  register const unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu =  u + sz;
+  const unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu =  u + sz;
   for (; u != eu; ++u) {
-    register unsigned char uu = *u;
+    unsigned char uu = *u;
     *(c++) = hex[(uu & 0xf0) >> 4];
     *(c++) = hex[uu & 0xf];
   }
@@ -743,11 +743,11 @@ SWIG_PackData(char *c, void *ptr, size_t sz) {
 */
 SWIGRUNTIME const char *
 SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
-  register unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu = u + sz;
+  unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu = u + sz;
   for (; u != eu; ++u) {
-    register char d = *(c++);
-    register unsigned char uu;
+    char d = *(c++);
+    unsigned char uu;
     if ((d >= '0') && (d <= '9'))
       uu = ((d - '0') << 4);
     else if ((d >= 'a') && (d <= 'f'))
@@ -1503,14 +1503,13 @@ SWIG_Ruby_InitRuntime(void)
 SWIGRUNTIME void
 SWIG_Ruby_define_class(swig_type_info *type)
 {
-  VALUE klass;
   char *klass_name = (char *) malloc(4 + strlen(type->name) + 1);
   sprintf(klass_name, "TYPE%s", type->name);
   if (NIL_P(_cSWIG_Pointer)) {
     _cSWIG_Pointer = rb_define_class_under(_mSWIG, "Pointer", rb_cObject);
     rb_undef_method(CLASS_OF(_cSWIG_Pointer), "new");
   }
-  klass = rb_define_class_under(_mSWIG, klass_name, _cSWIG_Pointer);
+  rb_define_class_under(_mSWIG, klass_name, _cSWIG_Pointer);
   free((void *) klass_name);
 }
 
@@ -1823,7 +1822,7 @@ static VALUE mESL;
 #define SWIG_RUBY_THREAD_END_BLOCK
 
 
-#define SWIGVERSION 0x02001
+#define SWIGVERSION 0x03000
 #define SWIG_VERSION SWIGVERSION
 
 
@@ -1929,7 +1928,7 @@ SWIG_ruby_failed(void)
 } 
 
 
-/*@SWIG:/usr/share/swig2.0/ruby/rubyprimtypes.swg,19,%ruby_aux_method@*/
+/*@SWIG:/usr/share/swig3.0/ruby/rubyprimtypes.swg,19,%ruby_aux_method@*/
 SWIGINTERN VALUE SWIG_AUX_NUM2LONG(VALUE *args)
 {
   VALUE obj = args[0];
@@ -3890,7 +3889,7 @@ static swig_cast_info *swig_cast_initial[] = {
  * 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 statically 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
index 85b1fa1211c494a7200a0bb45e50437a34bcf51b..527ef0356926d70f03c60d5d7a51fa60307f4d22 100644 (file)
@@ -5,7 +5,7 @@ WRAP_GCC_WARNING_SILENCE=-Wno-unused-function
 all: ESL.so
 
 esl_wrap.cpp:
-       swig -module ESL -tcl -c++ -DMULTIPLICITY -I../src/include -o esl_wrap.cpp ../ESL.i
+       swig3.0 -module ESL -tcl -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
index c0a0df4a82dd9b51b4b942ca1b58390e5ca4e14c..f294fcb8bd99d79e65540f268236f4c42d844034 100644 (file)
@@ -1,27 +1,32 @@
 /* ----------------------------------------------------------------------------
  * 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 3.0.2
+ *
+ * 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 SWIGTCL
+
 
 #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() {
@@ -60,14 +65,20 @@ 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
 
@@ -75,7 +86,7 @@ template <typename T> T SwigValueInit() {
 # ifdef __cplusplus
 #   define SWIGUNUSEDPARM(p)
 # else
-#   define SWIGUNUSEDPARM(p) p SWIGUNUSED 
+#   define SWIGUNUSEDPARM(p) p SWIGUNUSED
 # endif
 #endif
 
@@ -118,7 +129,7 @@ template <typename T> T SwigValueInit() {
 #   define SWIGSTDCALL __stdcall
 # else
 #   define SWIGSTDCALL
-# endif 
+# endif
 #endif
 
 /* Deal with Microsoft's attempt at deprecating C standard runtime functions */
@@ -143,7 +154,7 @@ template <typename T> T SwigValueInit() {
 /* -----------------------------------------------------------------------------
  * 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.
  * ----------------------------------------------------------------------------- */
 
@@ -162,11 +173,11 @@ template <typename T> T SwigValueInit() {
 
 /*
   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
@@ -190,17 +201,17 @@ template <typename T> T SwigValueInit() {
 #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
@@ -208,7 +219,7 @@ template <typename T> T SwigValueInit() {
        //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)) {
@@ -217,7 +228,7 @@ template <typename T> T SwigValueInit() {
       // 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);
@@ -232,28 +243,28 @@ template <typename T> T SwigValueInit() {
     } 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
@@ -262,18 +273,17 @@ template <typename T> T SwigValueInit() {
        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)
@@ -294,7 +304,6 @@ template <typename T> T SwigValueInit() {
 #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
@@ -305,20 +314,18 @@ template <typename T> T SwigValueInit() {
 #  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
@@ -358,7 +365,7 @@ typedef struct swig_module_info {
   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.
 
@@ -378,18 +385,18 @@ SWIG_TypeNameComp(const char *f1, const char *l1,
 
 /*
   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;
@@ -397,58 +404,65 @@ SWIG_TypeEquiv(const char *nb, const char *tb) {
 
 /*
   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;
 }
 
 /*
@@ -459,7 +473,7 @@ SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory) {
   return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
 }
 
-/* 
+/*
    Dynamic pointer casting. Down an inheritance hierarchy
 */
 SWIGRUNTIME swig_type_info *
@@ -503,7 +517,7 @@ SWIG_TypePrettyName(const swig_type_info *type) {
     return type->name;
 }
 
-/* 
+/*
    Set the clientdata field for a type
 */
 SWIGRUNTIME void
@@ -511,14 +525,14 @@ SWIG_TypeClientData(swig_type_info *ti, void *clientdata) {
   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;
   }
 }
@@ -527,31 +541,31 @@ SWIG_TypeNewClientData(swig_type_info *ti, void *clientdata) {
   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 {
     if (iter->size) {
-      register size_t l = 0;
-      register size_t r = iter->size - 1;
+      size_t l = 0;
+      size_t r = iter->size - 1;
       do {
        /* since l+r >= 0, we can (>> 1) instead (/ 2) */
-       register size_t i = (l + r) >> 1; 
+       size_t i = (l + r) >> 1;
        const char *iname = iter->types[i]->name;
        if (iname) {
-         register int compare = strcmp(name, iname);
-         if (compare == 0) {       
+         int compare = strcmp(name, iname);
+         if (compare == 0) {
            return iter->types[i];
          } else if (compare < 0) {
            if (i) {
@@ -576,14 +590,14 @@ SWIG_MangledTypeQueryModule(swig_module_info *start,
   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);
@@ -594,7 +608,7 @@ SWIG_TypeQueryModule(swig_module_info *start,
        of the str field (the human readable name) */
     swig_module_info *iter = start;
     do {
-      register size_t i = 0;
+      size_t i = 0;
       for (; i < iter->size; ++i) {
        if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
          return iter->types[i];
@@ -602,56 +616,56 @@ SWIG_TypeQueryModule(swig_module_info *start,
       iter = iter->next;
     } while (iter != end);
   }
-  
+
   /* neither found a match */
   return 0;
 }
 
-/* 
+/*
    Pack binary data into a string
 */
 SWIGRUNTIME char *
 SWIG_PackData(char *c, void *ptr, size_t sz) {
   static const char hex[17] = "0123456789abcdef";
-  register const unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu =  u + sz;
+  const unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu =  u + sz;
   for (; u != eu; ++u) {
-    register unsigned char uu = *u;
+    unsigned char uu = *u;
     *(c++) = hex[(uu & 0xf0) >> 4];
     *(c++) = hex[uu & 0xf];
   }
   return c;
 }
 
-/* 
+/*
    Unpack binary data from a string
 */
 SWIGRUNTIME const char *
 SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
-  register unsigned char *u = (unsigned char *) ptr;
-  register const unsigned char *eu = u + sz;
+  unsigned char *u = (unsigned char *) ptr;
+  const unsigned char *eu = u + sz;
   for (; u != eu; ++u) {
-    register char d = *(c++);
-    register unsigned char uu;
+    char d = *(c++);
+    unsigned char uu;
     if ((d >= '0') && (d <= '9'))
       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 *
@@ -711,18 +725,18 @@ SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
 #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
 
 
@@ -855,6 +869,7 @@ typedef struct swig_class {
   struct swig_class **bases;
   const char              **base_names;
   swig_module_info   *module;
+  Tcl_HashTable       hashtable;
 } swig_class;
 
 typedef struct swig_instance {
@@ -913,9 +928,6 @@ SWIG_Tcl_GetConstantObj(const char *key) {
 
 
 /* -----------------------------------------------------------------------------
- * 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.
- *
  * tclrun.swg
  *
  * This file contains the runtime support for Tcl modules and includes
@@ -988,9 +1000,6 @@ SWIG_Tcl_GetConstantObj(const char *key) {
 
 #ifdef __cplusplus
 extern "C" {
-#if 0
-} /* cc-mode */
-#endif
 #endif
 
 /* Object support */
@@ -1197,7 +1206,7 @@ SWIG_Tcl_SetModule(Tcl_Interp *interp, swig_module_info *module) {
   /* create a new pointer */
   data = SWIG_PackData(buf, &module, sizeof(swig_type_info **));
   *data = 0;
-  Tcl_SetVar(interp, (char *)"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME, buf, 0);
+  Tcl_SetVar(interp, (char *)"swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME, buf, TCL_GLOBAL_ONLY);
 }
 
 /* -----------------------------------------------------------------------------*
@@ -1260,6 +1269,7 @@ SWIG_Tcl_MethodCommand(ClientData clientData, Tcl_Interp *interp, int objc, Tcl_
   cls_stack_bi[cls_stack_top] = -1;
   cls = inst->classptr;
   while (1) {
+    Tcl_HashEntry* hashentry;
     bi = cls_stack_bi[cls_stack_top];
     cls = cls_stack[cls_stack_top];
     if (bi != -1) {
@@ -1284,19 +1294,17 @@ SWIG_Tcl_MethodCommand(ClientData clientData, Tcl_Interp *interp, int objc, Tcl_
     }
     cls_stack_bi[cls_stack_top]++;
 
-    meth = cls->methods;
-    /* Check for methods */
-    while (meth && meth->name) {
-      if (strcmp(meth->name,method) == 0) {
+    hashentry = Tcl_FindHashEntry(&(cls->hashtable), method);
+    if (hashentry) {
+        ClientData cd = Tcl_GetHashValue(hashentry);
+        swig_wrapper method_wrapper = (swig_wrapper)cd;
         oldarg = objv[1];
         objv[1] = inst->thisptr;
         Tcl_IncrRefCount(inst->thisptr);
-        rcode = (*meth->method)(clientData,interp,objc,objv);
+        rcode = (method_wrapper)(clientData,interp,objc,objv);
         objv[1] = oldarg;
         Tcl_DecrRefCount(inst->thisptr);
         return rcode;
-      }
-      meth++;
     }
     /* Check class methods for a match */
     if (strcmp(method,"cget") == 0) {
@@ -1403,7 +1411,7 @@ SWIGRUNTIME Tcl_Obj *
 SWIG_Tcl_NewInstanceObj(Tcl_Interp *interp, void *thisvalue, swig_type_info *type, int flags) {
   Tcl_Obj *robj = SWIG_NewPointerObj(thisvalue, type,0);
   /* Check to see if this pointer belongs to a class or not */
-  if ((type->clientdata) && (interp)) {
+  if (thisvalue && (type->clientdata) && (interp)) {
     Tcl_CmdInfo    ci;
     char          *name;
     name = Tcl_GetStringFromObj(robj,NULL);
@@ -1602,9 +1610,6 @@ SWIG_Tcl_GetArgs(Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[], const char
 }
 
 #ifdef __cplusplus
-#if 0
-{ /* cc-mode */
-#endif
 }
 #endif
 
@@ -1635,7 +1640,7 @@ static swig_module_info swig_module = {swig_types, 5, 0, 0, 0, 0};
 #define SWIG_prefix  ""
 #define SWIG_version "0.0"
 
-#define SWIGVERSION 0x010335 
+#define SWIGVERSION 0x030002 
 #define SWIG_VERSION SWIGVERSION
 
 
@@ -1661,6 +1666,11 @@ SWIGEXPORT int SWIG_init(Tcl_Interp *);
 }
 #endif
 
+/* Compatibility version for TCL stubs */
+#ifndef SWIG_TCL_STUBS_VERSION
+#define SWIG_TCL_STUBS_VERSION "8.1"
+#endif
+
 
 
 #include "esl.h"
@@ -1782,7 +1792,6 @@ _wrap_ESLevent_event_set(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, i
   arg2 = reinterpret_cast< esl_event_t * >(argp2);
   if (arg1) (arg1)->event = arg2;
   
-  
   return TCL_OK;
 fail:
   return TCL_ERROR;
@@ -1792,9 +1801,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLevent_event_get(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLevent *arg1 = (ESLevent *) 0 ;
-  esl_event_t *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  esl_event_t *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLevent_event_get self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -1850,9 +1859,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLevent_serialized_string_get(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLevent *arg1 = (ESLevent *) 0 ;
-  char *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  char *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLevent_serialized_string_get self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -1890,7 +1899,6 @@ _wrap_ESLevent_mine_set(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, in
   arg2 = static_cast< int >(val2);
   if (arg1) (arg1)->mine = arg2;
   
-  
   return TCL_OK;
 fail:
   return TCL_ERROR;
@@ -1900,9 +1908,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLevent_mine_get(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLevent *arg1 = (ESLevent *) 0 ;
-  int result;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  int result;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLevent_mine_get self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -1922,13 +1930,13 @@ SWIGINTERN int
 _wrap_new_ESLevent__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   char *arg1 = (char *) 0 ;
   char *arg2 = (char *) NULL ;
-  ESLevent *result = 0 ;
   int res1 ;
   char *buf1 = 0 ;
   int alloc1 = 0 ;
   int res2 ;
   char *buf2 = 0 ;
   int alloc2 = 0 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o|o:new_ESLevent type ?subclass_name? ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_AsCharPtrAndSize(objv[1], &buf1, NULL, &alloc1);
@@ -1959,11 +1967,11 @@ SWIGINTERN int
 _wrap_new_ESLevent__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   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 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o|o:new_ESLevent wrap_me ?free_me? ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_esl_event_t, 0 |  0 );
@@ -1989,9 +1997,9 @@ fail:
 SWIGINTERN int
 _wrap_new_ESLevent__SWIG_2(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLevent *arg1 = (ESLevent *) 0 ;
-  ESLevent *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:new_ESLevent me ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2054,7 +2062,11 @@ _wrap_new_ESLevent(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int obj
     }
   }
   
-  Tcl_SetResult(interp,(char *) "No matching function for overloaded 'new_ESLevent'", TCL_STATIC);
+  Tcl_SetResult(interp,(char *) "Wrong number or type of 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"
+    "    ESLevent::ESLevent(ESLevent *)\n", TCL_STATIC);
   return TCL_ERROR;
 }
 
@@ -2073,7 +2085,6 @@ _wrap_delete_ESLevent(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int
   arg1 = reinterpret_cast< ESLevent * >(argp1);
   delete arg1;
   
-  
   return TCL_OK;
 fail:
   return TCL_ERROR;
@@ -2084,12 +2095,12 @@ SWIGINTERN int
 _wrap_ESLevent_serialize(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   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 ;
+  char *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o|o:ESLevent_serialize self ?format? ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2118,11 +2129,11 @@ SWIGINTERN int
 _wrap_ESLevent_setPriority(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   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 ;
+  bool result;
   
   if (SWIG_GetArgs(interp, objc, objv,"o|o:ESLevent_setPriority self ?priority? ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2156,7 +2167,6 @@ _wrap_ESLevent_getHeader(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, i
   ESLevent *arg1 = (ESLevent *) 0 ;
   char *arg2 = (char *) 0 ;
   int arg3 = (int) -1 ;
-  char *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
@@ -2164,6 +2174,7 @@ _wrap_ESLevent_getHeader(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, i
   int alloc2 = 0 ;
   int val3 ;
   int ecode3 = 0 ;
+  char *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo|o:ESLevent_getHeader self header_name ?idx? ",(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2196,9 +2207,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLevent_getBody(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLevent *arg1 = (ESLevent *) 0 ;
-  char *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  char *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLevent_getBody self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2217,9 +2228,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLevent_getType(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLevent *arg1 = (ESLevent *) 0 ;
-  char *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  char *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLevent_getType self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2239,12 +2250,12 @@ SWIGINTERN int
 _wrap_ESLevent_addBody(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLevent *arg1 = (ESLevent *) 0 ;
   char *arg2 = (char *) 0 ;
-  bool result;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
   char *buf2 = 0 ;
   int alloc2 = 0 ;
+  bool result;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo:ESLevent_addBody self value ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2272,7 +2283,6 @@ _wrap_ESLevent_addHeader(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, i
   ESLevent *arg1 = (ESLevent *) 0 ;
   char *arg2 = (char *) 0 ;
   char *arg3 = (char *) 0 ;
-  bool result;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
@@ -2281,6 +2291,7 @@ _wrap_ESLevent_addHeader(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, i
   int res3 ;
   char *buf3 = 0 ;
   int alloc3 = 0 ;
+  bool result;
   
   if (SWIG_GetArgs(interp, objc, objv,"ooo:ESLevent_addHeader self header_name value ",(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2315,7 +2326,6 @@ _wrap_ESLevent_pushHeader(ClientData clientData SWIGUNUSED, Tcl_Interp *interp,
   ESLevent *arg1 = (ESLevent *) 0 ;
   char *arg2 = (char *) 0 ;
   char *arg3 = (char *) 0 ;
-  bool result;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
@@ -2324,6 +2334,7 @@ _wrap_ESLevent_pushHeader(ClientData clientData SWIGUNUSED, Tcl_Interp *interp,
   int res3 ;
   char *buf3 = 0 ;
   int alloc3 = 0 ;
+  bool result;
   
   if (SWIG_GetArgs(interp, objc, objv,"ooo:ESLevent_pushHeader self header_name value ",(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2358,7 +2369,6 @@ _wrap_ESLevent_unshiftHeader(ClientData clientData SWIGUNUSED, Tcl_Interp *inter
   ESLevent *arg1 = (ESLevent *) 0 ;
   char *arg2 = (char *) 0 ;
   char *arg3 = (char *) 0 ;
-  bool result;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
@@ -2367,6 +2377,7 @@ _wrap_ESLevent_unshiftHeader(ClientData clientData SWIGUNUSED, Tcl_Interp *inter
   int res3 ;
   char *buf3 = 0 ;
   int alloc3 = 0 ;
+  bool result;
   
   if (SWIG_GetArgs(interp, objc, objv,"ooo:ESLevent_unshiftHeader self header_name value ",(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2400,12 +2411,12 @@ SWIGINTERN int
 _wrap_ESLevent_delHeader(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLevent *arg1 = (ESLevent *) 0 ;
   char *arg2 = (char *) 0 ;
-  bool result;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
   char *buf2 = 0 ;
   int alloc2 = 0 ;
+  bool result;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo:ESLevent_delHeader self header_name ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2431,9 +2442,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLevent_firstHeader(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLevent *arg1 = (ESLevent *) 0 ;
-  char *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  char *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLevent_firstHeader self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2452,9 +2463,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLevent_nextHeader(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLevent *arg1 = (ESLevent *) 0 ;
-  char *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  char *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLevent_nextHeader self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLevent, 0 |  0 );
@@ -2504,7 +2515,6 @@ _wrap_new_ESLconnection__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *in
   int arg2 ;
   char *arg3 = (char *) 0 ;
   char *arg4 = (char *) 0 ;
-  ESLconnection *result = 0 ;
   int res1 ;
   char *buf1 = 0 ;
   int alloc1 = 0 ;
@@ -2516,6 +2526,7 @@ _wrap_new_ESLconnection__SWIG_0(ClientData clientData SWIGUNUSED, Tcl_Interp *in
   int res4 ;
   char *buf4 = 0 ;
   int alloc4 = 0 ;
+  ESLconnection *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"oooo:new_ESLconnection host port user password ",(void *)0,(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_AsCharPtrAndSize(objv[1], &buf1, NULL, &alloc1);
@@ -2557,7 +2568,6 @@ _wrap_new_ESLconnection__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *in
   char *arg1 = (char *) 0 ;
   int arg2 ;
   char *arg3 = (char *) 0 ;
-  ESLconnection *result = 0 ;
   int res1 ;
   char *buf1 = 0 ;
   int alloc1 = 0 ;
@@ -2566,6 +2576,7 @@ _wrap_new_ESLconnection__SWIG_1(ClientData clientData SWIGUNUSED, Tcl_Interp *in
   int res3 ;
   char *buf3 = 0 ;
   int alloc3 = 0 ;
+  ESLconnection *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"ooo:new_ESLconnection host port password ",(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_AsCharPtrAndSize(objv[1], &buf1, NULL, &alloc1);
@@ -2601,7 +2612,6 @@ _wrap_new_ESLconnection__SWIG_2(ClientData clientData SWIGUNUSED, Tcl_Interp *in
   char *arg2 = (char *) 0 ;
   char *arg3 = (char *) 0 ;
   char *arg4 = (char *) 0 ;
-  ESLconnection *result = 0 ;
   int res1 ;
   char *buf1 = 0 ;
   int alloc1 = 0 ;
@@ -2614,6 +2624,7 @@ _wrap_new_ESLconnection__SWIG_2(ClientData clientData SWIGUNUSED, Tcl_Interp *in
   int res4 ;
   char *buf4 = 0 ;
   int alloc4 = 0 ;
+  ESLconnection *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"oooo:new_ESLconnection host port user password ",(void *)0,(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_AsCharPtrAndSize(objv[1], &buf1, NULL, &alloc1);
@@ -2657,7 +2668,6 @@ _wrap_new_ESLconnection__SWIG_3(ClientData clientData SWIGUNUSED, Tcl_Interp *in
   char *arg1 = (char *) 0 ;
   char *arg2 = (char *) 0 ;
   char *arg3 = (char *) 0 ;
-  ESLconnection *result = 0 ;
   int res1 ;
   char *buf1 = 0 ;
   int alloc1 = 0 ;
@@ -2667,6 +2677,7 @@ _wrap_new_ESLconnection__SWIG_3(ClientData clientData SWIGUNUSED, Tcl_Interp *in
   int res3 ;
   char *buf3 = 0 ;
   int alloc3 = 0 ;
+  ESLconnection *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"ooo:new_ESLconnection host port password ",(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_AsCharPtrAndSize(objv[1], &buf1, NULL, &alloc1);
@@ -2701,9 +2712,9 @@ fail:
 SWIGINTERN int
 _wrap_new_ESLconnection__SWIG_4(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   int arg1 ;
-  ESLconnection *result = 0 ;
   int val1 ;
   int ecode1 = 0 ;
+  ESLconnection *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:new_ESLconnection socket ",(void *)0) == TCL_ERROR) SWIG_fail;
   ecode1 = SWIG_AsVal_int SWIG_TCL_CALL_ARGS_2(objv[1], &val1);
@@ -2810,7 +2821,13 @@ _wrap_new_ESLconnection(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, in
     }
   }
   
-  Tcl_SetResult(interp,(char *) "No matching function for overloaded 'new_ESLconnection'", TCL_STATIC);
+  Tcl_SetResult(interp,(char *) "Wrong number or type of 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"
+    "    ESLconnection::ESLconnection(char const *,char const *,char const *,char const *)\n"
+    "    ESLconnection::ESLconnection(char const *,char const *,char const *)\n"
+    "    ESLconnection::ESLconnection(int)\n", TCL_STATIC);
   return TCL_ERROR;
 }
 
@@ -2829,7 +2846,6 @@ _wrap_delete_ESLconnection(ClientData clientData SWIGUNUSED, Tcl_Interp *interp,
   arg1 = reinterpret_cast< ESLconnection * >(argp1);
   delete arg1;
   
-  
   return TCL_OK;
 fail:
   return TCL_ERROR;
@@ -2839,9 +2855,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLconnection_socketDescriptor(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLconnection *arg1 = (ESLconnection *) 0 ;
-  int result;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  int result;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLconnection_socketDescriptor self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -2860,9 +2876,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLconnection_connected(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLconnection *arg1 = (ESLconnection *) 0 ;
-  int result;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  int result;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLconnection_connected self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -2881,9 +2897,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLconnection_getInfo(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLconnection *arg1 = (ESLconnection *) 0 ;
-  ESLevent *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLconnection_getInfo self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -2903,12 +2919,12 @@ SWIGINTERN int
 _wrap_ESLconnection_send(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   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 result;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo:ESLconnection_send self cmd ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -2935,12 +2951,12 @@ SWIGINTERN int
 _wrap_ESLconnection_sendRecv(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   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 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo:ESLconnection_sendRecv self cmd ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -2968,7 +2984,6 @@ _wrap_ESLconnection_api(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, in
   ESLconnection *arg1 = (ESLconnection *) 0 ;
   char *arg2 = (char *) 0 ;
   char *arg3 = (char *) NULL ;
-  ESLevent *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
@@ -2977,6 +2992,7 @@ _wrap_ESLconnection_api(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, in
   int res3 ;
   char *buf3 = 0 ;
   int alloc3 = 0 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo|o:ESLconnection_api self cmd ?arg? ",(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3014,7 +3030,6 @@ _wrap_ESLconnection_bgapi(ClientData clientData SWIGUNUSED, Tcl_Interp *interp,
   char *arg2 = (char *) 0 ;
   char *arg3 = (char *) NULL ;
   char *arg4 = (char *) NULL ;
-  ESLevent *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
@@ -3026,6 +3041,7 @@ _wrap_ESLconnection_bgapi(ClientData clientData SWIGUNUSED, Tcl_Interp *interp,
   int res4 ;
   char *buf4 = 0 ;
   int alloc4 = 0 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo|oo:ESLconnection_bgapi self cmd ?arg? ?job_uuid? ",(void *)0,(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3070,11 +3086,11 @@ SWIGINTERN int
 _wrap_ESLconnection_sendEvent(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLconnection *arg1 = (ESLconnection *) 0 ;
   ESLevent *arg2 = (ESLevent *) 0 ;
-  ESLevent *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
   void *argp2 = 0 ;
   int res2 = 0 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo:ESLconnection_sendEvent self send_me ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3100,7 +3116,6 @@ _wrap_ESLconnection_sendMSG(ClientData clientData SWIGUNUSED, Tcl_Interp *interp
   ESLconnection *arg1 = (ESLconnection *) 0 ;
   ESLevent *arg2 = (ESLevent *) 0 ;
   char *arg3 = (char *) NULL ;
-  int result;
   void *argp1 = 0 ;
   int res1 = 0 ;
   void *argp2 = 0 ;
@@ -3108,6 +3123,7 @@ _wrap_ESLconnection_sendMSG(ClientData clientData SWIGUNUSED, Tcl_Interp *interp
   int res3 ;
   char *buf3 = 0 ;
   int alloc3 = 0 ;
+  int result;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo|o:ESLconnection_sendMSG self send_me ?uuid? ",(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3140,9 +3156,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLconnection_recvEvent(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLconnection *arg1 = (ESLconnection *) 0 ;
-  ESLevent *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLconnection_recvEvent self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3162,11 +3178,11 @@ SWIGINTERN int
 _wrap_ESLconnection_recvEventTimed(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLconnection *arg1 = (ESLconnection *) 0 ;
   int arg2 ;
-  ESLevent *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int val2 ;
   int ecode2 = 0 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo:ESLconnection_recvEventTimed self ms ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3192,7 +3208,6 @@ _wrap_ESLconnection_filter(ClientData clientData SWIGUNUSED, Tcl_Interp *interp,
   ESLconnection *arg1 = (ESLconnection *) 0 ;
   char *arg2 = (char *) 0 ;
   char *arg3 = (char *) 0 ;
-  ESLevent *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
@@ -3201,6 +3216,7 @@ _wrap_ESLconnection_filter(ClientData clientData SWIGUNUSED, Tcl_Interp *interp,
   int res3 ;
   char *buf3 = 0 ;
   int alloc3 = 0 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"ooo:ESLconnection_filter self header value ",(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3235,7 +3251,6 @@ _wrap_ESLconnection_events(ClientData clientData SWIGUNUSED, Tcl_Interp *interp,
   ESLconnection *arg1 = (ESLconnection *) 0 ;
   char *arg2 = (char *) 0 ;
   char *arg3 = (char *) 0 ;
-  int result;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
@@ -3244,6 +3259,7 @@ _wrap_ESLconnection_events(ClientData clientData SWIGUNUSED, Tcl_Interp *interp,
   int res3 ;
   char *buf3 = 0 ;
   int alloc3 = 0 ;
+  int result;
   
   if (SWIG_GetArgs(interp, objc, objv,"ooo:ESLconnection_events self etype value ",(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3279,7 +3295,6 @@ _wrap_ESLconnection_execute(ClientData clientData SWIGUNUSED, Tcl_Interp *interp
   char *arg2 = (char *) 0 ;
   char *arg3 = (char *) NULL ;
   char *arg4 = (char *) NULL ;
-  ESLevent *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
@@ -3291,6 +3306,7 @@ _wrap_ESLconnection_execute(ClientData clientData SWIGUNUSED, Tcl_Interp *interp
   int res4 ;
   char *buf4 = 0 ;
   int alloc4 = 0 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo|oo:ESLconnection_execute self app ?arg? ?uuid? ",(void *)0,(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3337,7 +3353,6 @@ _wrap_ESLconnection_executeAsync(ClientData clientData SWIGUNUSED, Tcl_Interp *i
   char *arg2 = (char *) 0 ;
   char *arg3 = (char *) NULL ;
   char *arg4 = (char *) NULL ;
-  ESLevent *result = 0 ;
   void *argp1 = 0 ;
   int res1 = 0 ;
   int res2 ;
@@ -3349,6 +3364,7 @@ _wrap_ESLconnection_executeAsync(ClientData clientData SWIGUNUSED, Tcl_Interp *i
   int res4 ;
   char *buf4 = 0 ;
   int alloc4 = 0 ;
+  ESLevent *result = 0 ;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo|oo:ESLconnection_executeAsync self app ?arg? ?uuid? ",(void *)0,(void *)0,(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3393,12 +3409,12 @@ SWIGINTERN int
 _wrap_ESLconnection_setAsyncExecute(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   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 result;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo:ESLconnection_setAsyncExecute self val ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3425,12 +3441,12 @@ SWIGINTERN int
 _wrap_ESLconnection_setEventLock(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   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 result;
   
   if (SWIG_GetArgs(interp, objc, objv,"oo:ESLconnection_setEventLock self val ",(void *)0,(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3456,9 +3472,9 @@ fail:
 SWIGINTERN int
 _wrap_ESLconnection_disconnect(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
   ESLconnection *arg1 = (ESLconnection *) 0 ;
-  int result;
   void *argp1 = 0 ;
   int res1 = 0 ;
+  int result;
   
   if (SWIG_GetArgs(interp, objc, objv,"o:ESLconnection_disconnect self ",(void *)0) == TCL_ERROR) SWIG_fail;
   res1 = SWIG_ConvertPtr(objv[1], &argp1,SWIGTYPE_p_ESLconnection, 0 |  0 );
@@ -3619,18 +3635,18 @@ static swig_cast_info *swig_cast_initial[] = {
 #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 statically 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
@@ -3640,17 +3656,17 @@ static swig_cast_info *swig_cast_initial[] = {
  * 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
@@ -3676,8 +3692,6 @@ SWIG_InitializeModule(void *clientdata) {
   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 */
@@ -3715,7 +3729,7 @@ SWIG_InitializeModule(void *clientdata) {
     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 */
@@ -3867,7 +3881,7 @@ extern "C" {
   
   SWIGINTERN void
   SWIG_Tcl_InstallConstants(Tcl_Interp *interp, swig_const_info constants[]) {
-    int i;
+    size_t i;
     Tcl_Obj *obj;
     
     if (!swigconstTableinit) {
@@ -3892,6 +3906,27 @@ extern "C" {
     }
   }
   
+  /* Create fast method lookup tables */
+  
+  SWIGINTERN void
+  SWIG_Tcl_InstallMethodLookupTables(void) {
+    size_t i;
+    
+    for (i = 0; i < swig_module.size; ++i) {
+      swig_type_info *type = swig_module.type_initial[i];
+      if (type->clientdata) {
+        swig_class* klass = (swig_class*) type->clientdata;
+        swig_method* meth;
+        Tcl_InitHashTable(&(klass->hashtable), TCL_STRING_KEYS);
+        for (meth = klass->methods; meth && meth->name; ++meth) {
+          int newEntry;
+          Tcl_HashEntry* hashentry = Tcl_CreateHashEntry(&(klass->hashtable), meth->name, &newEntry);
+          Tcl_SetHashValue(hashentry, (ClientData)meth->method);
+        }
+      }
+    }
+  }
+  
 #ifdef __cplusplus
 }
 #endif
@@ -3901,13 +3936,21 @@ extern "C" {
  * -----------------------------------------------------------------------------*/
 
 SWIGEXPORT int SWIG_init(Tcl_Interp *interp) {
-  int i;
+  size_t i;
   if (interp == 0) return TCL_ERROR;
 #ifdef USE_TCL_STUBS
-  if (Tcl_InitStubs(interp, (char*)"8.1", 0) == NULL) {
+  /* (char*) cast is required to avoid compiler warning/error for Tcl < 8.4. */
+  if (Tcl_InitStubs(interp, (char*)SWIG_TCL_STUBS_VERSION, 0) == NULL) {
     return TCL_ERROR;
   }
 #endif  
+#ifdef USE_TK_STUBS
+  /* (char*) cast is required to avoid compiler warning/error. */
+  if (Tk_InitStubs(interp, (char*)SWIG_TCL_STUBS_VERSION, 0) == NULL) {
+    return TCL_ERROR;
+  }
+#endif
+  
   Tcl_PkgProvide(interp, (char*)SWIG_name, (char*)SWIG_version);
   
 #ifdef SWIG_namespace
@@ -3930,6 +3973,7 @@ SWIGEXPORT int SWIG_init(Tcl_Interp *interp) {
   }
   
   SWIG_Tcl_InstallConstants(interp, swig_constants);
+  SWIG_Tcl_InstallMethodLookupTables();
   
   
   return TCL_OK;