/* ----------------------------------------------------------------------------
 * This file was automatically generated by SWIG (http://www.swig.org).
 * Version 2.0.0
 * 
 * This file is not intended to be easily readable and contains a number of 
 * coding conventions designed to improve portability and efficiency. Do not make
 * changes to this file unless you know what you are doing--modify the SWIG 
 * interface file instead. 
 * ----------------------------------------------------------------------------- */

#define SWIGPERL
#define SWIG_CASTRANK_MODE


#ifdef __cplusplus
/* SwigValueWrapper is described in swig.swg */
template<typename T> class SwigValueWrapper {
  struct SwigMovePointer {
    T *ptr;
    SwigMovePointer(T *p) : ptr(p) { }
    ~SwigMovePointer() { delete ptr; }
    SwigMovePointer& operator=(SwigMovePointer& rhs) { T* oldptr = ptr; ptr = 0; delete oldptr; ptr = rhs.ptr; rhs.ptr = 0; return *this; }
  } pointer;
  SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
  SwigValueWrapper(const SwigValueWrapper<T>& rhs);
public:
  SwigValueWrapper() : pointer(0) { }
  SwigValueWrapper& operator=(const T& t) { SwigMovePointer tmp(new T(t)); pointer = tmp; return *this; }
  operator T&() const { return *pointer.ptr; }
  T *operator&() { return pointer.ptr; }
};

template <typename T> T SwigValueInit() {
  return T();
}
#endif

/* -----------------------------------------------------------------------------
 *  This section contains generic SWIG labels for method/variable
 *  declarations/attributes, and other compiler dependent labels.
 * ----------------------------------------------------------------------------- */

/* template workaround for compilers that cannot correctly implement the C++ standard */
#ifndef SWIGTEMPLATEDISAMBIGUATOR
# if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
#  define SWIGTEMPLATEDISAMBIGUATOR template
# elif defined(__HP_aCC)
/* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */
/* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */
#  define SWIGTEMPLATEDISAMBIGUATOR template
# else
#  define SWIGTEMPLATEDISAMBIGUATOR
# endif
#endif

/* inline attribute */
#ifndef SWIGINLINE
# if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
#   define SWIGINLINE inline
# else
#   define SWIGINLINE
# endif
#endif

/* attribute recognised by some compilers to avoid 'unused' warnings */
#ifndef SWIGUNUSED
# if defined(__GNUC__)
#   if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
#     define SWIGUNUSED __attribute__ ((__unused__)) 
#   else
#     define SWIGUNUSED
#   endif
# elif defined(__ICC)
#   define SWIGUNUSED __attribute__ ((__unused__)) 
# else
#   define SWIGUNUSED 
# endif
#endif

#ifndef SWIG_MSC_UNSUPPRESS_4505
# if defined(_MSC_VER)
#   pragma warning(disable : 4505) /* unreferenced local function has been removed */
# endif 
#endif

#ifndef SWIGUNUSEDPARM
# ifdef __cplusplus
#   define SWIGUNUSEDPARM(p)
# else
#   define SWIGUNUSEDPARM(p) p SWIGUNUSED 
# endif
#endif

/* internal SWIG method */
#ifndef SWIGINTERN
# define SWIGINTERN static SWIGUNUSED
#endif

/* internal inline SWIG method */
#ifndef SWIGINTERNINLINE
# define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
#endif

/* exporting methods */
#if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
#  ifndef GCC_HASCLASSVISIBILITY
#    define GCC_HASCLASSVISIBILITY
#  endif
#endif

#ifndef SWIGEXPORT
# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
#   if defined(STATIC_LINKED)
#     define SWIGEXPORT
#   else
#     define SWIGEXPORT __declspec(dllexport)
#   endif
# else
#   if defined(__GNUC__) && defined(GCC_HASCLASSVISIBILITY)
#     define SWIGEXPORT __attribute__ ((visibility("default")))
#   else
#     define SWIGEXPORT
#   endif
# endif
#endif

/* calling conventions for Windows */
#ifndef SWIGSTDCALL
# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
#   define SWIGSTDCALL __stdcall
# else
#   define SWIGSTDCALL
# endif 
#endif

/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
#if !defined(SWIG_NO_CRT_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE)
# define _CRT_SECURE_NO_DEPRECATE
#endif

/* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */
#if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE)
# define _SCL_SECURE_NO_DEPRECATE
#endif


/* -----------------------------------------------------------------------------
 * swigrun.swg
 *
 * This file contains generic C API SWIG runtime support for pointer
 * type checking.
 * ----------------------------------------------------------------------------- */

/* This should only be incremented when either the layout of swig_type_info changes,
   or for whatever reason, the runtime changes incompatibly */
#define SWIG_RUNTIME_VERSION "4"

/* define SWIG_TYPE_TABLE_NAME as "SWIG_TYPE_TABLE" */
#ifdef SWIG_TYPE_TABLE
# define SWIG_QUOTE_STRING(x) #x
# define SWIG_EXPAND_AND_QUOTE_STRING(x) SWIG_QUOTE_STRING(x)
# define SWIG_TYPE_TABLE_NAME SWIG_EXPAND_AND_QUOTE_STRING(SWIG_TYPE_TABLE)
#else
# define SWIG_TYPE_TABLE_NAME
#endif

/*
  You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
  creating a static or dynamic library from the SWIG runtime code.
  In 99.9% of the cases, SWIG just needs to declare them as 'static'.
  
  But only do this if strictly necessary, ie, if you have problems
  with your compiler or suchlike.
*/

#ifndef SWIGRUNTIME
# define SWIGRUNTIME SWIGINTERN
#endif

#ifndef SWIGRUNTIMEINLINE
# define SWIGRUNTIMEINLINE SWIGRUNTIME SWIGINLINE
#endif

/*  Generic buffer size */
#ifndef SWIG_BUFFER_SIZE
# define SWIG_BUFFER_SIZE 1024
#endif

/* Flags for pointer conversions */
#define SWIG_POINTER_DISOWN        0x1
#define SWIG_CAST_NEW_MEMORY       0x2

/* Flags for new pointer objects */
#define SWIG_POINTER_OWN           0x1


/* 
   Flags/methods for returning states.
   
   The SWIG conversion methods, as ConvertPtr, return and integer 
   that tells if the conversion was successful or not. And if not,
   an error code can be returned (see swigerrors.swg for the codes).
   
   Use the following macros/flags to set or process the returning
   states.
   
   In old versions of SWIG, code such as the following was usually written:

     if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
       // success code
     } else {
       //fail code
     }

   Now you can be more explicit:

    int res = SWIG_ConvertPtr(obj,vptr,ty.flags);
    if (SWIG_IsOK(res)) {
      // success code
    } else {
      // fail code
    }

   which is the same really, but now you can also do

    Type *ptr;
    int res = SWIG_ConvertPtr(obj,(void **)(&ptr),ty.flags);
    if (SWIG_IsOK(res)) {
      // success code
      if (SWIG_IsNewObj(res) {
        ...
	delete *ptr;
      } else {
        ...
      }
    } else {
      // fail code
    }
    
   I.e., now SWIG_ConvertPtr can return new objects and you can
   identify the case and take care of the deallocation. Of course that
   also requires SWIG_ConvertPtr to return new result values, such as

      int SWIG_ConvertPtr(obj, ptr,...) {         
        if (<obj is ok>) {			       
          if (<need new object>) {		       
            *ptr = <ptr to new allocated object>; 
            return SWIG_NEWOBJ;		       
          } else {				       
            *ptr = <ptr to old object>;	       
            return SWIG_OLDOBJ;		       
          } 				       
        } else {				       
          return SWIG_BADOBJ;		       
        }					       
      }

   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.

   Finally, if the SWIG_CASTRANK_MODE is enabled, the result code
   allows to return the 'cast rank', for example, if you have this

       int food(double)
       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_ERROR                 (-1)
#define SWIG_IsOK(r)               (r >= 0)
#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)
/* The NewMask denotes the object was created (using new/malloc) */
#define SWIG_NEWOBJMASK            (SWIG_CASTRANKLIMIT  << 1)
/* The TmpMask is for in/out typemaps that use temporal objects */
#define SWIG_TMPOBJMASK            (SWIG_NEWOBJMASK << 1)
/* Simple returning values */
#define SWIG_BADOBJ                (SWIG_ERROR)
#define SWIG_OLDOBJ                (SWIG_OK)
#define SWIG_NEWOBJ                (SWIG_OK | SWIG_NEWOBJMASK)
#define SWIG_TMPOBJ                (SWIG_OK | SWIG_TMPOBJMASK)
/* Check, add and del mask methods */
#define SWIG_AddNewMask(r)         (SWIG_IsOK(r) ? (r | SWIG_NEWOBJMASK) : r)
#define SWIG_DelNewMask(r)         (SWIG_IsOK(r) ? (r & ~SWIG_NEWOBJMASK) : r)
#define SWIG_IsNewObj(r)           (SWIG_IsOK(r) && (r & SWIG_NEWOBJMASK))
#define SWIG_AddTmpMask(r)         (SWIG_IsOK(r) ? (r | SWIG_TMPOBJMASK) : r)
#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
#    define SWIG_TypeRank             unsigned long
#  endif
#  ifndef SWIG_MAXCASTRANK            /* Default cast allowed */
#    define SWIG_MAXCASTRANK          (2)
#  endif
#  define SWIG_CASTRANKMASK          ((SWIG_CASTRANKLIMIT) -1)
#  define SWIG_CastRank(r)           (r & SWIG_CASTRANKMASK)
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; 
}
#else /* no cast-rank mode */
#  define SWIG_AddCast
#  define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
#endif


#include <string.h>

#ifdef __cplusplus
extern "C" {
#endif

typedef void *(*swig_converter_func)(void *, int *);
typedef struct swig_type_info *(*swig_dycast_func)(void **);

/* Structure to store information on one type */
typedef struct swig_type_info {
  const char             *name;			/* mangled name of this type */
  const char             *str;			/* human readable name of this type */
  swig_dycast_func        dcast;		/* dynamic cast function down a hierarchy */
  struct swig_cast_info  *cast;			/* linked list of types that can cast into this type */
  void                   *clientdata;		/* language specific type data */
  int                    owndata;		/* flag if the structure owns the clientdata */
} swig_type_info;

/* Structure to store a type and conversion function used for casting */
typedef struct swig_cast_info {
  swig_type_info         *type;			/* pointer to type that is equivalent to this type */
  swig_converter_func     converter;		/* function to cast the void pointers */
  struct swig_cast_info  *next;			/* pointer to next cast in linked list */
  struct swig_cast_info  *prev;			/* pointer to the previous cast */
} swig_cast_info;

/* Structure used to store module information
 * Each module generates one structure like this, and the runtime collects
 * all of these structures and stores them in a circularly linked list.*/
typedef struct swig_module_info {
  swig_type_info         **types;		/* Array of pointers to swig_type_info structures that are in this module */
  size_t                 size;		        /* Number of types in this module */
  struct swig_module_info *next;		/* Pointer to next element in circularly linked list */
  swig_type_info         **type_initial;	/* Array of initially generated type structures */
  swig_cast_info         **cast_initial;	/* Array of initially generated casting structures */
  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.

  Return 0 when the two name types are equivalent, as in
  strncmp, but skipping ' '.
*/
SWIGRUNTIME int
SWIG_TypeNameComp(const char *f1, const char *l1,
		  const char *f2, const char *l2) {
  for (;(f1 != l1) && (f2 != l2); ++f1, ++f2) {
    while ((*f1 == ' ') && (f1 != l1)) ++f1;
    while ((*f2 == ' ') && (f2 != l2)) ++f2;
    if (*f1 != *f2) return (*f1 > *f2) ? 1 : -1;
  }
  return (int)((l1 - f1) - (l2 - f2));
}

/*
  Check type equivalence in a name list like <name1>|<name2>|...
  Return 0 if not equal, 1 if equal
*/
SWIGRUNTIME int
SWIG_TypeEquiv(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;
}

/*
  Check type equivalence in a name list like <name1>|<name2>|...
  Return 0 if equal, -1 if nb < tb, 1 if nb > tb
*/
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;
}


/*
  Check the typename
*/
SWIGRUNTIME swig_cast_info *
SWIG_TypeCheck(const char *c, swig_type_info *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;
}

/* 
  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 *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;
}

/*
  Cast a pointer up an inheritance hierarchy
*/
SWIGRUNTIMEINLINE void *
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 *
SWIG_TypeDynamicCast(swig_type_info *ty, void **ptr) {
  swig_type_info *lastty = ty;
  if (!ty || !ty->dcast) return ty;
  while (ty && (ty->dcast)) {
    ty = (*ty->dcast)(ptr);
    if (ty) lastty = ty;
  }
  return lastty;
}

/*
  Return the name associated with this type
*/
SWIGRUNTIMEINLINE const char *
SWIG_TypeName(const swig_type_info *ty) {
  return ty->name;
}

/*
  Return the pretty name associated with this type,
  that is an unmangled type name in a form presentable to the user.
*/
SWIGRUNTIME const char *
SWIG_TypePrettyName(const swig_type_info *type) {
  /* The "str" field contains the equivalent pretty names of the
     type, separated by vertical-bar characters.  We choose
     to print the last name, as it is often (?) the most
     specific. */
  if (!type) return NULL;
  if (type->str != NULL) {
    const char *last_name = type->str;
    const char *s;
    for (s = type->str; *s; s++)
      if (*s == '|') last_name = s+1;
    return last_name;
  }
  else
    return type->name;
}

/* 
   Set the clientdata field for a type
*/
SWIGRUNTIME void
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;
  }
}
SWIGRUNTIME void
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.  
  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, 
		            const char *name) {
  swig_module_info *iter = start;
  do {
    if (iter->size) {
      register size_t l = 0;
      register size_t r = iter->size - 1;
      do {
	/* since l+r >= 0, we can (>> 1) instead (/ 2) */
	register size_t i = (l + r) >> 1; 
	const char *iname = iter->types[i]->name;
	if (iname) {
	  register int compare = strcmp(name, iname);
	  if (compare == 0) {	    
	    return iter->types[i];
	  } else if (compare < 0) {
	    if (i) {
	      r = i - 1;
	    } else {
	      break;
	    }
	  } else if (compare > 0) {
	    l = i + 1;
	  }
	} else {
	  break; /* should never happen */
	}
      } while (l <= r);
    }
    iter = iter->next;
  } while (iter != end);
  return 0;
}

/*
  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.  
  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, 
		     const char *name) {
  /* STEP 1: Search the name field using binary search */
  swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
  if (ret) {
    return ret;
  } else {
    /* STEP 2: If the type hasn't been found, do a complete search
       of the str field (the human readable name) */
    swig_module_info *iter = start;
    do {
      register 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];
      }
      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;
  for (; u != eu; ++u) {
    register 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;
  for (; u != eu; ++u) {
    register char d = *(c++);
    register unsigned char uu;
    if ((d >= '0') && (d <= '9'))
      uu = ((d - '0') << 4);
    else if ((d >= 'a') && (d <= 'f'))
      uu = ((d - ('a'-10)) << 4);
    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 
      return (char *) 0;
    *u = uu;
  }
  return c;
}

/* 
   Pack 'void *' into a string buffer.
*/
SWIGRUNTIME char *
SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz) {
  char *r = buff;
  if ((2*sizeof(void *) + 2) > bsz) return 0;
  *(r++) = '_';
  r = SWIG_PackData(r,&ptr,sizeof(void *));
  if (strlen(name) + 1 > (bsz - (r - buff))) return 0;
  strcpy(r,name);
  return buff;
}

SWIGRUNTIME const char *
SWIG_UnpackVoidPtr(const char *c, void **ptr, const char *name) {
  if (*c != '_') {
    if (strcmp(c,"NULL") == 0) {
      *ptr = (void *) 0;
      return name;
    } else {
      return 0;
    }
  }
  return SWIG_UnpackData(++c,ptr,sizeof(void *));
}

SWIGRUNTIME char *
SWIG_PackDataName(char *buff, void *ptr, size_t sz, const char *name, size_t bsz) {
  char *r = buff;
  size_t lname = (name ? strlen(name) : 0);
  if ((2*sz + 2 + lname) > bsz) return 0;
  *(r++) = '_';
  r = SWIG_PackData(r,ptr,sz);
  if (lname) {
    strncpy(r,name,lname+1);
  } else {
    *r = 0;
  }
  return buff;
}

SWIGRUNTIME const char *
SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
  if (*c != '_') {
    if (strcmp(c,"NULL") == 0) {
      memset(ptr,0,sz);
      return name;
    } else {
      return 0;
    }
  }
  return SWIG_UnpackData(++c,ptr,sz);
}

#ifdef __cplusplus
}
#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_SystemError    	   -10
#define  SWIG_AttributeError 	   -11
#define  SWIG_MemoryError    	   -12 
#define  SWIG_NullReferenceError   -13



#ifdef __cplusplus
/* Needed on some windows machines---since MS plays funny games with the header files under C++ */
#include <math.h>
#include <stdlib.h>
extern "C" {
#endif
#include "EXTERN.h"
#include "perl.h"
#include "XSUB.h"

/* Add in functionality missing in older versions of Perl. Much of this is based on Devel-PPPort on cpan. */

/* Add PERL_REVISION, PERL_VERSION, PERL_SUBVERSION if missing */
#ifndef PERL_REVISION
#  if !defined(__PATCHLEVEL_H_INCLUDED__) && !(defined(PATCHLEVEL) && defined(SUBVERSION))
#    define PERL_PATCHLEVEL_H_IMPLICIT
#    include <patchlevel.h>
#  endif
#  if !(defined(PERL_VERSION) || (defined(SUBVERSION) && defined(PATCHLEVEL)))
#    include <could_not_find_Perl_patchlevel.h>
#  endif
#  ifndef PERL_REVISION
#    define PERL_REVISION       (5)
#    define PERL_VERSION        PATCHLEVEL
#    define PERL_SUBVERSION     SUBVERSION
#  endif
#endif

#if defined(WIN32) && defined(PERL_OBJECT) && !defined(PerlIO_exportFILE)
#define PerlIO_exportFILE(fh,fl) (FILE*)(fh)
#endif

#ifndef SvIOK_UV
# define SvIOK_UV(sv)       (SvIOK(sv) && (SvUVX(sv) == SvIVX(sv)))
#endif

#ifndef SvUOK
# define SvUOK(sv)           SvIOK_UV(sv)
#endif

#if ((PERL_VERSION < 4) || ((PERL_VERSION == 4) && (PERL_SUBVERSION <= 5)))
#  define PL_sv_undef               sv_undef
#  define PL_na	                    na
#  define PL_errgv                  errgv
#  define PL_sv_no                  sv_no
#  define PL_sv_yes                 sv_yes
#  define PL_markstack_ptr          markstack_ptr
#endif

#ifndef IVSIZE
#  ifdef LONGSIZE
#    define IVSIZE LONGSIZE
#  else
#    define IVSIZE 4 /* A bold guess, but the best we can make. */
#  endif
#endif

#ifndef INT2PTR
#  if (IVSIZE == PTRSIZE) && (UVSIZE == PTRSIZE)
#    define PTRV                  UV
#    define INT2PTR(any,d)        (any)(d)
#  else
#    if PTRSIZE == LONGSIZE
#      define PTRV                unsigned long
#    else
#      define PTRV                unsigned
#    endif
#    define INT2PTR(any,d)        (any)(PTRV)(d)
#  endif

#  define NUM2PTR(any,d)  (any)(PTRV)(d)
#  define PTR2IV(p)       INT2PTR(IV,p)
#  define PTR2UV(p)       INT2PTR(UV,p)
#  define PTR2NV(p)       NUM2PTR(NV,p)

#  if PTRSIZE == LONGSIZE
#    define PTR2ul(p)     (unsigned long)(p)
#  else
#    define PTR2ul(p)     INT2PTR(unsigned long,p)
#  endif
#endif /* !INT2PTR */

#ifndef SvPV_nolen
# define SvPV_nolen(x) SvPV(x,PL_na)
#endif

#ifndef get_sv
#  define get_sv perl_get_sv
#endif

#ifndef ERRSV
#  define ERRSV get_sv("@",FALSE)
#endif

#ifndef pTHX_
#define pTHX_
#endif   

#include <string.h>
#ifdef __cplusplus
}
#endif

/* -----------------------------------------------------------------------------
 * error manipulation
 * ----------------------------------------------------------------------------- */

SWIGINTERN const char*
SWIG_Perl_ErrorType(int code) {
  const char* type = 0;
  switch(code) {
  case SWIG_MemoryError:
    type = "MemoryError";
    break;
  case SWIG_IOError:
    type = "IOError";
    break;
  case SWIG_RuntimeError:
    type = "RuntimeError";
    break;
  case SWIG_IndexError:
    type = "IndexError";
    break;
  case SWIG_TypeError:
    type = "TypeError";
    break;
  case SWIG_DivisionByZero:
    type = "ZeroDivisionError";
    break;
  case SWIG_OverflowError:
    type = "OverflowError";
    break;
  case SWIG_SyntaxError:
    type = "SyntaxError";
    break;
  case SWIG_ValueError:
    type = "ValueError";
    break;
  case SWIG_SystemError:
    type = "SystemError";
    break;
  case SWIG_AttributeError:
    type = "AttributeError";
    break;
  default:
    type = "RuntimeError";
  }
  return type;
}




/* -----------------------------------------------------------------------------
 * perlrun.swg
 *
 * This file contains the runtime support for Perl modules
 * and includes code for managing global variables and pointer
 * type checking.
 * ----------------------------------------------------------------------------- */

#ifdef PERL_OBJECT
#define SWIG_PERL_OBJECT_DECL CPerlObj *SWIGUNUSEDPARM(pPerl),
#define SWIG_PERL_OBJECT_CALL pPerl,
#else
#define SWIG_PERL_OBJECT_DECL
#define SWIG_PERL_OBJECT_CALL
#endif

/* Common SWIG API */

/* for raw pointers */
#define SWIG_ConvertPtr(obj, pp, type, flags)           SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags)
#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own)
#define SWIG_NewPointerObj(p, type, flags)              SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags)

/* for raw packed data */
#define SWIG_ConvertPacked(obj, p, s, type)             SWIG_Perl_ConvertPacked(SWIG_PERL_OBJECT_CALL obj, p, s, type)
#define SWIG_NewPackedObj(p, s, type)	                SWIG_Perl_NewPackedObj(SWIG_PERL_OBJECT_CALL p, s, type)

/* for class or struct pointers */
#define SWIG_ConvertInstance(obj, pptr, type, flags)    SWIG_ConvertPtr(obj, pptr, type, flags)
#define SWIG_NewInstanceObj(ptr, type, flags)           SWIG_NewPointerObj(ptr, type, flags)

/* for C or C++ function pointers */
#define SWIG_ConvertFunctionPtr(obj, pptr, type)        SWIG_ConvertPtr(obj, pptr, type, 0)
#define SWIG_NewFunctionPtrObj(ptr, type)               SWIG_NewPointerObj(ptr, type, 0)

/* for C++ member pointers, ie, member methods */
#define SWIG_ConvertMember(obj, ptr, sz, ty)            SWIG_ConvertPacked(obj, ptr, sz, ty)
#define SWIG_NewMemberObj(ptr, sz, type)                SWIG_NewPackedObj(ptr, sz, type)


/* Runtime API */

#define SWIG_GetModule(clientdata)                      SWIG_Perl_GetModule()
#define SWIG_SetModule(clientdata, pointer)             SWIG_Perl_SetModule(pointer)


/* Error manipulation */

#define SWIG_ErrorType(code)                            SWIG_Perl_ErrorType(code)               
#define SWIG_Error(code, msg)            		sv_setpvf(GvSV(PL_errgv),"%s %s\n", SWIG_ErrorType(code), msg)
#define SWIG_fail                        		goto fail						    

/* Perl-specific SWIG API */

#define SWIG_MakePtr(sv, ptr, type, flags)              SWIG_Perl_MakePtr(SWIG_PERL_OBJECT_CALL sv, ptr, type, flags)
#define SWIG_MakePackedObj(sv, p, s, type)	        SWIG_Perl_MakePackedObj(SWIG_PERL_OBJECT_CALL sv, p, s, type)
#define SWIG_SetError(str)                              SWIG_Error(SWIG_RuntimeError, str)


#define SWIG_PERL_DECL_ARGS_1(arg1)                     (SWIG_PERL_OBJECT_DECL arg1)
#define SWIG_PERL_CALL_ARGS_1(arg1)                     (SWIG_PERL_OBJECT_CALL arg1)
#define SWIG_PERL_DECL_ARGS_2(arg1, arg2)               (SWIG_PERL_OBJECT_DECL arg1, arg2)
#define SWIG_PERL_CALL_ARGS_2(arg1, arg2)               (SWIG_PERL_OBJECT_CALL arg1, arg2)

/* -----------------------------------------------------------------------------
 * pointers/data manipulation
 * ----------------------------------------------------------------------------- */

/* For backward compatibility only */
#define SWIG_POINTER_EXCEPTION  0

#ifdef __cplusplus
extern "C" {
#endif

#define SWIG_OWNER   SWIG_POINTER_OWN
#define SWIG_SHADOW  SWIG_OWNER << 1

#define SWIG_MAYBE_PERL_OBJECT SWIG_PERL_OBJECT_DECL

/* SWIG Perl macros */

/* Macro to declare an XS function */
#ifndef XSPROTO
#   define XSPROTO(name) void name(pTHX_ CV* cv)
#endif

/* Macro to call an XS function */
#ifdef PERL_OBJECT 
#  define SWIG_CALLXS(_name) _name(cv,pPerl) 
#else 
#  ifndef MULTIPLICITY 
#    define SWIG_CALLXS(_name) _name(cv) 
#  else 
#    define SWIG_CALLXS(_name) _name(PERL_GET_THX, cv) 
#  endif 
#endif 

#ifdef PERL_OBJECT
#define MAGIC_PPERL  CPerlObj *pPerl = (CPerlObj *) this;

#ifdef __cplusplus
extern "C" {
#endif
typedef int (CPerlObj::*SwigMagicFunc)(SV *, MAGIC *);
#ifdef __cplusplus
}
#endif

#define SWIG_MAGIC(a,b) (SV *a, MAGIC *b)
#define SWIGCLASS_STATIC

#else /* PERL_OBJECT */

#define MAGIC_PPERL
#define SWIGCLASS_STATIC static SWIGUNUSED

#ifndef MULTIPLICITY
#define SWIG_MAGIC(a,b) (SV *a, MAGIC *b)

#ifdef __cplusplus
extern "C" {
#endif
typedef int (*SwigMagicFunc)(SV *, MAGIC *);
#ifdef __cplusplus
}
#endif

#else /* MULTIPLICITY */

#define SWIG_MAGIC(a,b) (struct interpreter *interp, SV *a, MAGIC *b)

#ifdef __cplusplus
extern "C" {
#endif
typedef int (*SwigMagicFunc)(struct interpreter *, SV *, MAGIC *);
#ifdef __cplusplus
}
#endif

#endif /* MULTIPLICITY */
#endif /* PERL_OBJECT */

/* Workaround for bug in perl 5.6.x croak and earlier */
#if (PERL_VERSION < 8)
#  ifdef PERL_OBJECT
#    define SWIG_croak_null() SWIG_Perl_croak_null(pPerl)
static void SWIG_Perl_croak_null(CPerlObj *pPerl)
#  else
static void SWIG_croak_null()
#  endif
{
  SV *err=ERRSV;
#  if (PERL_VERSION < 6)
  croak("%_", err);
#  else
  if (SvOK(err) && !SvROK(err)) croak("%_", err);
  croak(Nullch);
#  endif
}
#else
#  define SWIG_croak_null() croak(Nullch)
#endif


/* 
   Define how strict is the cast between strings and integers/doubles
   when overloading between these types occurs.
   
   The default is making it as strict as possible by using SWIG_AddCast
   when needed.
   
   You can use -DSWIG_PERL_NO_STRICT_STR2NUM at compilation time to
   disable the SWIG_AddCast, making the casting between string and
   numbers less strict.

   In the end, we try to solve the overloading between strings and
   numerical types in the more natural way, but if you can avoid it,
   well, avoid it using %rename, for example.
*/
#ifndef SWIG_PERL_NO_STRICT_STR2NUM
# ifndef SWIG_PERL_STRICT_STR2NUM
#  define SWIG_PERL_STRICT_STR2NUM
# endif
#endif
#ifdef SWIG_PERL_STRICT_STR2NUM
/* string takes precedence */
#define SWIG_Str2NumCast(x) SWIG_AddCast(x)  
#else
/* number takes precedence */
#define SWIG_Str2NumCast(x) x
#endif



#include <stdlib.h>

SWIGRUNTIME const char *
SWIG_Perl_TypeProxyName(const swig_type_info *type) {
  if (!type) return NULL;
  if (type->clientdata != NULL) {
    return (const char*) type->clientdata;
  } 
  else {
    return type->name;
  }
}

/* Identical to SWIG_TypeCheck, except for strcmp comparison */
SWIGRUNTIME swig_cast_info *
SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) {
  if (ty) {
    swig_cast_info *iter = ty->cast;
    while (iter) {
      if ( (!iter->type->clientdata && (strcmp(iter->type->name, c) == 0)) ||
            (iter->type->clientdata && (strcmp((char*)iter->type->clientdata, c) == 0)) ) {
        if (iter == ty->cast)
          return iter;
        /* Move iter to the top of the linked list */
        iter->prev->next = iter->next;
        if (iter->next)
          iter->next->prev = iter->prev;
        iter->next = ty->cast;
        iter->prev = 0;
        if (ty->cast) ty->cast->prev = iter;
        ty->cast = iter;
        return iter;
      }
      iter = iter->next;
    }
  }
  return 0;
}

/* Function for getting a pointer value */

SWIGRUNTIME int
SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) {
  swig_cast_info *tc;
  void *voidptr = (void *)0;
  SV *tsv = 0;

  if (own)
    *own = 0;

  /* If magical, apply more magic */
  if (SvGMAGICAL(sv))
    mg_get(sv);

  /* Check to see if this is an object */
  if (sv_isobject(sv)) {
    IV tmp = 0;
    tsv = (SV*) SvRV(sv);
    if ((SvTYPE(tsv) == SVt_PVHV)) {
      MAGIC *mg;
      if (SvMAGICAL(tsv)) {
        mg = mg_find(tsv,'P');
        if (mg) {
          sv = mg->mg_obj;
          if (sv_isobject(sv)) {
	    tsv = (SV*)SvRV(sv);
            tmp = SvIV(tsv);
          }
        }
      } else {
        return SWIG_ERROR;
      }
    } else {
      tmp = SvIV(tsv);
    }
    voidptr = INT2PTR(void *,tmp);
  } else if (! SvOK(sv)) {            /* Check for undef */
    *(ptr) = (void *) 0;
    return SWIG_OK;
  } else if (SvTYPE(sv) == SVt_RV) {  /* Check for NULL pointer */
    if (!SvROK(sv)) {
      *(ptr) = (void *) 0;
      return SWIG_OK;
    } else {
      return SWIG_ERROR;
    }
  } else {                            /* Don't know what it is */
    return SWIG_ERROR;
  }
  if (_t) {
    /* Now see if the types match */
    char *_c = HvNAME(SvSTASH(SvRV(sv)));
    tc = SWIG_TypeProxyCheck(_c,_t);
    if (!tc) {
      return SWIG_ERROR;
    }
    {
      int newmemory = 0;
      *ptr = SWIG_TypeCast(tc,voidptr,&newmemory);
      if (newmemory == SWIG_CAST_NEW_MEMORY) {
        assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */
        if (own)
          *own = *own | SWIG_CAST_NEW_MEMORY;
      }
    }
  } else {
    *ptr = voidptr;
  }

  /* 
   *  DISOWN implementation: we need a perl guru to check this one.
   */
  if (tsv && (flags & SWIG_POINTER_DISOWN)) {
    /* 
     *  almost copy paste code from below SWIG_POINTER_OWN setting
     */
    SV *obj = sv;
    HV *stash = SvSTASH(SvRV(obj));
    GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE);
    if (isGV(gv)) {
      HV *hv = GvHVn(gv);
      /*
       * To set ownership (see below), a newSViv(1) entry is added. 
       * Hence, to remove ownership, we delete the entry.
       */
      if (hv_exists_ent(hv, obj, 0)) {
	hv_delete_ent(hv, obj, 0, 0);
      }
    }
  }
  return SWIG_OK;
}

SWIGRUNTIME int
SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) {
  return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0);
}

SWIGRUNTIME void
SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) {
  if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) {
    SV *self;
    SV *obj=newSV(0);
    HV *hash=newHV();
    HV *stash;
    sv_setref_pv(obj, (char *) SWIG_Perl_TypeProxyName(t), ptr);
    stash=SvSTASH(SvRV(obj));
    if (flags & SWIG_POINTER_OWN) {
      HV *hv;
      GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE);
      if (!isGV(gv))
        gv_init(gv, stash, "OWNER", 5, FALSE);
      hv=GvHVn(gv);
      hv_store_ent(hv, obj, newSViv(1), 0);
    }
    sv_magic((SV *)hash, (SV *)obj, 'P', Nullch, 0);
    SvREFCNT_dec(obj);
    self=newRV_noinc((SV *)hash);
    sv_setsv(sv, self);
    SvREFCNT_dec((SV *)self);
    sv_bless(sv, stash);
  }
  else {
    sv_setref_pv(sv, (char *) SWIG_Perl_TypeProxyName(t), ptr);
  }
}

SWIGRUNTIMEINLINE SV *
SWIG_Perl_NewPointerObj(SWIG_MAYBE_PERL_OBJECT void *ptr, swig_type_info *t, int flags) {
  SV *result = sv_newmortal();
  SWIG_MakePtr(result, ptr, t, flags);
  return result;
}

SWIGRUNTIME void
SWIG_Perl_MakePackedObj(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, int sz, swig_type_info *type) {
  char result[1024];
  char *r = result;
  if ((2*sz + 1 + strlen(SWIG_Perl_TypeProxyName(type))) > 1000) return;
  *(r++) = '_';
  r = SWIG_PackData(r,ptr,sz);
  strcpy(r,SWIG_Perl_TypeProxyName(type));
  sv_setpv(sv, result);
}

SWIGRUNTIME SV *
SWIG_Perl_NewPackedObj(SWIG_MAYBE_PERL_OBJECT void *ptr, int sz, swig_type_info *type) {
  SV *result = sv_newmortal();
  SWIG_Perl_MakePackedObj(result, ptr, sz, type);
  return result;
}

/* Convert a packed value value */
SWIGRUNTIME int
SWIG_Perl_ConvertPacked(SWIG_MAYBE_PERL_OBJECT SV *obj, void *ptr, int sz, swig_type_info *ty) {
  swig_cast_info *tc;
  const char  *c = 0;

  if ((!obj) || (!SvOK(obj))) return SWIG_ERROR;
  c = SvPV_nolen(obj);
  /* Pointer values must start with leading underscore */
  if (*c != '_') return SWIG_ERROR;
  c++;
  c = SWIG_UnpackData(c,ptr,sz);
  if (ty) {
    tc = SWIG_TypeCheck(c,ty);
    if (!tc) return SWIG_ERROR;
  }
  return SWIG_OK;
}


/* Macros for low-level exception handling */
#define SWIG_croak(x)    { SWIG_Error(SWIG_RuntimeError, x); SWIG_fail; }


typedef XSPROTO(SwigPerlWrapper);
typedef SwigPerlWrapper *SwigPerlWrapperPtr;

/* Structure for command table */
typedef struct {
  const char         *name;
  SwigPerlWrapperPtr  wrapper;
} swig_command_info;

/* Information for constant table */

#define SWIG_INT     1
#define SWIG_FLOAT   2
#define SWIG_STRING  3
#define SWIG_POINTER 4
#define SWIG_BINARY  5

/* Constant information structure */
typedef struct swig_constant_info {
    int              type;
    const char      *name;
    long             lvalue;
    double           dvalue;
    void            *pvalue;
    swig_type_info **ptype;
} swig_constant_info;


/* Structure for variable table */
typedef struct {
  const char   *name;
  SwigMagicFunc   set;
  SwigMagicFunc   get;
  swig_type_info  **type;
} swig_variable_info;

/* Magic variable code */
#ifndef PERL_OBJECT
#define swig_create_magic(s,a,b,c) _swig_create_magic(s,a,b,c)
  #ifndef MULTIPLICITY
     SWIGRUNTIME void _swig_create_magic(SV *sv, char *name, int (*set)(SV *, MAGIC *), int (*get)(SV *,MAGIC *)) 
  #else
     SWIGRUNTIME void _swig_create_magic(SV *sv, char *name, int (*set)(struct interpreter*, SV *, MAGIC *), int (*get)(struct interpreter*, SV *,MAGIC *)) 
  #endif
#else
#  define swig_create_magic(s,a,b,c) _swig_create_magic(pPerl,s,a,b,c)
SWIGRUNTIME void _swig_create_magic(CPerlObj *pPerl, SV *sv, const char *name, int (CPerlObj::*set)(SV *, MAGIC *), int (CPerlObj::*get)(SV *, MAGIC *)) 
#endif
{
  MAGIC *mg;
  sv_magic(sv,sv,'U',(char *) name,strlen(name));
  mg = mg_find(sv,'U');
  mg->mg_virtual = (MGVTBL *) malloc(sizeof(MGVTBL));
  mg->mg_virtual->svt_get = (SwigMagicFunc) get;
  mg->mg_virtual->svt_set = (SwigMagicFunc) set;
  mg->mg_virtual->svt_len = 0;
  mg->mg_virtual->svt_clear = 0;
  mg->mg_virtual->svt_free = 0;
}


SWIGRUNTIME swig_module_info *
SWIG_Perl_GetModule(void) {
  static void *type_pointer = (void *)0;
  SV *pointer;

  /* first check if pointer already created */
  if (!type_pointer) {
    pointer = get_sv("swig_runtime_data::type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME, FALSE | GV_ADDMULTI);
    if (pointer && SvOK(pointer)) {
      type_pointer = INT2PTR(swig_type_info **, SvIV(pointer));
    }
  }

  return (swig_module_info *) type_pointer;
}

SWIGRUNTIME void
SWIG_Perl_SetModule(swig_module_info *module) {
  SV *pointer;

  /* create a new pointer */
  pointer = get_sv("swig_runtime_data::type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME, TRUE | GV_ADDMULTI);
  sv_setiv(pointer, PTR2IV(module));
}

#ifdef __cplusplus
}
#endif

/* Workaround perl5 global namespace pollution. Note that undefining library
 * functions like fopen will not solve the problem on all platforms as fopen
 * might be a macro on Windows but not necessarily on other operating systems. */
#ifdef do_open
  #undef do_open
#endif
#ifdef do_close
  #undef do_close
#endif
#ifdef do_exec
  #undef do_exec
#endif
#ifdef scalar
  #undef scalar
#endif
#ifdef list
  #undef list
#endif
#ifdef apply
  #undef apply
#endif
#ifdef convert
  #undef convert
#endif
#ifdef Error
  #undef Error
#endif
#ifdef form
  #undef form
#endif
#ifdef vform
  #undef vform
#endif
#ifdef LABEL
  #undef LABEL
#endif
#ifdef METHOD
  #undef METHOD
#endif
#ifdef Move
  #undef Move
#endif
#ifdef yylex
  #undef yylex
#endif
#ifdef yyparse
  #undef yyparse
#endif
#ifdef yyerror
  #undef yyerror
#endif
#ifdef invert
  #undef invert
#endif
#ifdef ref
  #undef ref
#endif
#ifdef read
  #undef read
#endif
#ifdef write
  #undef write
#endif
#ifdef eof
  #undef eof
#endif
#ifdef bool
  #undef bool
#endif
#ifdef close
  #undef close
#endif
#ifdef rewind
  #undef rewind
#endif
#ifdef free
  #undef free
#endif
#ifdef malloc
  #undef malloc
#endif
#ifdef calloc
  #undef calloc
#endif
#ifdef Stat
  #undef Stat
#endif
#ifdef check
  #undef check
#endif
#ifdef seekdir
  #undef seekdir
#endif
#ifdef open
  #undef open
#endif
#ifdef readdir
  #undef readdir
#endif
#ifdef bind
  #undef bind
#endif



#define SWIG_exception_fail(code, msg) do { SWIG_Error(code, msg); SWIG_fail; } while(0) 

#define SWIG_contract_assert(expr, msg) if (!(expr)) { SWIG_Error(SWIG_RuntimeError, msg); SWIG_fail; } else 



/* -------- TYPES TABLE (BEGIN) -------- */

#define SWIGTYPE_p_ASTNode swig_types[0]
#define SWIGTYPE_p_ASTNodeType_t swig_types[1]
#define SWIGTYPE_p_AlgebraicRule swig_types[2]
#define SWIGTYPE_p_AssignmentRule swig_types[3]
#define SWIGTYPE_p_BiolQualifierType_t swig_types[4]
#define SWIGTYPE_p_CVTerm swig_types[5]
#define SWIGTYPE_p_Compartment swig_types[6]
#define SWIGTYPE_p_CompartmentType swig_types[7]
#define SWIGTYPE_p_Constraint swig_types[8]
#define SWIGTYPE_p_Date swig_types[9]
#define SWIGTYPE_p_Delay swig_types[10]
#define SWIGTYPE_p_Event swig_types[11]
#define SWIGTYPE_p_EventAssignment swig_types[12]
#define SWIGTYPE_p_FunctionDefinition swig_types[13]
#define SWIGTYPE_p_InitialAssignment swig_types[14]
#define SWIGTYPE_p_KineticLaw swig_types[15]
#define SWIGTYPE_p_List swig_types[16]
#define SWIGTYPE_p_ListOf swig_types[17]
#define SWIGTYPE_p_ListOfCompartmentTypes swig_types[18]
#define SWIGTYPE_p_ListOfCompartments swig_types[19]
#define SWIGTYPE_p_ListOfConstraints swig_types[20]
#define SWIGTYPE_p_ListOfEventAssignments swig_types[21]
#define SWIGTYPE_p_ListOfEvents swig_types[22]
#define SWIGTYPE_p_ListOfFunctionDefinitions swig_types[23]
#define SWIGTYPE_p_ListOfInitialAssignments swig_types[24]
#define SWIGTYPE_p_ListOfLocalParameters swig_types[25]
#define SWIGTYPE_p_ListOfParameters swig_types[26]
#define SWIGTYPE_p_ListOfReactions swig_types[27]
#define SWIGTYPE_p_ListOfRules swig_types[28]
#define SWIGTYPE_p_ListOfSpecies swig_types[29]
#define SWIGTYPE_p_ListOfSpeciesReferences swig_types[30]
#define SWIGTYPE_p_ListOfSpeciesTypes swig_types[31]
#define SWIGTYPE_p_ListOfUnitDefinitions swig_types[32]
#define SWIGTYPE_p_ListOfUnits swig_types[33]
#define SWIGTYPE_p_ListWrapperT_ASTNode_t swig_types[34]
#define SWIGTYPE_p_ListWrapperT_CVTerm_t swig_types[35]
#define SWIGTYPE_p_ListWrapperT_Date_t swig_types[36]
#define SWIGTYPE_p_ListWrapperT_ModelCreator_t swig_types[37]
#define SWIGTYPE_p_ListWrapperT_SBMLNamespaces_t swig_types[38]
#define SWIGTYPE_p_LocalParameter swig_types[39]
#define SWIGTYPE_p_Model swig_types[40]
#define SWIGTYPE_p_ModelCreator swig_types[41]
#define SWIGTYPE_p_ModelHistory swig_types[42]
#define SWIGTYPE_p_ModelQualifierType_t swig_types[43]
#define SWIGTYPE_p_ModifierSpeciesReference swig_types[44]
#define SWIGTYPE_p_OFStream swig_types[45]
#define SWIGTYPE_p_OStream swig_types[46]
#define SWIGTYPE_p_OStringStream swig_types[47]
#define SWIGTYPE_p_OperationReturnValues_t swig_types[48]
#define SWIGTYPE_p_Parameter swig_types[49]
#define SWIGTYPE_p_ParentMap__iterator swig_types[50]
#define SWIGTYPE_p_Priority swig_types[51]
#define SWIGTYPE_p_QualifierType_t swig_types[52]
#define SWIGTYPE_p_RDFAnnotationParser swig_types[53]
#define SWIGTYPE_p_RateRule swig_types[54]
#define SWIGTYPE_p_Reaction swig_types[55]
#define SWIGTYPE_p_Rule swig_types[56]
#define SWIGTYPE_p_RuleType_t swig_types[57]
#define SWIGTYPE_p_SBMLConstructorException swig_types[58]
#define SWIGTYPE_p_SBMLDocument swig_types[59]
#define SWIGTYPE_p_SBMLError swig_types[60]
#define SWIGTYPE_p_SBMLErrorCategory_t swig_types[61]
#define SWIGTYPE_p_SBMLErrorCode_t swig_types[62]
#define SWIGTYPE_p_SBMLErrorLog swig_types[63]
#define SWIGTYPE_p_SBMLErrorSeverity_t swig_types[64]
#define SWIGTYPE_p_SBMLNamespaces swig_types[65]
#define SWIGTYPE_p_SBMLReader swig_types[66]
#define SWIGTYPE_p_SBMLTransforms swig_types[67]
#define SWIGTYPE_p_SBMLTypeCode_t swig_types[68]
#define SWIGTYPE_p_SBMLWriter swig_types[69]
#define SWIGTYPE_p_SBO swig_types[70]
#define SWIGTYPE_p_SBase swig_types[71]
#define SWIGTYPE_p_SimpleSpeciesReference swig_types[72]
#define SWIGTYPE_p_Species swig_types[73]
#define SWIGTYPE_p_SpeciesReference swig_types[74]
#define SWIGTYPE_p_SpeciesType swig_types[75]
#define SWIGTYPE_p_StoichiometryMath swig_types[76]
#define SWIGTYPE_p_SyntaxChecker swig_types[77]
#define SWIGTYPE_p_Trigger swig_types[78]
#define SWIGTYPE_p_Unit swig_types[79]
#define SWIGTYPE_p_UnitDefinition swig_types[80]
#define SWIGTYPE_p_UnitKind_t swig_types[81]
#define SWIGTYPE_p_XMLAttributes swig_types[82]
#define SWIGTYPE_p_XMLConstructorException swig_types[83]
#define SWIGTYPE_p_XMLError swig_types[84]
#define SWIGTYPE_p_XMLErrorCategory_t swig_types[85]
#define SWIGTYPE_p_XMLErrorCode_t swig_types[86]
#define SWIGTYPE_p_XMLErrorLog swig_types[87]
#define SWIGTYPE_p_XMLErrorSeverity_t swig_types[88]
#define SWIGTYPE_p_XMLInputStream swig_types[89]
#define SWIGTYPE_p_XMLNamespaces swig_types[90]
#define SWIGTYPE_p_XMLNode swig_types[91]
#define SWIGTYPE_p_XMLOutputFileStream swig_types[92]
#define SWIGTYPE_p_XMLOutputStream swig_types[93]
#define SWIGTYPE_p_XMLOutputStringStream swig_types[94]
#define SWIGTYPE_p_XMLToken swig_types[95]
#define SWIGTYPE_p_XMLTriple swig_types[96]
#define SWIGTYPE_p_char swig_types[97]
#define SWIGTYPE_p_std__multimapT_int_int_t swig_types[98]
#define SWIGTYPE_p_std__ostream swig_types[99]
#define SWIGTYPE_p_std__pairT_ParentMap__iterator_ParentMap__iterator_t swig_types[100]
#define SWIGTYPE_p_std__pairT_std__string_bool_t swig_types[101]
static swig_type_info *swig_types[103];
static swig_module_info swig_module = {swig_types, 102, 0, 0, 0, 0};
#define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
#define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)

/* -------- TYPES TABLE (END) -------- */

#define SWIG_init    boot_LibSBML

#define SWIG_name   "LibSBMLc::boot_LibSBML"
#define SWIG_prefix "LibSBMLc::"

#define SWIGVERSION 0x020000 
#define SWIG_VERSION SWIGVERSION


#define SWIG_as_voidptr(a) const_cast< void * >(static_cast< const void * >(a)) 
#define SWIG_as_voidptrptr(a) ((void)SWIG_as_voidptr(*a),reinterpret_cast< void** >(a)) 


#include <stdexcept>


#ifdef __cplusplus
extern "C"
#endif
#ifndef PERL_OBJECT
#ifndef MULTIPLICITY
SWIGEXPORT void SWIG_init (CV* cv);
#else
SWIGEXPORT void SWIG_init (pTHXo_ CV* cv);
#endif
#else
SWIGEXPORT void SWIG_init (CV *cv, CPerlObj *);
#endif


#include "libsbml.h"

LIBSBML_CPP_NAMESPACE_USE

#ifdef USE_LAYOUT
#include "../swig/layout.h"
#endif /* USE_LAYOUT */
#include "local.cpp"


#include <limits.h>
#if !defined(SWIG_NO_LLONG_MAX)
# if !defined(LLONG_MAX) && defined(__GNUC__) && defined (__LONG_LONG_MAX__)
#   define LLONG_MAX __LONG_LONG_MAX__
#   define LLONG_MIN (-LLONG_MAX - 1LL)
#   define ULLONG_MAX (LLONG_MAX * 2ULL + 1ULL)
# endif
#endif


SWIGINTERN int
SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val)
{
  if (SvNIOK(obj)) {
    if (val) *val = SvNV(obj);
    return SWIG_OK;
  } else if (SvIOK(obj)) {
    if (val) *val = (double) SvIV(obj);
    return SWIG_AddCast(SWIG_OK);
  } else {
    const char *nptr = SvPV_nolen(obj);
    if (nptr) {
      char *endptr;
      double v = strtod(nptr, &endptr);
      if (errno == ERANGE) {
	errno = 0;
	return SWIG_OverflowError;
      } else {
	if (*endptr == '\0') {
	  if (val) *val = v;
	  return SWIG_Str2NumCast(SWIG_OK);
	}
      }
    }
  }
  return SWIG_TypeError;
}


#include <float.h>


#include <math.h>


SWIGINTERNINLINE int
SWIG_CanCastAsInteger(double *d, double min, double max) {
  double x = *d;
  if ((min <= x && x <= max)) {
   double fx = floor(x);
   double cx = ceil(x);
   double rd =  ((x - fx) < 0.5) ? fx : cx; /* simple rint */
   if ((errno == EDOM) || (errno == ERANGE)) {
     errno = 0;
   } else {
     double summ, reps, diff;
     if (rd < x) {
       diff = x - rd;
     } else if (rd > x) {
       diff = rd - x;
     } else {
       return 1;
     }
     summ = rd + x;
     reps = diff/summ;
     if (reps < 8*DBL_EPSILON) {
       *d = rd;
       return 1;
     }
   }
  }
  return 0;
}


SWIGINTERN int
SWIG_AsVal_unsigned_SS_long SWIG_PERL_DECL_ARGS_2(SV *obj, unsigned long *val) 
{
  if (SvUOK(obj)) {
    if (val) *val = SvUV(obj);
    return SWIG_OK;
  } else  if (SvIOK(obj)) {
    long v = SvIV(obj);
    if (v >= 0) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      return SWIG_OverflowError;
    }
  } else {
    int dispatch = 0;
    const char *nptr = SvPV_nolen(obj);
    if (nptr) {
      char *endptr;
      unsigned long v;
      errno = 0;
      v = strtoul(nptr, &endptr,0);
      if (errno == ERANGE) {
	errno = 0;
	return SWIG_OverflowError;
      } else {
	if (*endptr == '\0') {
	  if (val) *val = v;
	  return SWIG_Str2NumCast(SWIG_OK);
	}
      }
    }
    if (!dispatch) {
      double d;
      int res = SWIG_AddCast(SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(obj,&d));
      if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, 0, ULONG_MAX)) {
	if (val) *val = (unsigned long)(d);
	return res;
      }
    }
  }
  return SWIG_TypeError;
}


SWIGINTERN int
SWIG_AsVal_unsigned_SS_int SWIG_PERL_DECL_ARGS_2(SV * obj, unsigned int *val)
{
  unsigned long v;
  int res = SWIG_AsVal_unsigned_SS_long SWIG_PERL_CALL_ARGS_2(obj, &v);
  if (SWIG_IsOK(res)) {
    if ((v > UINT_MAX)) {
      return SWIG_OverflowError;
    } else {
      if (val) *val = static_cast< unsigned int >(v);
    }
  }  
  return res;
}


SWIGINTERNINLINE SV *
SWIG_From_unsigned_SS_long  SWIG_PERL_DECL_ARGS_1(unsigned long value)
{    
  SV *obj = sv_newmortal();
  sv_setuv(obj, (UV) value);
  return obj;
}


SWIGINTERNINLINE SV *
SWIG_From_unsigned_SS_int  SWIG_PERL_DECL_ARGS_1(unsigned int value)
{    
  return SWIG_From_unsigned_SS_long  SWIG_PERL_CALL_ARGS_1(value);
}


#include <string>


#include <iostream>
#include <sstream>


SWIGINTERNINLINE SV *
SWIG_From_long  SWIG_PERL_DECL_ARGS_1(long value)
{    
  SV *obj = sv_newmortal();
  sv_setiv(obj, (IV) value);
  return obj;
}


SWIGINTERNINLINE SV *
SWIG_From_int  SWIG_PERL_DECL_ARGS_1(int value)
{    
  return SWIG_From_long  SWIG_PERL_CALL_ARGS_1(value);
}


SWIGINTERN int
SWIG_AsVal_long SWIG_PERL_DECL_ARGS_2(SV *obj, long* val)
{
  if (SvIOK(obj)) {
    if (val) *val = SvIV(obj);
    return SWIG_OK;
  } else {
    int dispatch = 0;
    const char *nptr = SvPV_nolen(obj);
    if (nptr) {
      char *endptr;
      long v;
      errno = 0;
      v = strtol(nptr, &endptr,0);
      if (errno == ERANGE) {
	errno = 0;
	return SWIG_OverflowError;
      } else {
	if (*endptr == '\0') {
	  if (val) *val = v;
	  return SWIG_Str2NumCast(SWIG_OK);
	}
      }
    }
    if (!dispatch) {
      double d;
      int res = SWIG_AddCast(SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(obj,&d));
      if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, LONG_MIN, LONG_MAX)) {
	if (val) *val = (long)(d);
	return res;
      }
    }
  }
  return SWIG_TypeError;
}


SWIGINTERN int
SWIG_AsVal_int SWIG_PERL_DECL_ARGS_2(SV * obj, int *val)
{
  long v;
  int res = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(obj, &v);
  if (SWIG_IsOK(res)) {
    if ((v < INT_MIN || v > INT_MAX)) {
      return SWIG_OverflowError;
    } else {
      if (val) *val = static_cast< int >(v);
    }
  }  
  return res;
}


SWIGINTERN swig_type_info*
SWIG_pchar_descriptor(void)
{
  static int init = 0;
  static swig_type_info* info = 0;
  if (!init) {
    info = SWIG_TypeQuery("_p_char");
    init = 1;
  }
  return info;
}


SWIGINTERN int
SWIG_AsCharPtrAndSize(SV *obj, char** cptr, size_t* psize, int *alloc)
{
  if (SvMAGICAL(obj)) {
     SV *tmp = sv_newmortal();
     SvSetSV(tmp, obj);
     obj = tmp;
  }
  if (SvPOK(obj)) {
    STRLEN len = 0;
    char *cstr = SvPV(obj, len); 
    size_t size = len + 1;
    if (cptr)  {
      if (alloc) {
	if (*alloc == SWIG_NEWOBJ) {
	  *cptr = reinterpret_cast< char* >(memcpy((new char[size]), cstr, sizeof(char)*(size)));
	} else {
	  *cptr = cstr;
	  *alloc = SWIG_OLDOBJ;
	}
      }
    }
    if (psize) *psize = size;
    return SWIG_OK;
  } else {
    swig_type_info* pchar_descriptor = SWIG_pchar_descriptor();
    if (pchar_descriptor) {
      char* vptr = 0; 
      if (SWIG_ConvertPtr(obj, (void**)&vptr, pchar_descriptor, 0) == SWIG_OK) {
	if (cptr) *cptr = vptr;
	if (psize) *psize = vptr ? (strlen(vptr) + 1) : 0;
	if (alloc) *alloc = SWIG_OLDOBJ;
	return SWIG_OK;
      }
    }
  }
  return SWIG_TypeError;
}


SWIGINTERN int
SWIG_AsPtr_std_string SWIG_PERL_DECL_ARGS_2(SV * obj, std::string **val) 
{
  char* buf = 0 ; size_t size = 0; int alloc = SWIG_OLDOBJ;
  if (SWIG_IsOK((SWIG_AsCharPtrAndSize(obj, &buf, &size, &alloc)))) {
    if (buf) {
      if (val) *val = new std::string(buf, size - 1);
      if (alloc == SWIG_NEWOBJ) delete[] buf;
      return SWIG_NEWOBJ;
    } else {
      if (val) *val = 0;
      return SWIG_OLDOBJ;
    }
  } else {
    static int init = 0;
    static swig_type_info* descriptor = 0;
    if (!init) {
      descriptor = SWIG_TypeQuery("std::string" " *");
      init = 1;
    }
    if (descriptor) {
      std::string *vptr;
      int res = SWIG_ConvertPtr(obj, (void**)&vptr, descriptor, 0);
      if (SWIG_IsOK(res) && val) *val = vptr;
      return res;
    }
  }
  return SWIG_ERROR;
}


SWIGINTERN int
SWIG_AsVal_bool SWIG_PERL_DECL_ARGS_2(SV *obj, bool* val)
{
  if (obj == &PL_sv_yes) {
    if (val) *val = true;
    return SWIG_OK;
  } else if (obj == &PL_sv_no) { 
    if (val) *val = false;
    return SWIG_OK;
  } else {
    if (val) *val = SvTRUE(obj) ? true: false;
    return SWIG_AddCast(SWIG_OK);    
  }
  return SWIG_TypeError;
}


SWIGINTERNINLINE SV *
SWIG_FromCharPtrAndSize(const char* carray, size_t size)
{
  SV *obj = sv_newmortal();
  if (carray) {
    sv_setpvn(obj, carray, size);
  } else {
    sv_setsv(obj, &PL_sv_undef);
  }
  return obj;
}


SWIGINTERNINLINE SV *
SWIG_From_std_string  SWIG_PERL_DECL_ARGS_1(const std::string& s)
{
  if (s.size()) {
    return SWIG_FromCharPtrAndSize(s.data(), s.size());
  } else {
    return SWIG_FromCharPtrAndSize(s.c_str(), 0);
  }
}


#include "OStream.cpp"


  /**
  * @deprecated libSBML internal
  */
  int ASTNode_true(const ASTNode *node)
  {
    return 1;
  }


SWIGINTERNINLINE SV * 
SWIG_FromCharPtr(const char *cptr)
{ 
  return SWIG_FromCharPtrAndSize(cptr, (cptr ? strlen(cptr) : 0));
}





SWIGINTERNINLINE SV *
SWIG_From_double  SWIG_PERL_DECL_ARGS_1(double value)
{    
  SV *obj = sv_newmortal();
  sv_setnv(obj, value);
  return obj;
}


SWIGINTERNINLINE SV *
SWIG_From_char  SWIG_PERL_DECL_ARGS_1(char c) 
{ 
  return SWIG_FromCharPtrAndSize(&c,1);
}


SWIGINTERN int
SWIG_AsCharArray(SV * obj, char *val, size_t size)
{ 
  char* cptr = 0; size_t csize = 0; int alloc = SWIG_OLDOBJ;
  int res = SWIG_AsCharPtrAndSize(obj, &cptr, &csize, &alloc);
  if (SWIG_IsOK(res)) {
    if ((csize == size + 1) && cptr && !(cptr[csize-1])) --csize;
    if (csize <= size) {
      if (val) {
	if (csize) memcpy(val, cptr, csize*sizeof(char));
	if (csize < size) memset(val + csize, 0, (size - csize)*sizeof(char));
      }
      if (alloc == SWIG_NEWOBJ) {
	delete[] cptr;
	res = SWIG_DelNewMask(res);
      }      
      return res;
    }
    if (alloc == SWIG_NEWOBJ) delete[] cptr;
  }
  return SWIG_TypeError;
}


SWIGINTERN int
SWIG_AsVal_char SWIG_PERL_DECL_ARGS_2(SV * obj, char *val)
{    
  int res = SWIG_AsCharArray(obj, val, 1);
  if (!SWIG_IsOK(res)) {
    long v;
    res = SWIG_AddCast(SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(obj, &v));
    if (SWIG_IsOK(res)) {
      if ((CHAR_MIN <= v) && (v <= CHAR_MAX)) {
	if (val) *val = static_cast< char >(v);
      } else {
	res = SWIG_OverflowError;
      }
    }
  }
  return res;
}

SWIGINTERN ListWrapper< ASTNode > *ASTNode_getListOfNodes(ASTNode *self){
    List *list = self->getListOfNodes(ASTNode_true);
    return new ListWrapper<ASTNode>(list);
  }
SWIGINTERN void RDFAnnotationParser_parseRDFAnnotation__SWIG_1(XMLNode const *annotation,ListWrapper< CVTerm > *CVTerms){
    if (!CVTerms) return;

    List *list = CVTerms->getList();
    RDFAnnotationParser::parseRDFAnnotation(annotation,list);
  }
#ifdef __cplusplus
extern "C" {
#endif

#ifdef PERL_OBJECT
#define MAGIC_CLASS _wrap_LibSBML_var::
class _wrap_LibSBML_var : public CPerlObj {
public:
#else
#define MAGIC_CLASS
#endif
SWIGCLASS_STATIC int swig_magic_readonly(pTHX_ SV *SWIGUNUSEDPARM(sv), MAGIC *SWIGUNUSEDPARM(mg)) {
    MAGIC_PPERL
    croak("Value is read-only.");
    return 0;
}
SWIGCLASS_STATIC int _wrap_COUT_get(pTHX_ SV *sv, MAGIC *SWIGUNUSEDPARM(mg)) {
  MAGIC_PPERL
  sv_setiv(SvRV(sv), PTR2IV(&std::cout));
  return 1;
}


SWIGCLASS_STATIC int _wrap_CERR_get(pTHX_ SV *sv, MAGIC *SWIGUNUSEDPARM(mg)) {
  MAGIC_PPERL
  sv_setiv(SvRV(sv), PTR2IV(&std::cerr));
  return 1;
}


SWIGCLASS_STATIC int _wrap_CLOG_get(pTHX_ SV *sv, MAGIC *SWIGUNUSEDPARM(mg)) {
  MAGIC_PPERL
  sv_setiv(SvRV(sv), PTR2IV(&std::clog));
  return 1;
}




#ifdef PERL_OBJECT
};
#endif

#ifdef __cplusplus
}
#endif

#ifdef __cplusplus
extern "C" {
#endif
XS(_wrap_new_ModelCreatorList) {
  {
    int argvi = 0;
    ListWrapper< ModelCreator > *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ModelCreatorList();");
    }
    result = (ListWrapper< ModelCreator > *)new ListWrapper< ModelCreator >();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListWrapperT_ModelCreator_t, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ModelCreatorList) {
  {
    ListWrapper< ModelCreator > *arg1 = (ListWrapper< ModelCreator > *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ModelCreatorList(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ModelCreator_t, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ModelCreatorList" "', argument " "1"" of type '" "ListWrapper< ModelCreator > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ModelCreator > * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreatorList_add) {
  {
    ListWrapper< ModelCreator > *arg1 = (ListWrapper< ModelCreator > *) 0 ;
    ModelCreator *arg2 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelCreatorList_add(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ModelCreator_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreatorList_add" "', argument " "1"" of type '" "ListWrapper< ModelCreator > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ModelCreator > * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ModelCreatorList_add" "', argument " "2"" of type '" "ModelCreator *""'"); 
    }
    arg2 = reinterpret_cast< ModelCreator * >(argp2);
    (arg1)->add(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreatorList_get) {
  {
    ListWrapper< ModelCreator > *arg1 = (ListWrapper< ModelCreator > *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    ModelCreator *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelCreatorList_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ModelCreator_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreatorList_get" "', argument " "1"" of type '" "ListWrapper< ModelCreator > const *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ModelCreator > * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ModelCreatorList_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (ModelCreator *)((ListWrapper< ModelCreator > const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelCreator, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreatorList_prepend) {
  {
    ListWrapper< ModelCreator > *arg1 = (ListWrapper< ModelCreator > *) 0 ;
    ModelCreator *arg2 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelCreatorList_prepend(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ModelCreator_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreatorList_prepend" "', argument " "1"" of type '" "ListWrapper< ModelCreator > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ModelCreator > * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ModelCreatorList_prepend" "', argument " "2"" of type '" "ModelCreator *""'"); 
    }
    arg2 = reinterpret_cast< ModelCreator * >(argp2);
    (arg1)->prepend(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreatorList_remove) {
  {
    ListWrapper< ModelCreator > *arg1 = (ListWrapper< ModelCreator > *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    ModelCreator *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelCreatorList_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ModelCreator_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreatorList_remove" "', argument " "1"" of type '" "ListWrapper< ModelCreator > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ModelCreator > * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ModelCreatorList_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (ModelCreator *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelCreator, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreatorList_getSize) {
  {
    ListWrapper< ModelCreator > *arg1 = (ListWrapper< ModelCreator > *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreatorList_getSize(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ModelCreator_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreatorList_getSize" "', argument " "1"" of type '" "ListWrapper< ModelCreator > const *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ModelCreator > * >(argp1);
    result = (unsigned int)((ListWrapper< ModelCreator > const *)arg1)->getSize();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_DateList) {
  {
    int argvi = 0;
    ListWrapper< Date > *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_DateList();");
    }
    result = (ListWrapper< Date > *)new ListWrapper< Date >();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListWrapperT_Date_t, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_DateList) {
  {
    ListWrapper< Date > *arg1 = (ListWrapper< Date > *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_DateList(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_Date_t, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_DateList" "', argument " "1"" of type '" "ListWrapper< Date > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< Date > * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_DateList_add) {
  {
    ListWrapper< Date > *arg1 = (ListWrapper< Date > *) 0 ;
    Date *arg2 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: DateList_add(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_Date_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "DateList_add" "', argument " "1"" of type '" "ListWrapper< Date > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< Date > * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "DateList_add" "', argument " "2"" of type '" "Date *""'"); 
    }
    arg2 = reinterpret_cast< Date * >(argp2);
    (arg1)->add(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_DateList_get) {
  {
    ListWrapper< Date > *arg1 = (ListWrapper< Date > *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: DateList_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_Date_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "DateList_get" "', argument " "1"" of type '" "ListWrapper< Date > const *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< Date > * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "DateList_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Date *)((ListWrapper< Date > const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_DateList_prepend) {
  {
    ListWrapper< Date > *arg1 = (ListWrapper< Date > *) 0 ;
    Date *arg2 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: DateList_prepend(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_Date_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "DateList_prepend" "', argument " "1"" of type '" "ListWrapper< Date > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< Date > * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "DateList_prepend" "', argument " "2"" of type '" "Date *""'"); 
    }
    arg2 = reinterpret_cast< Date * >(argp2);
    (arg1)->prepend(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_DateList_remove) {
  {
    ListWrapper< Date > *arg1 = (ListWrapper< Date > *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: DateList_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_Date_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "DateList_remove" "', argument " "1"" of type '" "ListWrapper< Date > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< Date > * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "DateList_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Date *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_DateList_getSize) {
  {
    ListWrapper< Date > *arg1 = (ListWrapper< Date > *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: DateList_getSize(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_Date_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "DateList_getSize" "', argument " "1"" of type '" "ListWrapper< Date > const *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< Date > * >(argp1);
    result = (unsigned int)((ListWrapper< Date > const *)arg1)->getSize();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_CVTermList) {
  {
    int argvi = 0;
    ListWrapper< CVTerm > *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_CVTermList();");
    }
    result = (ListWrapper< CVTerm > *)new ListWrapper< CVTerm >();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListWrapperT_CVTerm_t, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_CVTermList) {
  {
    ListWrapper< CVTerm > *arg1 = (ListWrapper< CVTerm > *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_CVTermList(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_CVTerm_t, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_CVTermList" "', argument " "1"" of type '" "ListWrapper< CVTerm > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< CVTerm > * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTermList_add) {
  {
    ListWrapper< CVTerm > *arg1 = (ListWrapper< CVTerm > *) 0 ;
    CVTerm *arg2 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CVTermList_add(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_CVTerm_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTermList_add" "', argument " "1"" of type '" "ListWrapper< CVTerm > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< CVTerm > * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "CVTermList_add" "', argument " "2"" of type '" "CVTerm *""'"); 
    }
    arg2 = reinterpret_cast< CVTerm * >(argp2);
    (arg1)->add(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTermList_get) {
  {
    ListWrapper< CVTerm > *arg1 = (ListWrapper< CVTerm > *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    CVTerm *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CVTermList_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_CVTerm_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTermList_get" "', argument " "1"" of type '" "ListWrapper< CVTerm > const *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< CVTerm > * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "CVTermList_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (CVTerm *)((ListWrapper< CVTerm > const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CVTerm, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTermList_prepend) {
  {
    ListWrapper< CVTerm > *arg1 = (ListWrapper< CVTerm > *) 0 ;
    CVTerm *arg2 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CVTermList_prepend(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_CVTerm_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTermList_prepend" "', argument " "1"" of type '" "ListWrapper< CVTerm > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< CVTerm > * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "CVTermList_prepend" "', argument " "2"" of type '" "CVTerm *""'"); 
    }
    arg2 = reinterpret_cast< CVTerm * >(argp2);
    (arg1)->prepend(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTermList_remove) {
  {
    ListWrapper< CVTerm > *arg1 = (ListWrapper< CVTerm > *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    CVTerm *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CVTermList_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_CVTerm_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTermList_remove" "', argument " "1"" of type '" "ListWrapper< CVTerm > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< CVTerm > * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "CVTermList_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (CVTerm *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CVTerm, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTermList_getSize) {
  {
    ListWrapper< CVTerm > *arg1 = (ListWrapper< CVTerm > *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CVTermList_getSize(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_CVTerm_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTermList_getSize" "', argument " "1"" of type '" "ListWrapper< CVTerm > const *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< CVTerm > * >(argp1);
    result = (unsigned int)((ListWrapper< CVTerm > const *)arg1)->getSize();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ASTNodeList) {
  {
    int argvi = 0;
    ListWrapper< ASTNode > *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ASTNodeList();");
    }
    result = (ListWrapper< ASTNode > *)new ListWrapper< ASTNode >();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListWrapperT_ASTNode_t, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ASTNodeList) {
  {
    ListWrapper< ASTNode > *arg1 = (ListWrapper< ASTNode > *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ASTNodeList(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ASTNode_t, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ASTNodeList" "', argument " "1"" of type '" "ListWrapper< ASTNode > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ASTNode > * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNodeList_add) {
  {
    ListWrapper< ASTNode > *arg1 = (ListWrapper< ASTNode > *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNodeList_add(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ASTNode_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNodeList_add" "', argument " "1"" of type '" "ListWrapper< ASTNode > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ASTNode > * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ASTNodeList_add" "', argument " "2"" of type '" "ASTNode *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    (arg1)->add(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNodeList_get) {
  {
    ListWrapper< ASTNode > *arg1 = (ListWrapper< ASTNode > *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNodeList_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ASTNode_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNodeList_get" "', argument " "1"" of type '" "ListWrapper< ASTNode > const *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ASTNode > * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNodeList_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (ASTNode *)((ListWrapper< ASTNode > const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNodeList_prepend) {
  {
    ListWrapper< ASTNode > *arg1 = (ListWrapper< ASTNode > *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNodeList_prepend(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ASTNode_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNodeList_prepend" "', argument " "1"" of type '" "ListWrapper< ASTNode > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ASTNode > * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ASTNodeList_prepend" "', argument " "2"" of type '" "ASTNode *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    (arg1)->prepend(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNodeList_remove) {
  {
    ListWrapper< ASTNode > *arg1 = (ListWrapper< ASTNode > *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNodeList_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ASTNode_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNodeList_remove" "', argument " "1"" of type '" "ListWrapper< ASTNode > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ASTNode > * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNodeList_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (ASTNode *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNodeList_getSize) {
  {
    ListWrapper< ASTNode > *arg1 = (ListWrapper< ASTNode > *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNodeList_getSize(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_ASTNode_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNodeList_getSize" "', argument " "1"" of type '" "ListWrapper< ASTNode > const *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< ASTNode > * >(argp1);
    result = (unsigned int)((ListWrapper< ASTNode > const *)arg1)->getSize();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLNamespacesList) {
  {
    int argvi = 0;
    ListWrapper< SBMLNamespaces > *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_SBMLNamespacesList();");
    }
    result = (ListWrapper< SBMLNamespaces > *)new ListWrapper< SBMLNamespaces >();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListWrapperT_SBMLNamespaces_t, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SBMLNamespacesList) {
  {
    ListWrapper< SBMLNamespaces > *arg1 = (ListWrapper< SBMLNamespaces > *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SBMLNamespacesList(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_SBMLNamespaces_t, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SBMLNamespacesList" "', argument " "1"" of type '" "ListWrapper< SBMLNamespaces > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< SBMLNamespaces > * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespacesList_add) {
  {
    ListWrapper< SBMLNamespaces > *arg1 = (ListWrapper< SBMLNamespaces > *) 0 ;
    SBMLNamespaces *arg2 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLNamespacesList_add(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_SBMLNamespaces_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespacesList_add" "', argument " "1"" of type '" "ListWrapper< SBMLNamespaces > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< SBMLNamespaces > * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLNamespacesList_add" "', argument " "2"" of type '" "SBMLNamespaces *""'"); 
    }
    arg2 = reinterpret_cast< SBMLNamespaces * >(argp2);
    (arg1)->add(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespacesList_get) {
  {
    ListWrapper< SBMLNamespaces > *arg1 = (ListWrapper< SBMLNamespaces > *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SBMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLNamespacesList_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_SBMLNamespaces_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespacesList_get" "', argument " "1"" of type '" "ListWrapper< SBMLNamespaces > const *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< SBMLNamespaces > * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBMLNamespacesList_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SBMLNamespaces *)((ListWrapper< SBMLNamespaces > const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLNamespaces, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespacesList_prepend) {
  {
    ListWrapper< SBMLNamespaces > *arg1 = (ListWrapper< SBMLNamespaces > *) 0 ;
    SBMLNamespaces *arg2 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLNamespacesList_prepend(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_SBMLNamespaces_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespacesList_prepend" "', argument " "1"" of type '" "ListWrapper< SBMLNamespaces > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< SBMLNamespaces > * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLNamespacesList_prepend" "', argument " "2"" of type '" "SBMLNamespaces *""'"); 
    }
    arg2 = reinterpret_cast< SBMLNamespaces * >(argp2);
    (arg1)->prepend(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespacesList_remove) {
  {
    ListWrapper< SBMLNamespaces > *arg1 = (ListWrapper< SBMLNamespaces > *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SBMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLNamespacesList_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_SBMLNamespaces_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespacesList_remove" "', argument " "1"" of type '" "ListWrapper< SBMLNamespaces > *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< SBMLNamespaces > * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBMLNamespacesList_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SBMLNamespaces *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLNamespaces, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespacesList_getSize) {
  {
    ListWrapper< SBMLNamespaces > *arg1 = (ListWrapper< SBMLNamespaces > *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLNamespacesList_getSize(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListWrapperT_SBMLNamespaces_t, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespacesList_getSize" "', argument " "1"" of type '" "ListWrapper< SBMLNamespaces > const *""'"); 
    }
    arg1 = reinterpret_cast< ListWrapper< SBMLNamespaces > * >(argp1);
    result = (unsigned int)((ListWrapper< SBMLNamespaces > const *)arg1)->getSize();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_OStream__SWIG_0) {
  {
    OStream::StdOSType arg1 ;
    int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    OStream *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_OStream(sot);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_OStream" "', argument " "1"" of type '" "OStream::StdOSType""'");
    } 
    arg1 = static_cast< OStream::StdOSType >(val1);
    result = (OStream *)new OStream(arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_OStream, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_OStream__SWIG_1) {
  {
    int argvi = 0;
    OStream *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_OStream();");
    }
    result = (OStream *)new OStream();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_OStream, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_OStream) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_OStream__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_OStream__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_OStream'");
  XSRETURN(0);
}


XS(_wrap_delete_OStream) {
  {
    OStream *arg1 = (OStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_OStream(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_OStream, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_OStream" "', argument " "1"" of type '" "OStream *""'"); 
    }
    arg1 = reinterpret_cast< OStream * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_OStream_get_ostream) {
  {
    OStream *arg1 = (OStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::ostream *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: OStream_get_ostream(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_OStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "OStream_get_ostream" "', argument " "1"" of type '" "OStream *""'"); 
    }
    arg1 = reinterpret_cast< OStream * >(argp1);
    result = (std::ostream *)(arg1)->get_ostream();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__ostream, 0 | 0); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_OStream_endl) {
  {
    OStream *arg1 = (OStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: OStream_endl(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_OStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "OStream_endl" "', argument " "1"" of type '" "OStream *""'"); 
    }
    arg1 = reinterpret_cast< OStream * >(argp1);
    (arg1)->endl();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_OFStream__SWIG_0) {
  {
    std::string *arg1 = 0 ;
    bool arg2 ;
    int res1 = SWIG_OLDOBJ ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    OFStream *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_OFStream(filename,is_append);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_OFStream" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_OFStream" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_OFStream" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (OFStream *)new OFStream((std::string const &)*arg1,arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_OFStream, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_OFStream__SWIG_1) {
  {
    std::string *arg1 = 0 ;
    int res1 = SWIG_OLDOBJ ;
    int argvi = 0;
    OFStream *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_OFStream(filename);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_OFStream" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_OFStream" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    result = (OFStream *)new OFStream((std::string const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_OFStream, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    SWIG_croak_null();
  }
}


XS(_wrap_new_OFStream) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_OFStream__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_OFStream__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_OFStream'");
  XSRETURN(0);
}


XS(_wrap_delete_OFStream) {
  {
    OFStream *arg1 = (OFStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_OFStream(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_OFStream, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_OFStream" "', argument " "1"" of type '" "OFStream *""'"); 
    }
    arg1 = reinterpret_cast< OFStream * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_OFStream_open__SWIG_0) {
  {
    OFStream *arg1 = (OFStream *) 0 ;
    std::string *arg2 = 0 ;
    bool arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    bool val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: OFStream_open(self,filename,is_append);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_OFStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "OFStream_open" "', argument " "1"" of type '" "OFStream *""'"); 
    }
    arg1 = reinterpret_cast< OFStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "OFStream_open" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "OFStream_open" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "OFStream_open" "', argument " "3"" of type '" "bool""'");
    } 
    arg3 = static_cast< bool >(val3);
    (arg1)->open((std::string const &)*arg2,arg3);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    SWIG_croak_null();
  }
}


XS(_wrap_OFStream_open__SWIG_1) {
  {
    OFStream *arg1 = (OFStream *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: OFStream_open(self,filename);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_OFStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "OFStream_open" "', argument " "1"" of type '" "OFStream *""'"); 
    }
    arg1 = reinterpret_cast< OFStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "OFStream_open" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "OFStream_open" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    (arg1)->open((std::string const &)*arg2);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_OFStream_open) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_OFStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_OFStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_OFStream_open__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_OFStream_open__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'OFStream_open'");
  XSRETURN(0);
}


XS(_wrap_OFStream_close) {
  {
    OFStream *arg1 = (OFStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: OFStream_close(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_OFStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "OFStream_close" "', argument " "1"" of type '" "OFStream *""'"); 
    }
    arg1 = reinterpret_cast< OFStream * >(argp1);
    (arg1)->close();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_OFStream_is_open) {
  {
    OFStream *arg1 = (OFStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: OFStream_is_open(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_OFStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "OFStream_is_open" "', argument " "1"" of type '" "OFStream *""'"); 
    }
    arg1 = reinterpret_cast< OFStream * >(argp1);
    result = (bool)(arg1)->is_open();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_OStringStream) {
  {
    int argvi = 0;
    OStringStream *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_OStringStream();");
    }
    result = (OStringStream *)new OStringStream();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_OStringStream, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_OStringStream_str__SWIG_0) {
  {
    OStringStream *arg1 = (OStringStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: OStringStream_str(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_OStringStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "OStringStream_str" "', argument " "1"" of type '" "OStringStream *""'"); 
    }
    arg1 = reinterpret_cast< OStringStream * >(argp1);
    result = (arg1)->str();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_OStringStream_str__SWIG_1) {
  {
    OStringStream *arg1 = (OStringStream *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: OStringStream_str(self,s);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_OStringStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "OStringStream_str" "', argument " "1"" of type '" "OStringStream *""'"); 
    }
    arg1 = reinterpret_cast< OStringStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "OStringStream_str" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "OStringStream_str" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    (arg1)->str((std::string const &)*arg2);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_OStringStream_str) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_OStringStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_OStringStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_OStringStream_str__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_OStringStream_str__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'OStringStream_str'");
  XSRETURN(0);
}


XS(_wrap_delete_OStringStream) {
  {
    OStringStream *arg1 = (OStringStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_OStringStream(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_OStringStream, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_OStringStream" "', argument " "1"" of type '" "OStringStream *""'"); 
    }
    arg1 = reinterpret_cast< OStringStream * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_true) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_true(node);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_true" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (int)ASTNode_true((ASTNode const *)arg1);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_getLibSBMLVersion) {
  {
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: getLibSBMLVersion();");
    }
    result = (int)getLibSBMLVersion();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_getLibSBMLDottedVersion) {
  {
    int argvi = 0;
    char *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: getLibSBMLDottedVersion();");
    }
    result = (char *)getLibSBMLDottedVersion();
    ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_getLibSBMLVersionString) {
  {
    int argvi = 0;
    char *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: getLibSBMLVersionString();");
    }
    result = (char *)getLibSBMLVersionString();
    ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLReader) {
  {
    int argvi = 0;
    SBMLReader *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_SBMLReader();");
    }
    result = (SBMLReader *)new SBMLReader();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLReader, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SBMLReader) {
  {
    SBMLReader *arg1 = (SBMLReader *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SBMLReader(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLReader, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SBMLReader" "', argument " "1"" of type '" "SBMLReader *""'"); 
    }
    arg1 = reinterpret_cast< SBMLReader * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLReader_readSBML) {
  {
    SBMLReader *arg1 = (SBMLReader *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SBMLDocument *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLReader_readSBML(self,filename);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLReader, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLReader_readSBML" "', argument " "1"" of type '" "SBMLReader *""'"); 
    }
    arg1 = reinterpret_cast< SBMLReader * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLReader_readSBML" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBMLReader_readSBML" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SBMLDocument *)(arg1)->readSBML((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLReader_readSBMLFromFile) {
  {
    SBMLReader *arg1 = (SBMLReader *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SBMLDocument *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLReader_readSBMLFromFile(self,filename);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLReader, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLReader_readSBMLFromFile" "', argument " "1"" of type '" "SBMLReader *""'"); 
    }
    arg1 = reinterpret_cast< SBMLReader * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLReader_readSBMLFromFile" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBMLReader_readSBMLFromFile" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SBMLDocument *)(arg1)->readSBMLFromFile((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLReader_readSBMLFromString) {
  {
    SBMLReader *arg1 = (SBMLReader *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SBMLDocument *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLReader_readSBMLFromString(self,xml);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLReader, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLReader_readSBMLFromString" "', argument " "1"" of type '" "SBMLReader *""'"); 
    }
    arg1 = reinterpret_cast< SBMLReader * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLReader_readSBMLFromString" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBMLReader_readSBMLFromString" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SBMLDocument *)(arg1)->readSBMLFromString((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLReader_hasZlib) {
  {
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: SBMLReader_hasZlib();");
    }
    result = (bool)SBMLReader::hasZlib();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLReader_hasBzip2) {
  {
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: SBMLReader_hasBzip2();");
    }
    result = (bool)SBMLReader::hasBzip2();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_readSBML) {
  {
    char *arg1 = (char *) 0 ;
    int res1 ;
    char *buf1 = 0 ;
    int alloc1 = 0 ;
    int argvi = 0;
    SBMLDocument_t *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: readSBML(filename);");
    }
    res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1);
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "readSBML" "', argument " "1"" of type '" "char const *""'");
    }
    arg1 = reinterpret_cast< char * >(buf1);
    result = (SBMLDocument_t *)readSBML((char const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    XSRETURN(argvi);
  fail:
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    SWIG_croak_null();
  }
}


XS(_wrap_readSBMLFromFile) {
  {
    char *arg1 = (char *) 0 ;
    int res1 ;
    char *buf1 = 0 ;
    int alloc1 = 0 ;
    int argvi = 0;
    SBMLDocument_t *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: readSBMLFromFile(filename);");
    }
    res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1);
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "readSBMLFromFile" "', argument " "1"" of type '" "char const *""'");
    }
    arg1 = reinterpret_cast< char * >(buf1);
    result = (SBMLDocument_t *)readSBMLFromFile((char const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    XSRETURN(argvi);
  fail:
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    SWIG_croak_null();
  }
}


XS(_wrap_readSBMLFromString) {
  {
    char *arg1 = (char *) 0 ;
    int res1 ;
    char *buf1 = 0 ;
    int alloc1 = 0 ;
    int argvi = 0;
    SBMLDocument_t *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: readSBMLFromString(xml);");
    }
    res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1);
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "readSBMLFromString" "', argument " "1"" of type '" "char const *""'");
    }
    arg1 = reinterpret_cast< char * >(buf1);
    result = (SBMLDocument_t *)readSBMLFromString((char const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    XSRETURN(argvi);
  fail:
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLWriter) {
  {
    int argvi = 0;
    SBMLWriter *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_SBMLWriter();");
    }
    result = (SBMLWriter *)new SBMLWriter();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLWriter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SBMLWriter) {
  {
    SBMLWriter *arg1 = (SBMLWriter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SBMLWriter(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLWriter, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SBMLWriter" "', argument " "1"" of type '" "SBMLWriter *""'"); 
    }
    arg1 = reinterpret_cast< SBMLWriter * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLWriter_setProgramName) {
  {
    SBMLWriter *arg1 = (SBMLWriter *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLWriter_setProgramName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLWriter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLWriter_setProgramName" "', argument " "1"" of type '" "SBMLWriter *""'"); 
    }
    arg1 = reinterpret_cast< SBMLWriter * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLWriter_setProgramName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBMLWriter_setProgramName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setProgramName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLWriter_setProgramVersion) {
  {
    SBMLWriter *arg1 = (SBMLWriter *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLWriter_setProgramVersion(self,version);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLWriter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLWriter_setProgramVersion" "', argument " "1"" of type '" "SBMLWriter *""'"); 
    }
    arg1 = reinterpret_cast< SBMLWriter * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLWriter_setProgramVersion" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBMLWriter_setProgramVersion" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setProgramVersion((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLWriter_writeSBML__SWIG_0) {
  {
    SBMLWriter *arg1 = (SBMLWriter *) 0 ;
    SBMLDocument *arg2 = (SBMLDocument *) 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: SBMLWriter_writeSBML(self,d,filename);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLWriter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLWriter_writeSBML" "', argument " "1"" of type '" "SBMLWriter *""'"); 
    }
    arg1 = reinterpret_cast< SBMLWriter * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLWriter_writeSBML" "', argument " "2"" of type '" "SBMLDocument const *""'"); 
    }
    arg2 = reinterpret_cast< SBMLDocument * >(argp2);
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "SBMLWriter_writeSBML" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBMLWriter_writeSBML" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (bool)(arg1)->writeSBML((SBMLDocument const *)arg2,(std::string const &)*arg3);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLWriter_writeSBML__SWIG_1) {
  {
    SBMLWriter *arg1 = (SBMLWriter *) 0 ;
    SBMLDocument *arg2 = (SBMLDocument *) 0 ;
    std::ostream *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    void *argp3 = 0 ;
    int res3 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: SBMLWriter_writeSBML(self,d,stream);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLWriter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLWriter_writeSBML" "', argument " "1"" of type '" "SBMLWriter *""'"); 
    }
    arg1 = reinterpret_cast< SBMLWriter * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLWriter_writeSBML" "', argument " "2"" of type '" "SBMLDocument const *""'"); 
    }
    arg2 = reinterpret_cast< SBMLDocument * >(argp2);
    res3 = SWIG_ConvertPtr(ST(2), &argp3, SWIGTYPE_p_std__ostream,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "SBMLWriter_writeSBML" "', argument " "3"" of type '" "std::ostream &""'"); 
    }
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBMLWriter_writeSBML" "', argument " "3"" of type '" "std::ostream &""'"); 
    }
    arg3 = reinterpret_cast< std::ostream * >(argp3);
    result = (bool)(arg1)->writeSBML((SBMLDocument const *)arg2,*arg3);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLWriter_writeSBML) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLWriter, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_SBMLDocument, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(2), &vptr, SWIGTYPE_p_std__ostream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLWriter, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_SBMLDocument, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLWriter_writeSBML__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLWriter_writeSBML__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'SBMLWriter_writeSBML'");
  XSRETURN(0);
}


XS(_wrap_SBMLWriter_writeToString) {
  {
    SBMLWriter *arg1 = (SBMLWriter *) 0 ;
    SBMLDocument *arg2 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    char *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLWriter_writeToString(self,d);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLWriter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLWriter_writeToString" "', argument " "1"" of type '" "SBMLWriter *""'"); 
    }
    arg1 = reinterpret_cast< SBMLWriter * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLWriter_writeToString" "', argument " "2"" of type '" "SBMLDocument const *""'"); 
    }
    arg2 = reinterpret_cast< SBMLDocument * >(argp2);
    result = (char *)(arg1)->writeToString((SBMLDocument const *)arg2);
    ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
    
    
    free(result);
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLWriter_writeSBMLToFile) {
  {
    SBMLWriter *arg1 = (SBMLWriter *) 0 ;
    SBMLDocument *arg2 = (SBMLDocument *) 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: SBMLWriter_writeSBMLToFile(self,d,filename);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLWriter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLWriter_writeSBMLToFile" "', argument " "1"" of type '" "SBMLWriter *""'"); 
    }
    arg1 = reinterpret_cast< SBMLWriter * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLWriter_writeSBMLToFile" "', argument " "2"" of type '" "SBMLDocument const *""'"); 
    }
    arg2 = reinterpret_cast< SBMLDocument * >(argp2);
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "SBMLWriter_writeSBMLToFile" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBMLWriter_writeSBMLToFile" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (bool)(arg1)->writeSBMLToFile((SBMLDocument const *)arg2,(std::string const &)*arg3);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLWriter_writeSBMLToString) {
  {
    SBMLWriter *arg1 = (SBMLWriter *) 0 ;
    SBMLDocument *arg2 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    char *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLWriter_writeSBMLToString(self,d);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLWriter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLWriter_writeSBMLToString" "', argument " "1"" of type '" "SBMLWriter *""'"); 
    }
    arg1 = reinterpret_cast< SBMLWriter * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLWriter_writeSBMLToString" "', argument " "2"" of type '" "SBMLDocument const *""'"); 
    }
    arg2 = reinterpret_cast< SBMLDocument * >(argp2);
    result = (char *)(arg1)->writeSBMLToString((SBMLDocument const *)arg2);
    ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
    
    
    free(result);
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLWriter_hasZlib) {
  {
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: SBMLWriter_hasZlib();");
    }
    result = (bool)SBMLWriter::hasZlib();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLWriter_hasBzip2) {
  {
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: SBMLWriter_hasBzip2();");
    }
    result = (bool)SBMLWriter::hasBzip2();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_writeSBML) {
  {
    SBMLDocument_t *arg1 = (SBMLDocument_t *) 0 ;
    char *arg2 = (char *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 ;
    char *buf2 = 0 ;
    int alloc2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: writeSBML(d,filename);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "writeSBML" "', argument " "1"" of type '" "SBMLDocument_t const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument_t * >(argp1);
    res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "writeSBML" "', argument " "2"" of type '" "char const *""'");
    }
    arg2 = reinterpret_cast< char * >(buf2);
    result = (int)writeSBML((SBMLDocument const *)arg1,(char const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
    XSRETURN(argvi);
  fail:
    
    if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
    SWIG_croak_null();
  }
}


XS(_wrap_writeSBMLToString) {
  {
    SBMLDocument_t *arg1 = (SBMLDocument_t *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    char *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: writeSBMLToString(d);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "writeSBMLToString" "', argument " "1"" of type '" "SBMLDocument_t const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument_t * >(argp1);
    result = (char *)writeSBMLToString((SBMLDocument const *)arg1);
    ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
    
    free(result);
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_writeSBMLToFile) {
  {
    SBMLDocument_t *arg1 = (SBMLDocument_t *) 0 ;
    char *arg2 = (char *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 ;
    char *buf2 = 0 ;
    int alloc2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: writeSBMLToFile(d,filename);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "writeSBMLToFile" "', argument " "1"" of type '" "SBMLDocument_t const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument_t * >(argp1);
    res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "writeSBMLToFile" "', argument " "2"" of type '" "char const *""'");
    }
    arg2 = reinterpret_cast< char * >(buf2);
    result = (int)writeSBMLToFile((SBMLDocument const *)arg1,(char const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
    XSRETURN(argvi);
  fail:
    
    if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLTypeCode_toString) {
  {
    SBMLTypeCode_t arg1 ;
    int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    char *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLTypeCode_toString(tc);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBMLTypeCode_toString" "', argument " "1"" of type '" "SBMLTypeCode_t""'");
    } 
    arg1 = static_cast< SBMLTypeCode_t >(val1);
    result = (char *)SBMLTypeCode_toString(arg1);
    ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLConstructorException__SWIG_0) {
  {
    std::string arg1 ;
    int argvi = 0;
    SBMLConstructorException *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SBMLConstructorException(message);");
    }
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_SBMLConstructorException" "', argument " "1"" of type '" "std::string""'"); 
      }
      arg1 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (SBMLConstructorException *)new SBMLConstructorException(arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLConstructorException, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLConstructorException__SWIG_1) {
  {
    int argvi = 0;
    SBMLConstructorException *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_SBMLConstructorException();");
    }
    result = (SBMLConstructorException *)new SBMLConstructorException();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLConstructorException, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLConstructorException) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLConstructorException__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLConstructorException__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_SBMLConstructorException'");
  XSRETURN(0);
}


XS(_wrap_delete_SBMLConstructorException) {
  {
    SBMLConstructorException *arg1 = (SBMLConstructorException *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SBMLConstructorException(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLConstructorException, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SBMLConstructorException" "', argument " "1"" of type '" "SBMLConstructorException *""'"); 
    }
    arg1 = reinterpret_cast< SBMLConstructorException * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SBase) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SBase(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SBase" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_clone) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBase *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_clone" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (SBase *)((SBase const *)arg1)->clone();
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        SWIG_OWNER | SWIG_SHADOW);
      argvi++;
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getMetaId) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getMetaId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getMetaId" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (std::string *) &((SBase const *)arg1)->getMetaId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getId) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getId" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (std::string *) &((SBase const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getName) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getName" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (std::string *) &((SBase const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getNotes) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getNotes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getNotes" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (XMLNode *)(arg1)->getNotes();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getNotesString) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getNotesString(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getNotesString" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (arg1)->getNotesString();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getAnnotation) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getAnnotation(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getAnnotation" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (XMLNode *)(arg1)->getAnnotation();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getAnnotationString) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getAnnotationString(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getAnnotationString" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (arg1)->getAnnotationString();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getNamespaces) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getNamespaces(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getNamespaces" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (XMLNamespaces *)((SBase const *)arg1)->getNamespaces();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNamespaces, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getSBMLDocument__SWIG_0) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLDocument *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getSBMLDocument(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getSBMLDocument" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (SBMLDocument *)((SBase const *)arg1)->getSBMLDocument();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getSBMLDocument__SWIG_1) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLDocument *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getSBMLDocument(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getSBMLDocument" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (SBMLDocument *)(arg1)->getSBMLDocument();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getSBMLDocument) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_getSBMLDocument__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_getSBMLDocument__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'SBase_getSBMLDocument'");
  XSRETURN(0);
}


XS(_wrap_SBase_getParentSBMLObject) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBase *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getParentSBMLObject(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getParentSBMLObject" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (SBase *)(arg1)->getParentSBMLObject();
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getAncestorOfType) {
  {
    SBase *arg1 = (SBase *) 0 ;
    SBMLTypeCode_t arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SBase *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_getAncestorOfType(self,type);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getAncestorOfType" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBase_getAncestorOfType" "', argument " "2"" of type '" "SBMLTypeCode_t""'");
    } 
    arg2 = static_cast< SBMLTypeCode_t >(val2);
    result = (SBase *)(arg1)->getAncestorOfType(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getSBOTerm) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getSBOTerm(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getSBOTerm" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (int)((SBase const *)arg1)->getSBOTerm();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getSBOTermID) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getSBOTermID(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getSBOTermID" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = ((SBase const *)arg1)->getSBOTermID();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getLine) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getLine(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getLine" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (unsigned int)((SBase const *)arg1)->getLine();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getColumn) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getColumn(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getColumn" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (unsigned int)((SBase const *)arg1)->getColumn();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getModelHistory__SWIG_0) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ModelHistory *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getModelHistory(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getModelHistory" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (ModelHistory *)((SBase const *)arg1)->getModelHistory();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelHistory, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getModelHistory__SWIG_1) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ModelHistory *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getModelHistory(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getModelHistory" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (ModelHistory *)(arg1)->getModelHistory();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelHistory, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getModelHistory) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_getModelHistory__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_getModelHistory__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'SBase_getModelHistory'");
  XSRETURN(0);
}


XS(_wrap_SBase_isSetMetaId) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_isSetMetaId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_isSetMetaId" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (bool)((SBase const *)arg1)->isSetMetaId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_isSetId) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_isSetId" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (bool)((SBase const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_isSetName) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_isSetName" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (bool)((SBase const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_isSetNotes) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_isSetNotes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_isSetNotes" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (bool)((SBase const *)arg1)->isSetNotes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_isSetAnnotation) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_isSetAnnotation(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_isSetAnnotation" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (bool)((SBase const *)arg1)->isSetAnnotation();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_isSetSBOTerm) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_isSetSBOTerm(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_isSetSBOTerm" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (bool)((SBase const *)arg1)->isSetSBOTerm();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_setMetaId) {
  {
    SBase *arg1 = (SBase *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_setMetaId(self,metaid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_setMetaId" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_setMetaId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBase_setMetaId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setMetaId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_isSetModelHistory) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_isSetModelHistory(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_isSetModelHistory" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (bool)(arg1)->isSetModelHistory();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_setId) {
  {
    SBase *arg1 = (SBase *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_setId" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBase_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_setName) {
  {
    SBase *arg1 = (SBase *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_setName" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBase_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_setAnnotation__SWIG_0) {
  {
    SBase *arg1 = (SBase *) 0 ;
    XMLNode *arg2 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_setAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_setAnnotation" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_setAnnotation" "', argument " "2"" of type '" "XMLNode const *""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (int)(arg1)->setAnnotation((XMLNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_setAnnotation__SWIG_1) {
  {
    SBase *arg1 = (SBase *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_setAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_setAnnotation" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_setAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBase_setAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setAnnotation((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_setAnnotation) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_setAnnotation__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_setAnnotation__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'SBase_setAnnotation'");
  XSRETURN(0);
}


XS(_wrap_SBase_appendAnnotation__SWIG_0) {
  {
    SBase *arg1 = (SBase *) 0 ;
    XMLNode *arg2 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_appendAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_appendAnnotation" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_appendAnnotation" "', argument " "2"" of type '" "XMLNode const *""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (int)(arg1)->appendAnnotation((XMLNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_appendAnnotation__SWIG_1) {
  {
    SBase *arg1 = (SBase *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_appendAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_appendAnnotation" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_appendAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBase_appendAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->appendAnnotation((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_appendAnnotation) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_appendAnnotation__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_appendAnnotation__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'SBase_appendAnnotation'");
  XSRETURN(0);
}


XS(_wrap_SBase_setNotes__SWIG_0) {
  {
    SBase *arg1 = (SBase *) 0 ;
    XMLNode *arg2 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_setNotes(self,notes);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_setNotes" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_setNotes" "', argument " "2"" of type '" "XMLNode const *""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (int)(arg1)->setNotes((XMLNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_setNotes__SWIG_1) {
  {
    SBase *arg1 = (SBase *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_setNotes(self,notes);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_setNotes" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_setNotes" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBase_setNotes" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setNotes((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_setNotes) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_setNotes__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_setNotes__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'SBase_setNotes'");
  XSRETURN(0);
}


XS(_wrap_SBase_appendNotes__SWIG_0) {
  {
    SBase *arg1 = (SBase *) 0 ;
    XMLNode *arg2 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_appendNotes(self,notes);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_appendNotes" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_appendNotes" "', argument " "2"" of type '" "XMLNode const *""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (int)(arg1)->appendNotes((XMLNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_appendNotes__SWIG_1) {
  {
    SBase *arg1 = (SBase *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_appendNotes(self,notes);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_appendNotes" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_appendNotes" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBase_appendNotes" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->appendNotes((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_appendNotes) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_appendNotes__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_appendNotes__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'SBase_appendNotes'");
  XSRETURN(0);
}


XS(_wrap_SBase_setModelHistory) {
  {
    SBase *arg1 = (SBase *) 0 ;
    ModelHistory *arg2 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_setModelHistory(self,history);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_setModelHistory" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_setModelHistory" "', argument " "2"" of type '" "ModelHistory *""'"); 
    }
    arg2 = reinterpret_cast< ModelHistory * >(argp2);
    result = (int)(arg1)->setModelHistory(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_setSBOTerm__SWIG_0) {
  {
    SBase *arg1 = (SBase *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_setSBOTerm(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_setSBOTerm" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBase_setSBOTerm" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (int)(arg1)->setSBOTerm(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_setSBOTerm__SWIG_1) {
  {
    SBase *arg1 = (SBase *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_setSBOTerm(self,sboid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_setSBOTerm" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_setSBOTerm" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBase_setSBOTerm" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setSBOTerm((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_setSBOTerm) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_setSBOTerm__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_setSBOTerm__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'SBase_setSBOTerm'");
  XSRETURN(0);
}


XS(_wrap_SBase_setNamespaces) {
  {
    SBase *arg1 = (SBase *) 0 ;
    XMLNamespaces *arg2 = (XMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_setNamespaces(self,xmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_setNamespaces" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_setNamespaces" "', argument " "2"" of type '" "XMLNamespaces *""'"); 
    }
    arg2 = reinterpret_cast< XMLNamespaces * >(argp2);
    result = (int)(arg1)->setNamespaces(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_unsetMetaId) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_unsetMetaId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_unsetMetaId" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (int)(arg1)->unsetMetaId();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_unsetNotes) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_unsetNotes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_unsetNotes" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (int)(arg1)->unsetNotes();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_unsetAnnotation) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_unsetAnnotation(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_unsetAnnotation" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (int)(arg1)->unsetAnnotation();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_unsetSBOTerm) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_unsetSBOTerm(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_unsetSBOTerm" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (int)(arg1)->unsetSBOTerm();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_addCVTerm__SWIG_0) {
  {
    SBase *arg1 = (SBase *) 0 ;
    CVTerm *arg2 = (CVTerm *) 0 ;
    bool arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    bool val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: SBase_addCVTerm(self,term,newBag);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_addCVTerm" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_addCVTerm" "', argument " "2"" of type '" "CVTerm *""'"); 
    }
    arg2 = reinterpret_cast< CVTerm * >(argp2);
    ecode3 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "SBase_addCVTerm" "', argument " "3"" of type '" "bool""'");
    } 
    arg3 = static_cast< bool >(val3);
    result = (int)(arg1)->addCVTerm(arg2,arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_addCVTerm__SWIG_1) {
  {
    SBase *arg1 = (SBase *) 0 ;
    CVTerm *arg2 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_addCVTerm(self,term);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_addCVTerm" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_addCVTerm" "', argument " "2"" of type '" "CVTerm *""'"); 
    }
    arg2 = reinterpret_cast< CVTerm * >(argp2);
    result = (int)(arg1)->addCVTerm(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_addCVTerm) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_CVTerm, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_CVTerm, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_addCVTerm__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_addCVTerm__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'SBase_addCVTerm'");
  XSRETURN(0);
}


XS(_wrap_SBase_getCVTerms__SWIG_0) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    List *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getCVTerms(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getCVTerms" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (List *)(arg1)->getCVTerms();
    {
      ListWrapper<CVTerm> *listw = (result != 0) ? new ListWrapper<CVTerm>(result) : 0;
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(listw), 
        
        SWIGTYPE_p_ListWrapperT_CVTerm_t, 
        
        
        
        SWIG_OWNER | 0);
      argvi++;
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getCVTerms__SWIG_1) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    List *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getCVTerms(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getCVTerms" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (List *)((SBase const *)arg1)->getCVTerms();
    {
      ListWrapper<CVTerm> *listw = (result != 0) ? new ListWrapper<CVTerm>(result) : 0;
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(listw), 
        
        SWIGTYPE_p_ListWrapperT_CVTerm_t, 
        
        
        
        SWIG_OWNER | 0);
      argvi++;
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getCVTerms) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBase, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_getCVTerms__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBase_getCVTerms__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'SBase_getCVTerms'");
  XSRETURN(0);
}


XS(_wrap_SBase_getNumCVTerms) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getNumCVTerms(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getNumCVTerms" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (unsigned int)(arg1)->getNumCVTerms();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getCVTerm) {
  {
    SBase *arg1 = (SBase *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    CVTerm *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_getCVTerm(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getCVTerm" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBase_getCVTerm" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (CVTerm *)(arg1)->getCVTerm(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CVTerm, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_unsetCVTerms) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_unsetCVTerms(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_unsetCVTerms" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (int)(arg1)->unsetCVTerms();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_unsetModelHistory) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_unsetModelHistory(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_unsetModelHistory" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (int)(arg1)->unsetModelHistory();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getResourceBiologicalQualifier) {
  {
    SBase *arg1 = (SBase *) 0 ;
    std::string arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    BiolQualifierType_t result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_getResourceBiologicalQualifier(self,resource);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getResourceBiologicalQualifier" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "SBase_getResourceBiologicalQualifier" "', argument " "2"" of type '" "std::string""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (BiolQualifierType_t)(arg1)->getResourceBiologicalQualifier(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getResourceModelQualifier) {
  {
    SBase *arg1 = (SBase *) 0 ;
    std::string arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ModelQualifierType_t result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_getResourceModelQualifier(self,resource);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getResourceModelQualifier" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "SBase_getResourceModelQualifier" "', argument " "2"" of type '" "std::string""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (ModelQualifierType_t)(arg1)->getResourceModelQualifier(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getModel) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Model *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getModel(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getModel" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (Model *)((SBase const *)arg1)->getModel();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Model, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getLevel) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getLevel(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getLevel" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (unsigned int)((SBase const *)arg1)->getLevel();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getVersion) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getVersion(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getVersion" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (unsigned int)((SBase const *)arg1)->getVersion();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getTypeCode) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getTypeCode" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (SBMLTypeCode_t)((SBase const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_hasValidLevelVersionNamespaceCombination) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_hasValidLevelVersionNamespaceCombination(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_hasValidLevelVersionNamespaceCombination" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (bool)(arg1)->hasValidLevelVersionNamespaceCombination();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_getElementName) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_getElementName" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (std::string *) &((SBase const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_toSBML) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    char *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_toSBML(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_toSBML" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (char *)(arg1)->toSBML();
    ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
    
    free(result);
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_hasRequiredAttributes) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_hasRequiredAttributes" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (bool)((SBase const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_hasRequiredElements) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBase_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_hasRequiredElements" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (bool)((SBase const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBase_checkMathMLNamespace) {
  {
    SBase *arg1 = (SBase *) 0 ;
    XMLToken arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBase_checkMathMLNamespace(self,elem);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBase_checkMathMLNamespace" "', argument " "1"" of type '" "SBase *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    {
      res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLToken,  0 );
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBase_checkMathMLNamespace" "', argument " "2"" of type '" "XMLToken const""'"); 
      }  
      if (!argp2) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBase_checkMathMLNamespace" "', argument " "2"" of type '" "XMLToken const""'");
      } else {
        arg2 = *(reinterpret_cast< XMLToken * >(argp2));
      }
    }
    result = (arg1)->checkMathMLNamespace(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ListOf__SWIG_0) {
  {
    int argvi = 0;
    ListOf *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOf();");
    }
    result = (ListOf *)new ListOf();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOf, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOf) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOf(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOf" "', argument " "1"" of type '" "ListOf *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ListOf__SWIG_1) {
  {
    ListOf *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOf *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_ListOf(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_ListOf,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_ListOf" "', argument " "1"" of type '" "ListOf const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_ListOf" "', argument " "1"" of type '" "ListOf const &""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    result = (ListOf *)new ListOf((ListOf const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOf, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ListOf) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOf, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ListOf__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ListOf__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'new_ListOf'");
  XSRETURN(0);
}


XS(_wrap_ListOf_clone) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBase *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOf_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_clone" "', argument " "1"" of type '" "ListOf const *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    result = (SBase *)((ListOf const *)arg1)->clone();
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        SWIG_OWNER | SWIG_SHADOW);
      argvi++;
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOf_append) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    SBase *arg2 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOf_append(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_append" "', argument " "1"" of type '" "ListOf *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOf_append" "', argument " "2"" of type '" "SBase const *""'"); 
    }
    arg2 = reinterpret_cast< SBase * >(argp2);
    result = (int)(arg1)->append((SBase const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOf_appendAndOwn) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    SBase *arg2 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOf_appendAndOwn(self,item);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_appendAndOwn" "', argument " "1"" of type '" "ListOf *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOf_appendAndOwn" "', argument " "2"" of type '" "SBase *""'"); 
    }
    arg2 = reinterpret_cast< SBase * >(argp2);
    result = (int)(arg1)->appendAndOwn(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOf_get__SWIG_0) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SBase *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOf_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_get" "', argument " "1"" of type '" "ListOf const *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOf_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SBase *)((ListOf const *)arg1)->get(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOf_get__SWIG_1) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SBase *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOf_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_get" "', argument " "1"" of type '" "ListOf *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOf_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SBase *)(arg1)->get(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOf_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOf, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOf, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOf_get__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOf_get__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOf_get'");
  XSRETURN(0);
}


XS(_wrap_ListOf_clear__SWIG_0) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOf_clear(self,doDelete);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_clear" "', argument " "1"" of type '" "ListOf *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOf_clear" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    (arg1)->clear(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOf_clear__SWIG_1) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOf_clear(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_clear" "', argument " "1"" of type '" "ListOf *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    (arg1)->clear();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOf_clear) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOf, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOf, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOf_clear__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOf_clear__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOf_clear'");
  XSRETURN(0);
}


XS(_wrap_ListOf_remove) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SBase *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOf_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_remove" "', argument " "1"" of type '" "ListOf *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOf_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SBase *)(arg1)->remove(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        SWIG_OWNER | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOf_size) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOf_size(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_size" "', argument " "1"" of type '" "ListOf const *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    result = (unsigned int)((ListOf const *)arg1)->size();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOf_getTypeCode) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOf_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_getTypeCode" "', argument " "1"" of type '" "ListOf const *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    result = (SBMLTypeCode_t)((ListOf const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOf_getItemTypeCode) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOf_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_getItemTypeCode" "', argument " "1"" of type '" "ListOf const *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    result = (SBMLTypeCode_t)((ListOf const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOf_getElementName) {
  {
    ListOf *arg1 = (ListOf *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOf_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOf, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOf_getElementName" "', argument " "1"" of type '" "ListOf const *""'"); 
    }
    arg1 = reinterpret_cast< ListOf * >(argp1);
    result = (std::string *) &((ListOf const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Model__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Model *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Model(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Model" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Model" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (Model *)new Model(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Model, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Model__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Model *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Model(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Model" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (Model *)new Model(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Model, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Model) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Model(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Model" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Model__SWIG_2) {
  {
    Model *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Model *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Model(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Model,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Model" "', argument " "1"" of type '" "Model const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Model" "', argument " "1"" of type '" "Model const &""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      try {
        result = (Model *)new Model((Model const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Model, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Model) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Model__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Model__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Model__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Model'");
  XSRETURN(0);
}


XS(_wrap_Model_clone) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Model *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_clone" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (Model *)((Model const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Model, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getId) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getId" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (std::string *) &((Model const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getName) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getName" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (std::string *) &((Model const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getSubstanceUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getSubstanceUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getSubstanceUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (std::string *) &((Model const *)arg1)->getSubstanceUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getTimeUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getTimeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getTimeUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (std::string *) &((Model const *)arg1)->getTimeUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getVolumeUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getVolumeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getVolumeUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (std::string *) &((Model const *)arg1)->getVolumeUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getAreaUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getAreaUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getAreaUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (std::string *) &((Model const *)arg1)->getAreaUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getLengthUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getLengthUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getLengthUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (std::string *) &((Model const *)arg1)->getLengthUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getExtentUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getExtentUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getExtentUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (std::string *) &((Model const *)arg1)->getExtentUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getConversionFactor) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getConversionFactor(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getConversionFactor" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (std::string *) &((Model const *)arg1)->getConversionFactor();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_isSetId) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_isSetId" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (bool)((Model const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_isSetName) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_isSetName" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (bool)((Model const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_isSetSubstanceUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_isSetSubstanceUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_isSetSubstanceUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (bool)((Model const *)arg1)->isSetSubstanceUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_isSetTimeUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_isSetTimeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_isSetTimeUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (bool)((Model const *)arg1)->isSetTimeUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_isSetVolumeUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_isSetVolumeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_isSetVolumeUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (bool)((Model const *)arg1)->isSetVolumeUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_isSetAreaUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_isSetAreaUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_isSetAreaUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (bool)((Model const *)arg1)->isSetAreaUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_isSetLengthUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_isSetLengthUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_isSetLengthUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (bool)((Model const *)arg1)->isSetLengthUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_isSetExtentUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_isSetExtentUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_isSetExtentUnits" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (bool)((Model const *)arg1)->isSetExtentUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_isSetConversionFactor) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_isSetConversionFactor(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_isSetConversionFactor" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (bool)((Model const *)arg1)->isSetConversionFactor();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setId) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setId" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setName) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setName" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setSubstanceUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setSubstanceUnits(self,units);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setSubstanceUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_setSubstanceUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_setSubstanceUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setSubstanceUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setTimeUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setTimeUnits(self,units);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setTimeUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_setTimeUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_setTimeUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setTimeUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setVolumeUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setVolumeUnits(self,units);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setVolumeUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_setVolumeUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_setVolumeUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setVolumeUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setAreaUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setAreaUnits(self,units);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setAreaUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_setAreaUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_setAreaUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setAreaUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setLengthUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setLengthUnits(self,units);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setLengthUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_setLengthUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_setLengthUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setLengthUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setExtentUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setExtentUnits(self,units);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setExtentUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_setExtentUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_setExtentUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setExtentUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setConversionFactor) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setConversionFactor(self,units);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setConversionFactor" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_setConversionFactor" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_setConversionFactor" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setConversionFactor((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_unsetId) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_unsetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_unsetId" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (int)(arg1)->unsetId();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_unsetName) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_unsetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_unsetName" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (int)(arg1)->unsetName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_unsetSubstanceUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_unsetSubstanceUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_unsetSubstanceUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (int)(arg1)->unsetSubstanceUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_unsetTimeUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_unsetTimeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_unsetTimeUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (int)(arg1)->unsetTimeUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_unsetVolumeUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_unsetVolumeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_unsetVolumeUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (int)(arg1)->unsetVolumeUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_unsetAreaUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_unsetAreaUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_unsetAreaUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (int)(arg1)->unsetAreaUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_unsetLengthUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_unsetLengthUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_unsetLengthUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (int)(arg1)->unsetLengthUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_unsetExtentUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_unsetExtentUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_unsetExtentUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (int)(arg1)->unsetExtentUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_unsetConversionFactor) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_unsetConversionFactor(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_unsetConversionFactor" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (int)(arg1)->unsetConversionFactor();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addFunctionDefinition) {
  {
    Model *arg1 = (Model *) 0 ;
    FunctionDefinition *arg2 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addFunctionDefinition(self,fd);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addFunctionDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addFunctionDefinition" "', argument " "2"" of type '" "FunctionDefinition const *""'"); 
    }
    arg2 = reinterpret_cast< FunctionDefinition * >(argp2);
    result = (int)(arg1)->addFunctionDefinition((FunctionDefinition const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addUnitDefinition) {
  {
    Model *arg1 = (Model *) 0 ;
    UnitDefinition *arg2 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addUnitDefinition(self,ud);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addUnitDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addUnitDefinition" "', argument " "2"" of type '" "UnitDefinition const *""'"); 
    }
    arg2 = reinterpret_cast< UnitDefinition * >(argp2);
    result = (int)(arg1)->addUnitDefinition((UnitDefinition const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addCompartmentType) {
  {
    Model *arg1 = (Model *) 0 ;
    CompartmentType *arg2 = (CompartmentType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addCompartmentType(self,ct);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addCompartmentType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addCompartmentType" "', argument " "2"" of type '" "CompartmentType const *""'"); 
    }
    arg2 = reinterpret_cast< CompartmentType * >(argp2);
    result = (int)(arg1)->addCompartmentType((CompartmentType const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addSpeciesType) {
  {
    Model *arg1 = (Model *) 0 ;
    SpeciesType *arg2 = (SpeciesType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addSpeciesType(self,st);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addSpeciesType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addSpeciesType" "', argument " "2"" of type '" "SpeciesType const *""'"); 
    }
    arg2 = reinterpret_cast< SpeciesType * >(argp2);
    result = (int)(arg1)->addSpeciesType((SpeciesType const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addCompartment) {
  {
    Model *arg1 = (Model *) 0 ;
    Compartment *arg2 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addCompartment(self,c);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addCompartment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addCompartment" "', argument " "2"" of type '" "Compartment const *""'"); 
    }
    arg2 = reinterpret_cast< Compartment * >(argp2);
    result = (int)(arg1)->addCompartment((Compartment const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addSpecies) {
  {
    Model *arg1 = (Model *) 0 ;
    Species *arg2 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addSpecies(self,s);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addSpecies" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addSpecies" "', argument " "2"" of type '" "Species const *""'"); 
    }
    arg2 = reinterpret_cast< Species * >(argp2);
    result = (int)(arg1)->addSpecies((Species const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addParameter) {
  {
    Model *arg1 = (Model *) 0 ;
    Parameter *arg2 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addParameter(self,p);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addParameter" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addParameter" "', argument " "2"" of type '" "Parameter const *""'"); 
    }
    arg2 = reinterpret_cast< Parameter * >(argp2);
    result = (int)(arg1)->addParameter((Parameter const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addInitialAssignment) {
  {
    Model *arg1 = (Model *) 0 ;
    InitialAssignment *arg2 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addInitialAssignment(self,ia);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addInitialAssignment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addInitialAssignment" "', argument " "2"" of type '" "InitialAssignment const *""'"); 
    }
    arg2 = reinterpret_cast< InitialAssignment * >(argp2);
    result = (int)(arg1)->addInitialAssignment((InitialAssignment const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addRule) {
  {
    Model *arg1 = (Model *) 0 ;
    Rule *arg2 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addRule(self,r);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addRule" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addRule" "', argument " "2"" of type '" "Rule const *""'"); 
    }
    arg2 = reinterpret_cast< Rule * >(argp2);
    result = (int)(arg1)->addRule((Rule const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addConstraint) {
  {
    Model *arg1 = (Model *) 0 ;
    Constraint *arg2 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addConstraint(self,c);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addConstraint" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addConstraint" "', argument " "2"" of type '" "Constraint const *""'"); 
    }
    arg2 = reinterpret_cast< Constraint * >(argp2);
    result = (int)(arg1)->addConstraint((Constraint const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addReaction) {
  {
    Model *arg1 = (Model *) 0 ;
    Reaction *arg2 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addReaction(self,r);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addReaction" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addReaction" "', argument " "2"" of type '" "Reaction const *""'"); 
    }
    arg2 = reinterpret_cast< Reaction * >(argp2);
    result = (int)(arg1)->addReaction((Reaction const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addEvent) {
  {
    Model *arg1 = (Model *) 0 ;
    Event *arg2 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_addEvent(self,e);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addEvent" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_addEvent" "', argument " "2"" of type '" "Event const *""'"); 
    }
    arg2 = reinterpret_cast< Event * >(argp2);
    result = (int)(arg1)->addEvent((Event const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createFunctionDefinition) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createFunctionDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createFunctionDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (FunctionDefinition *)(arg1)->createFunctionDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createUnitDefinition) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createUnitDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (UnitDefinition *)(arg1)->createUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createUnit) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createUnit(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createUnit" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (Unit *)(arg1)->createUnit();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createCompartmentType) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createCompartmentType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createCompartmentType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (CompartmentType *)(arg1)->createCompartmentType();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createSpeciesType) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createSpeciesType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createSpeciesType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (SpeciesType *)(arg1)->createSpeciesType();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createCompartment) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createCompartment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createCompartment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (Compartment *)(arg1)->createCompartment();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createSpecies) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createSpecies(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createSpecies" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (Species *)(arg1)->createSpecies();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createParameter) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createParameter(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createParameter" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (Parameter *)(arg1)->createParameter();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createInitialAssignment) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createInitialAssignment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createInitialAssignment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (InitialAssignment *)(arg1)->createInitialAssignment();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createAlgebraicRule) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    AlgebraicRule *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createAlgebraicRule(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createAlgebraicRule" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (AlgebraicRule *)(arg1)->createAlgebraicRule();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_AlgebraicRule, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createAssignmentRule) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    AssignmentRule *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createAssignmentRule(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createAssignmentRule" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (AssignmentRule *)(arg1)->createAssignmentRule();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_AssignmentRule, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createRateRule) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    RateRule *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createRateRule(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createRateRule" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (RateRule *)(arg1)->createRateRule();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_RateRule, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createConstraint) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Constraint *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createConstraint(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createConstraint" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (Constraint *)(arg1)->createConstraint();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Constraint, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createReaction) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createReaction(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createReaction" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (Reaction *)(arg1)->createReaction();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createReactant) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createReactant(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createReactant" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (SpeciesReference *)(arg1)->createReactant();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createProduct) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createProduct(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createProduct" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (SpeciesReference *)(arg1)->createProduct();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createModifier) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ModifierSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createModifier(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createModifier" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ModifierSpeciesReference *)(arg1)->createModifier();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModifierSpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createKineticLaw) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    KineticLaw *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createKineticLaw(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createKineticLaw" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (KineticLaw *)(arg1)->createKineticLaw();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_KineticLaw, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createKineticLawParameter) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createKineticLawParameter(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createKineticLawParameter" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (Parameter *)(arg1)->createKineticLawParameter();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createKineticLawLocalParameter) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createKineticLawLocalParameter(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createKineticLawLocalParameter" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (LocalParameter *)(arg1)->createKineticLawLocalParameter();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createEvent) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createEvent(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createEvent" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (Event *)(arg1)->createEvent();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createEventAssignment) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createEventAssignment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createEventAssignment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (EventAssignment *)(arg1)->createEventAssignment();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createTrigger) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Trigger *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createTrigger(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createTrigger" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (Trigger *)(arg1)->createTrigger();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Trigger, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_createDelay) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Delay *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_createDelay(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_createDelay" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (Delay *)(arg1)->createDelay();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Delay, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setAnnotation__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    XMLNode *arg2 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setAnnotation" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_setAnnotation" "', argument " "2"" of type '" "XMLNode const *""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (int)(arg1)->setAnnotation((XMLNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setAnnotation__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setAnnotation" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_setAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_setAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setAnnotation((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setAnnotation) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_setAnnotation__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_setAnnotation__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_setAnnotation'");
  XSRETURN(0);
}


XS(_wrap_Model_appendAnnotation__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    XMLNode *arg2 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_appendAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_appendAnnotation" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_appendAnnotation" "', argument " "2"" of type '" "XMLNode const *""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (int)(arg1)->appendAnnotation((XMLNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_appendAnnotation__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_appendAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_appendAnnotation" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_appendAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_appendAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->appendAnnotation((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_appendAnnotation) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_appendAnnotation__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_appendAnnotation__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_appendAnnotation'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfFunctionDefinitions__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfFunctionDefinitions *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfFunctionDefinitions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfFunctionDefinitions" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfFunctionDefinitions *)((Model const *)arg1)->getListOfFunctionDefinitions();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfFunctionDefinitions, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfFunctionDefinitions__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfFunctionDefinitions *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfFunctionDefinitions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfFunctionDefinitions" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfFunctionDefinitions *)(arg1)->getListOfFunctionDefinitions();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfFunctionDefinitions, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfFunctionDefinitions) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfFunctionDefinitions__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfFunctionDefinitions__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfFunctionDefinitions'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfUnitDefinitions__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfUnitDefinitions *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfUnitDefinitions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfUnitDefinitions" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfUnitDefinitions *)((Model const *)arg1)->getListOfUnitDefinitions();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfUnitDefinitions, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfUnitDefinitions__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfUnitDefinitions *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfUnitDefinitions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfUnitDefinitions" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfUnitDefinitions *)(arg1)->getListOfUnitDefinitions();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfUnitDefinitions, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfUnitDefinitions) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfUnitDefinitions__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfUnitDefinitions__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfUnitDefinitions'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfCompartmentTypes__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfCompartmentTypes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfCompartmentTypes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfCompartmentTypes" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfCompartmentTypes *)((Model const *)arg1)->getListOfCompartmentTypes();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfCompartmentTypes, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfCompartmentTypes__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfCompartmentTypes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfCompartmentTypes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfCompartmentTypes" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfCompartmentTypes *)(arg1)->getListOfCompartmentTypes();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfCompartmentTypes, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfCompartmentTypes) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfCompartmentTypes__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfCompartmentTypes__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfCompartmentTypes'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfSpeciesTypes__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpeciesTypes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfSpeciesTypes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfSpeciesTypes" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfSpeciesTypes *)((Model const *)arg1)->getListOfSpeciesTypes();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesTypes, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfSpeciesTypes__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpeciesTypes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfSpeciesTypes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfSpeciesTypes" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfSpeciesTypes *)(arg1)->getListOfSpeciesTypes();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesTypes, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfSpeciesTypes) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfSpeciesTypes__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfSpeciesTypes__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfSpeciesTypes'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfCompartments__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfCompartments *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfCompartments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfCompartments" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfCompartments *)((Model const *)arg1)->getListOfCompartments();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfCompartments, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfCompartments__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfCompartments *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfCompartments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfCompartments" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfCompartments *)(arg1)->getListOfCompartments();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfCompartments, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfCompartments) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfCompartments__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfCompartments__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfCompartments'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfSpecies__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpecies *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfSpecies(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfSpecies" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfSpecies *)((Model const *)arg1)->getListOfSpecies();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpecies, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfSpecies__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpecies *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfSpecies(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfSpecies" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfSpecies *)(arg1)->getListOfSpecies();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpecies, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfSpecies) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfSpecies__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfSpecies__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfSpecies'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfParameters__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfParameters *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfParameters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfParameters" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfParameters *)((Model const *)arg1)->getListOfParameters();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfParameters, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfParameters__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfParameters *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfParameters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfParameters" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfParameters *)(arg1)->getListOfParameters();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfParameters, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfParameters) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfParameters__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfParameters__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfParameters'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfInitialAssignments__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfInitialAssignments *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfInitialAssignments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfInitialAssignments" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfInitialAssignments *)((Model const *)arg1)->getListOfInitialAssignments();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfInitialAssignments, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfInitialAssignments__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfInitialAssignments *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfInitialAssignments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfInitialAssignments" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfInitialAssignments *)(arg1)->getListOfInitialAssignments();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfInitialAssignments, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfInitialAssignments) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfInitialAssignments__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfInitialAssignments__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfInitialAssignments'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfRules__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfRules *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfRules(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfRules" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfRules *)((Model const *)arg1)->getListOfRules();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfRules, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfRules__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfRules *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfRules(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfRules" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfRules *)(arg1)->getListOfRules();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfRules, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfRules) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfRules__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfRules__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfRules'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfConstraints__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfConstraints *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfConstraints(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfConstraints" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfConstraints *)((Model const *)arg1)->getListOfConstraints();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfConstraints, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfConstraints__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfConstraints *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfConstraints(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfConstraints" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfConstraints *)(arg1)->getListOfConstraints();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfConstraints, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfConstraints) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfConstraints__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfConstraints__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfConstraints'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfReactions__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfReactions *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfReactions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfReactions" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfReactions *)((Model const *)arg1)->getListOfReactions();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfReactions, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfReactions__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfReactions *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfReactions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfReactions" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfReactions *)(arg1)->getListOfReactions();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfReactions, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfReactions) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfReactions__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfReactions__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfReactions'");
  XSRETURN(0);
}


XS(_wrap_Model_getListOfEvents__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfEvents *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfEvents(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfEvents" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfEvents *)((Model const *)arg1)->getListOfEvents();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfEvents, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfEvents__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfEvents *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getListOfEvents(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getListOfEvents" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (ListOfEvents *)(arg1)->getListOfEvents();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfEvents, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getListOfEvents) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfEvents__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getListOfEvents__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getListOfEvents'");
  XSRETURN(0);
}


XS(_wrap_Model_getFunctionDefinition__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getFunctionDefinition(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getFunctionDefinition" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getFunctionDefinition" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (FunctionDefinition *)((Model const *)arg1)->getFunctionDefinition(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getFunctionDefinition__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getFunctionDefinition(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getFunctionDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getFunctionDefinition" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (FunctionDefinition *)(arg1)->getFunctionDefinition(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getFunctionDefinition__SWIG_2) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getFunctionDefinition(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getFunctionDefinition" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getFunctionDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getFunctionDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (FunctionDefinition *)((Model const *)arg1)->getFunctionDefinition((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getFunctionDefinition__SWIG_3) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getFunctionDefinition(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getFunctionDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getFunctionDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getFunctionDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (FunctionDefinition *)(arg1)->getFunctionDefinition((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getFunctionDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getFunctionDefinition__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getFunctionDefinition__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getFunctionDefinition__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getFunctionDefinition__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getFunctionDefinition'");
  XSRETURN(0);
}


XS(_wrap_Model_getUnitDefinition__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getUnitDefinition(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getUnitDefinition" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getUnitDefinition" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (UnitDefinition *)((Model const *)arg1)->getUnitDefinition(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getUnitDefinition__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getUnitDefinition(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getUnitDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getUnitDefinition" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (UnitDefinition *)(arg1)->getUnitDefinition(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getUnitDefinition__SWIG_2) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getUnitDefinition(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getUnitDefinition" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getUnitDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getUnitDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (UnitDefinition *)((Model const *)arg1)->getUnitDefinition((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getUnitDefinition__SWIG_3) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getUnitDefinition(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getUnitDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getUnitDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getUnitDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (UnitDefinition *)(arg1)->getUnitDefinition((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getUnitDefinition__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getUnitDefinition__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getUnitDefinition__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getUnitDefinition__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_Model_getCompartmentType__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getCompartmentType(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getCompartmentType" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getCompartmentType" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (CompartmentType *)((Model const *)arg1)->getCompartmentType(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getCompartmentType__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getCompartmentType(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getCompartmentType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getCompartmentType" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (CompartmentType *)(arg1)->getCompartmentType(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getCompartmentType__SWIG_2) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getCompartmentType(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getCompartmentType" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getCompartmentType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getCompartmentType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (CompartmentType *)((Model const *)arg1)->getCompartmentType((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getCompartmentType__SWIG_3) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getCompartmentType(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getCompartmentType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getCompartmentType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getCompartmentType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (CompartmentType *)(arg1)->getCompartmentType((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getCompartmentType) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getCompartmentType__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getCompartmentType__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getCompartmentType__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getCompartmentType__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getCompartmentType'");
  XSRETURN(0);
}


XS(_wrap_Model_getSpeciesType__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getSpeciesType(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getSpeciesType" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getSpeciesType" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesType *)((Model const *)arg1)->getSpeciesType(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getSpeciesType__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getSpeciesType(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getSpeciesType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getSpeciesType" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesType *)(arg1)->getSpeciesType(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getSpeciesType__SWIG_2) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getSpeciesType(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getSpeciesType" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getSpeciesType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getSpeciesType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesType *)((Model const *)arg1)->getSpeciesType((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getSpeciesType__SWIG_3) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getSpeciesType(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getSpeciesType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getSpeciesType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getSpeciesType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesType *)(arg1)->getSpeciesType((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getSpeciesType) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getSpeciesType__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getSpeciesType__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getSpeciesType__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getSpeciesType__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getSpeciesType'");
  XSRETURN(0);
}


XS(_wrap_Model_getCompartment__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getCompartment(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getCompartment" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getCompartment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Compartment *)((Model const *)arg1)->getCompartment(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getCompartment__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getCompartment(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getCompartment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getCompartment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Compartment *)(arg1)->getCompartment(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getCompartment__SWIG_2) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getCompartment(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getCompartment" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getCompartment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getCompartment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Compartment *)((Model const *)arg1)->getCompartment((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getCompartment__SWIG_3) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getCompartment(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getCompartment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getCompartment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getCompartment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Compartment *)(arg1)->getCompartment((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getCompartment) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getCompartment__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getCompartment__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getCompartment__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getCompartment__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getCompartment'");
  XSRETURN(0);
}


XS(_wrap_Model_getSpecies__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getSpecies(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getSpecies" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getSpecies" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Species *)((Model const *)arg1)->getSpecies(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getSpecies__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getSpecies(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getSpecies" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getSpecies" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Species *)(arg1)->getSpecies(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getSpecies__SWIG_2) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getSpecies(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getSpecies" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getSpecies" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getSpecies" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Species *)((Model const *)arg1)->getSpecies((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getSpecies__SWIG_3) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getSpecies(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getSpecies" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getSpecies" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getSpecies" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Species *)(arg1)->getSpecies((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getSpecies) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getSpecies__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getSpecies__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getSpecies__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getSpecies__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getSpecies'");
  XSRETURN(0);
}


XS(_wrap_Model_getParameter__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getParameter(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getParameter" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getParameter" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Parameter *)((Model const *)arg1)->getParameter(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getParameter__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getParameter(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getParameter" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getParameter" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Parameter *)(arg1)->getParameter(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getParameter__SWIG_2) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getParameter(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getParameter" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Parameter *)((Model const *)arg1)->getParameter((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getParameter__SWIG_3) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getParameter(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getParameter" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Parameter *)(arg1)->getParameter((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getParameter) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getParameter__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getParameter__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getParameter__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getParameter__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getParameter'");
  XSRETURN(0);
}


XS(_wrap_Model_getInitialAssignment__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getInitialAssignment(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getInitialAssignment" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getInitialAssignment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (InitialAssignment *)((Model const *)arg1)->getInitialAssignment(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getInitialAssignment__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getInitialAssignment(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getInitialAssignment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getInitialAssignment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (InitialAssignment *)(arg1)->getInitialAssignment(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getInitialAssignment__SWIG_2) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getInitialAssignment(self,symbol);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getInitialAssignment" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getInitialAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getInitialAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (InitialAssignment *)((Model const *)arg1)->getInitialAssignment((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getInitialAssignment__SWIG_3) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getInitialAssignment(self,symbol);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getInitialAssignment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getInitialAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getInitialAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (InitialAssignment *)(arg1)->getInitialAssignment((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getInitialAssignment) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getInitialAssignment__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getInitialAssignment__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getInitialAssignment__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getInitialAssignment__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getInitialAssignment'");
  XSRETURN(0);
}


XS(_wrap_Model_getRule__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getRule(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getRule" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getRule" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Rule *)((Model const *)arg1)->getRule(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getRule__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getRule(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getRule" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getRule" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Rule *)(arg1)->getRule(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getRule__SWIG_2) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getRule(self,variable);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getRule" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getRule" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getRule" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Rule *)((Model const *)arg1)->getRule((std::string const &)*arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getRule__SWIG_3) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getRule(self,variable);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getRule" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getRule" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getRule" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Rule *)(arg1)->getRule((std::string const &)*arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getRule) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getRule__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getRule__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getRule__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getRule__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getRule'");
  XSRETURN(0);
}


XS(_wrap_Model_getConstraint__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Constraint *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getConstraint(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getConstraint" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getConstraint" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Constraint *)((Model const *)arg1)->getConstraint(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Constraint, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getConstraint__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Constraint *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getConstraint(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getConstraint" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getConstraint" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Constraint *)(arg1)->getConstraint(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Constraint, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getConstraint) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getConstraint__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getConstraint__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getConstraint'");
  XSRETURN(0);
}


XS(_wrap_Model_getReaction__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getReaction(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getReaction" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getReaction" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Reaction *)((Model const *)arg1)->getReaction(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getReaction__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getReaction(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getReaction" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getReaction" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Reaction *)(arg1)->getReaction(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getReaction__SWIG_2) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getReaction(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getReaction" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getReaction" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getReaction" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Reaction *)((Model const *)arg1)->getReaction((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getReaction__SWIG_3) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getReaction(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getReaction" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getReaction" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getReaction" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Reaction *)(arg1)->getReaction((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getReaction) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getReaction__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getReaction__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getReaction__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getReaction__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getReaction'");
  XSRETURN(0);
}


XS(_wrap_Model_getSpeciesReference__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getSpeciesReference(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getSpeciesReference" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getSpeciesReference" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getSpeciesReference" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesReference *)(arg1)->getSpeciesReference((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getSpeciesReference__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getSpeciesReference(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getSpeciesReference" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getSpeciesReference" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getSpeciesReference" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesReference *)((Model const *)arg1)->getSpeciesReference((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getSpeciesReference) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getSpeciesReference__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getSpeciesReference__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getSpeciesReference'");
  XSRETURN(0);
}


XS(_wrap_Model_getEvent__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getEvent(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getEvent" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getEvent" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Event *)((Model const *)arg1)->getEvent(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getEvent__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getEvent(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getEvent" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_getEvent" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Event *)(arg1)->getEvent(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getEvent__SWIG_2) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getEvent(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getEvent" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getEvent" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getEvent" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Event *)((Model const *)arg1)->getEvent((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getEvent__SWIG_3) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_getEvent(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getEvent" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_getEvent" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_getEvent" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Event *)(arg1)->getEvent((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getEvent) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getEvent__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getEvent__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getEvent__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_getEvent__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_getEvent'");
  XSRETURN(0);
}


XS(_wrap_Model_getNumFunctionDefinitions) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumFunctionDefinitions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumFunctionDefinitions" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumFunctionDefinitions();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumUnitDefinitions) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumUnitDefinitions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumUnitDefinitions" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumUnitDefinitions();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumCompartmentTypes) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumCompartmentTypes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumCompartmentTypes" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumCompartmentTypes();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumSpeciesTypes) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumSpeciesTypes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumSpeciesTypes" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumSpeciesTypes();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumCompartments) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumCompartments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumCompartments" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumCompartments();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumSpecies) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumSpecies(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumSpecies" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumSpecies();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumSpeciesWithBoundaryCondition) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumSpeciesWithBoundaryCondition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumSpeciesWithBoundaryCondition" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumSpeciesWithBoundaryCondition();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumParameters) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumParameters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumParameters" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumParameters();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumInitialAssignments) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumInitialAssignments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumInitialAssignments" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumInitialAssignments();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumRules) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumRules(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumRules" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumRules();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumConstraints) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumConstraints(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumConstraints" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumConstraints();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumReactions) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumReactions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumReactions" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumReactions();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getNumEvents) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getNumEvents(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getNumEvents" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (unsigned int)((Model const *)arg1)->getNumEvents();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_convertL1ToL2) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_convertL1ToL2(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_convertL1ToL2" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->convertL1ToL2();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_convertL1ToL3) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_convertL1ToL3(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_convertL1ToL3" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->convertL1ToL3();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_convertL2ToL3) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_convertL2ToL3(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_convertL2ToL3" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->convertL2ToL3();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_convertL2ToL1__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_convertL2ToL1(self,strict);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_convertL2ToL1" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_convertL2ToL1" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    (arg1)->convertL2ToL1(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_convertL2ToL1__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_convertL2ToL1(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_convertL2ToL1" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->convertL2ToL1();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_convertL2ToL1) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_convertL2ToL1__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_convertL2ToL1__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_convertL2ToL1'");
  XSRETURN(0);
}


XS(_wrap_Model_convertL3ToL1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_convertL3ToL1(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_convertL3ToL1" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->convertL3ToL1();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_convertL3ToL2) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_convertL3ToL2(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_convertL3ToL2" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->convertL3ToL2();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addModifiers) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_addModifiers(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addModifiers" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->addModifiers();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_addConstantAttribute) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_addConstantAttribute(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addConstantAttribute" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->addConstantAttribute();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setSpatialDimensions__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_setSpatialDimensions(self,dims);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setSpatialDimensions" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_setSpatialDimensions" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    (arg1)->setSpatialDimensions(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setSpatialDimensions__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_setSpatialDimensions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setSpatialDimensions" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->setSpatialDimensions();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setSpatialDimensions) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_setSpatialDimensions__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_setSpatialDimensions__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_setSpatialDimensions'");
  XSRETURN(0);
}


XS(_wrap_Model_addDefinitionsForDefaultUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_addDefinitionsForDefaultUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_addDefinitionsForDefaultUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->addDefinitionsForDefaultUnits();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_convertParametersToLocals) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: Model_convertParametersToLocals(self,level,version);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_convertParametersToLocals" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_convertParametersToLocals" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "Model_convertParametersToLocals" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    (arg1)->convertParametersToLocals(arg2,arg3);
    ST(argvi) = sv_newmortal();
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_setSpeciesReferenceConstantValueAndStoichiometry) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_setSpeciesReferenceConstantValueAndStoichiometry(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_setSpeciesReferenceConstantValueAndStoichiometry" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->setSpeciesReferenceConstantValueAndStoichiometry();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeParameterRuleUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_removeParameterRuleUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeParameterRuleUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->removeParameterRuleUnits();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_convertStoichiometryMath) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_convertStoichiometryMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_convertStoichiometryMath" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->convertStoichiometryMath();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_assignRequiredValues) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_assignRequiredValues(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_assignRequiredValues" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->assignRequiredValues();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_dealWithModelUnits) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_dealWithModelUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_dealWithModelUnits" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->dealWithModelUnits();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_dealWithStoichiometry) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_dealWithStoichiometry(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_dealWithStoichiometry" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->dealWithStoichiometry();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getTypeCode) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getTypeCode" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (SBMLTypeCode_t)((Model const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_getElementName) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_getElementName" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (std::string *) &((Model const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_populateListFormulaUnitsData) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_populateListFormulaUnitsData(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_populateListFormulaUnitsData" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    (arg1)->populateListFormulaUnitsData();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_isPopulatedListFormulaUnitsData) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_isPopulatedListFormulaUnitsData(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_isPopulatedListFormulaUnitsData" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (bool)(arg1)->isPopulatedListFormulaUnitsData();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_hasRequiredElements) {
  {
    Model *arg1 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Model_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_hasRequiredElements" "', argument " "1"" of type '" "Model const *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    result = (bool)((Model const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeFunctionDefinition__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeFunctionDefinition(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeFunctionDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeFunctionDefinition" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (FunctionDefinition *)(arg1)->removeFunctionDefinition(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeFunctionDefinition__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeFunctionDefinition(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeFunctionDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_removeFunctionDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_removeFunctionDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (FunctionDefinition *)(arg1)->removeFunctionDefinition((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeFunctionDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeFunctionDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeFunctionDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_removeFunctionDefinition'");
  XSRETURN(0);
}


XS(_wrap_Model_removeUnitDefinition__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeUnitDefinition(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeUnitDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeUnitDefinition" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (UnitDefinition *)(arg1)->removeUnitDefinition(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeUnitDefinition__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeUnitDefinition(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeUnitDefinition" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_removeUnitDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_removeUnitDefinition" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (UnitDefinition *)(arg1)->removeUnitDefinition((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeUnitDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeUnitDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_removeUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_Model_removeCompartmentType__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeCompartmentType(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeCompartmentType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeCompartmentType" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (CompartmentType *)(arg1)->removeCompartmentType(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeCompartmentType__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeCompartmentType(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeCompartmentType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_removeCompartmentType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_removeCompartmentType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (CompartmentType *)(arg1)->removeCompartmentType((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeCompartmentType) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeCompartmentType__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeCompartmentType__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_removeCompartmentType'");
  XSRETURN(0);
}


XS(_wrap_Model_removeSpeciesType__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeSpeciesType(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeSpeciesType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeSpeciesType" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesType *)(arg1)->removeSpeciesType(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeSpeciesType__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeSpeciesType(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeSpeciesType" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_removeSpeciesType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_removeSpeciesType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesType *)(arg1)->removeSpeciesType((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeSpeciesType) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeSpeciesType__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeSpeciesType__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_removeSpeciesType'");
  XSRETURN(0);
}


XS(_wrap_Model_removeCompartment__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeCompartment(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeCompartment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeCompartment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Compartment *)(arg1)->removeCompartment(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeCompartment__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeCompartment(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeCompartment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_removeCompartment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_removeCompartment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Compartment *)(arg1)->removeCompartment((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeCompartment) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeCompartment__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeCompartment__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_removeCompartment'");
  XSRETURN(0);
}


XS(_wrap_Model_removeSpecies__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeSpecies(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeSpecies" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeSpecies" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Species *)(arg1)->removeSpecies(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeSpecies__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeSpecies(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeSpecies" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_removeSpecies" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_removeSpecies" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Species *)(arg1)->removeSpecies((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeSpecies) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeSpecies__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeSpecies__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_removeSpecies'");
  XSRETURN(0);
}


XS(_wrap_Model_removeParameter__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeParameter(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeParameter" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeParameter" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Parameter *)(arg1)->removeParameter(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeParameter__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeParameter(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeParameter" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_removeParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_removeParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Parameter *)(arg1)->removeParameter((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeParameter) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeParameter__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeParameter__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_removeParameter'");
  XSRETURN(0);
}


XS(_wrap_Model_removeInitialAssignment__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeInitialAssignment(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeInitialAssignment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeInitialAssignment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (InitialAssignment *)(arg1)->removeInitialAssignment(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeInitialAssignment__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeInitialAssignment(self,symbol);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeInitialAssignment" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_removeInitialAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_removeInitialAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (InitialAssignment *)(arg1)->removeInitialAssignment((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeInitialAssignment) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeInitialAssignment__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeInitialAssignment__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_removeInitialAssignment'");
  XSRETURN(0);
}


XS(_wrap_Model_removeRule__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeRule(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeRule" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeRule" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Rule *)(arg1)->removeRule(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        SWIG_OWNER | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeRule__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeRule(self,variable);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeRule" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_removeRule" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_removeRule" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Rule *)(arg1)->removeRule((std::string const &)*arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        SWIG_OWNER | SWIG_SHADOW);
      argvi++;
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeRule) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeRule__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeRule__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_removeRule'");
  XSRETURN(0);
}


XS(_wrap_Model_removeConstraint) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Constraint *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeConstraint(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeConstraint" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeConstraint" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Constraint *)(arg1)->removeConstraint(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Constraint, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeReaction__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeReaction(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeReaction" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeReaction" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Reaction *)(arg1)->removeReaction(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeReaction__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeReaction(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeReaction" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_removeReaction" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_removeReaction" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Reaction *)(arg1)->removeReaction((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeReaction) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeReaction__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeReaction__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_removeReaction'");
  XSRETURN(0);
}


XS(_wrap_Model_removeEvent__SWIG_0) {
  {
    Model *arg1 = (Model *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeEvent(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeEvent" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Model_removeEvent" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Event *)(arg1)->removeEvent(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeEvent__SWIG_1) {
  {
    Model *arg1 = (Model *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Model_removeEvent(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Model_removeEvent" "', argument " "1"" of type '" "Model *""'"); 
    }
    arg1 = reinterpret_cast< Model * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Model_removeEvent" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Model_removeEvent" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Event *)(arg1)->removeEvent((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Model_removeEvent) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Model, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeEvent__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Model_removeEvent__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Model_removeEvent'");
  XSRETURN(0);
}


XS(_wrap_SBMLDocument_getDefaultLevel) {
  {
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: SBMLDocument_getDefaultLevel();");
    }
    result = (unsigned int)SBMLDocument::getDefaultLevel();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_getDefaultVersion) {
  {
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: SBMLDocument_getDefaultVersion();");
    }
    result = (unsigned int)SBMLDocument::getDefaultVersion();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLDocument__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SBMLDocument *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_SBMLDocument(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLDocument" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_SBMLDocument" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (SBMLDocument *)new SBMLDocument(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLDocument__SWIG_1) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    SBMLDocument *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SBMLDocument(level);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLDocument" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    {
      try {
        result = (SBMLDocument *)new SBMLDocument(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLDocument__SWIG_2) {
  {
    int argvi = 0;
    SBMLDocument *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_SBMLDocument();");
    }
    {
      try {
        result = (SBMLDocument *)new SBMLDocument();
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLDocument__SWIG_3) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLDocument *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SBMLDocument(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_SBMLDocument" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (SBMLDocument *)new SBMLDocument(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SBMLDocument) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SBMLDocument(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SBMLDocument" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLDocument__SWIG_4) {
  {
    SBMLDocument *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLDocument *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SBMLDocument(rhs);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_SBMLDocument,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_SBMLDocument" "', argument " "1"" of type '" "SBMLDocument const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_SBMLDocument" "', argument " "1"" of type '" "SBMLDocument const &""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    {
      try {
        result = (SBMLDocument *)new SBMLDocument((SBMLDocument const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLDocument) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLDocument, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 5;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_5:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLDocument__SWIG_2); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLDocument__SWIG_3); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLDocument__SWIG_4); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLDocument__SWIG_1); return;
    case 5:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLDocument__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_SBMLDocument'");
  XSRETURN(0);
}


XS(_wrap_SBMLDocument_clone) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLDocument *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_clone" "', argument " "1"" of type '" "SBMLDocument const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (SBMLDocument *)((SBMLDocument const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLDocument, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_getModel__SWIG_0) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Model *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_getModel(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_getModel" "', argument " "1"" of type '" "SBMLDocument const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (Model *)((SBMLDocument const *)arg1)->getModel();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Model, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_getModel__SWIG_1) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Model *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_getModel(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_getModel" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (Model *)(arg1)->getModel();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Model, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_getModel) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLDocument, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLDocument, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLDocument_getModel__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLDocument_getModel__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'SBMLDocument_getModel'");
  XSRETURN(0);
}


XS(_wrap_SBMLDocument_expandFunctionDefinitions) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_expandFunctionDefinitions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_expandFunctionDefinitions" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (bool)(arg1)->expandFunctionDefinitions();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_expandInitialAssignments) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_expandInitialAssignments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_expandInitialAssignments" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (bool)(arg1)->expandInitialAssignments();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_setLevelAndVersion__SWIG_0) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    bool arg4 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    bool val4 ;
    int ecode4 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 4) || (items > 4)) {
      SWIG_croak("Usage: SBMLDocument_setLevelAndVersion(self,level,version,strict);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_setLevelAndVersion" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBMLDocument_setLevelAndVersion" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "SBMLDocument_setLevelAndVersion" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "SBMLDocument_setLevelAndVersion" "', argument " "4"" of type '" "bool""'");
    } 
    arg4 = static_cast< bool >(val4);
    result = (bool)(arg1)->setLevelAndVersion(arg2,arg3,arg4);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_setLevelAndVersion__SWIG_1) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: SBMLDocument_setLevelAndVersion(self,level,version);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_setLevelAndVersion" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBMLDocument_setLevelAndVersion" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "SBMLDocument_setLevelAndVersion" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    result = (bool)(arg1)->setLevelAndVersion(arg2,arg3);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_setLevelAndVersion) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLDocument, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 4) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLDocument, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLDocument_setLevelAndVersion__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLDocument_setLevelAndVersion__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'SBMLDocument_setLevelAndVersion'");
  XSRETURN(0);
}


XS(_wrap_SBMLDocument_setModel) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    Model *arg2 = (Model *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLDocument_setModel(self,m);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_setModel" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Model, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLDocument_setModel" "', argument " "2"" of type '" "Model const *""'"); 
    }
    arg2 = reinterpret_cast< Model * >(argp2);
    result = (int)(arg1)->setModel((Model const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_createModel__SWIG_0) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Model *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLDocument_createModel(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_createModel" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLDocument_createModel" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBMLDocument_createModel" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Model *)(arg1)->createModel((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Model, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_createModel__SWIG_1) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Model *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_createModel(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_createModel" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (Model *)(arg1)->createModel();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Model, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_createModel) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLDocument, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLDocument, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLDocument_createModel__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLDocument_createModel__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'SBMLDocument_createModel'");
  XSRETURN(0);
}


XS(_wrap_SBMLDocument_setConsistencyChecks) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    SBMLErrorCategory_t arg2 ;
    bool arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    bool val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: SBMLDocument_setConsistencyChecks(self,category,apply);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_setConsistencyChecks" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBMLDocument_setConsistencyChecks" "', argument " "2"" of type '" "SBMLErrorCategory_t""'");
    } 
    arg2 = static_cast< SBMLErrorCategory_t >(val2);
    ecode3 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "SBMLDocument_setConsistencyChecks" "', argument " "3"" of type '" "bool""'");
    } 
    arg3 = static_cast< bool >(val3);
    (arg1)->setConsistencyChecks(arg2,arg3);
    ST(argvi) = sv_newmortal();
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_setConsistencyChecksForConversion) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    SBMLErrorCategory_t arg2 ;
    bool arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    bool val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: SBMLDocument_setConsistencyChecksForConversion(self,category,apply);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_setConsistencyChecksForConversion" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBMLDocument_setConsistencyChecksForConversion" "', argument " "2"" of type '" "SBMLErrorCategory_t""'");
    } 
    arg2 = static_cast< SBMLErrorCategory_t >(val2);
    ecode3 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "SBMLDocument_setConsistencyChecksForConversion" "', argument " "3"" of type '" "bool""'");
    } 
    arg3 = static_cast< bool >(val3);
    (arg1)->setConsistencyChecksForConversion(arg2,arg3);
    ST(argvi) = sv_newmortal();
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_checkConsistency) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_checkConsistency(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_checkConsistency" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (unsigned int)(arg1)->checkConsistency();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_checkInternalConsistency) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_checkInternalConsistency(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_checkInternalConsistency" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (unsigned int)(arg1)->checkInternalConsistency();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_checkL1Compatibility) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_checkL1Compatibility(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_checkL1Compatibility" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (unsigned int)(arg1)->checkL1Compatibility();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_checkL2v1Compatibility) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_checkL2v1Compatibility(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_checkL2v1Compatibility" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (unsigned int)(arg1)->checkL2v1Compatibility();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_checkL2v2Compatibility) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_checkL2v2Compatibility(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_checkL2v2Compatibility" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (unsigned int)(arg1)->checkL2v2Compatibility();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_checkL2v3Compatibility) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_checkL2v3Compatibility(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_checkL2v3Compatibility" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (unsigned int)(arg1)->checkL2v3Compatibility();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_checkL2v4Compatibility) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_checkL2v4Compatibility(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_checkL2v4Compatibility" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (unsigned int)(arg1)->checkL2v4Compatibility();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_checkL3v1Compatibility) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_checkL3v1Compatibility(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_checkL3v1Compatibility" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (unsigned int)(arg1)->checkL3v1Compatibility();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_getError) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLDocument_getError(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_getError" "', argument " "1"" of type '" "SBMLDocument const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBMLDocument_getError" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SBMLError *)((SBMLDocument const *)arg1)->getError(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_getNumErrors) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_getNumErrors(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_getNumErrors" "', argument " "1"" of type '" "SBMLDocument const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (unsigned int)((SBMLDocument const *)arg1)->getNumErrors();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_printErrors__SWIG_0) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    std::ostream *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLDocument_printErrors(self,stream);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_printErrors" "', argument " "1"" of type '" "SBMLDocument const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_std__ostream,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLDocument_printErrors" "', argument " "2"" of type '" "std::ostream &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBMLDocument_printErrors" "', argument " "2"" of type '" "std::ostream &""'"); 
    }
    arg2 = reinterpret_cast< std::ostream * >(argp2);
    ((SBMLDocument const *)arg1)->printErrors(*arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_printErrors__SWIG_1) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_printErrors(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_printErrors" "', argument " "1"" of type '" "SBMLDocument const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    ((SBMLDocument const *)arg1)->printErrors();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_printErrors) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLDocument, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLDocument, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_std__ostream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLDocument_printErrors__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLDocument_printErrors__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'SBMLDocument_printErrors'");
  XSRETURN(0);
}


XS(_wrap_SBMLDocument_getTypeCode) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_getTypeCode" "', argument " "1"" of type '" "SBMLDocument const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (SBMLTypeCode_t)((SBMLDocument const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_getElementName) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_getElementName" "', argument " "1"" of type '" "SBMLDocument const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (std::string *) &((SBMLDocument const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_getErrorLog) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLErrorLog *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_getErrorLog(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_getErrorLog" "', argument " "1"" of type '" "SBMLDocument *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (SBMLErrorLog *)(arg1)->getErrorLog();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLErrorLog, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLDocument_getNamespaces) {
  {
    SBMLDocument *arg1 = (SBMLDocument *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLDocument_getNamespaces(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLDocument, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLDocument_getNamespaces" "', argument " "1"" of type '" "SBMLDocument const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLDocument * >(argp1);
    result = (XMLNamespaces *)((SBMLDocument const *)arg1)->getNamespaces();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNamespaces, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_FunctionDefinition__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_FunctionDefinition(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_FunctionDefinition" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_FunctionDefinition" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (FunctionDefinition *)new FunctionDefinition(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_FunctionDefinition__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_FunctionDefinition(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_FunctionDefinition" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (FunctionDefinition *)new FunctionDefinition(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_FunctionDefinition) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_FunctionDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_FunctionDefinition" "', argument " "1"" of type '" "FunctionDefinition *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_FunctionDefinition__SWIG_2) {
  {
    FunctionDefinition *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_FunctionDefinition(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_FunctionDefinition,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_FunctionDefinition" "', argument " "1"" of type '" "FunctionDefinition const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_FunctionDefinition" "', argument " "1"" of type '" "FunctionDefinition const &""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    {
      try {
        result = (FunctionDefinition *)new FunctionDefinition((FunctionDefinition const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_FunctionDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_FunctionDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_FunctionDefinition__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_FunctionDefinition__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_FunctionDefinition__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_FunctionDefinition'");
  XSRETURN(0);
}


XS(_wrap_FunctionDefinition_clone) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_clone" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (FunctionDefinition *)((FunctionDefinition const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_getId) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_getId" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (std::string *) &((FunctionDefinition const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_getName) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_getName" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (std::string *) &((FunctionDefinition const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_getMath) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_getMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_getMath" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (ASTNode *)((FunctionDefinition const *)arg1)->getMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_isSetId) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_isSetId" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (bool)((FunctionDefinition const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_isSetName) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_isSetName" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (bool)((FunctionDefinition const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_isSetMath) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_isSetMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_isSetMath" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (bool)((FunctionDefinition const *)arg1)->isSetMath();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_setId) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: FunctionDefinition_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_setId" "', argument " "1"" of type '" "FunctionDefinition *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "FunctionDefinition_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "FunctionDefinition_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_setName) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: FunctionDefinition_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_setName" "', argument " "1"" of type '" "FunctionDefinition *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "FunctionDefinition_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "FunctionDefinition_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_setMath) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: FunctionDefinition_setMath(self,math);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_setMath" "', argument " "1"" of type '" "FunctionDefinition *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "FunctionDefinition_setMath" "', argument " "2"" of type '" "ASTNode const *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->setMath((ASTNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_unsetName) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_unsetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_unsetName" "', argument " "1"" of type '" "FunctionDefinition *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (int)(arg1)->unsetName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_getArgument__SWIG_0) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: FunctionDefinition_getArgument(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_getArgument" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "FunctionDefinition_getArgument" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (ASTNode *)((FunctionDefinition const *)arg1)->getArgument(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_getArgument__SWIG_1) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: FunctionDefinition_getArgument(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_getArgument" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "FunctionDefinition_getArgument" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "FunctionDefinition_getArgument" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (ASTNode *)((FunctionDefinition const *)arg1)->getArgument((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_getArgument) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_FunctionDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_FunctionDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_FunctionDefinition_getArgument__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_FunctionDefinition_getArgument__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'FunctionDefinition_getArgument'");
  XSRETURN(0);
}


XS(_wrap_FunctionDefinition_getBody__SWIG_0) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_getBody(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_getBody" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (ASTNode *)((FunctionDefinition const *)arg1)->getBody();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_getBody__SWIG_1) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_getBody(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_getBody" "', argument " "1"" of type '" "FunctionDefinition *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (ASTNode *)(arg1)->getBody();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_getBody) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_FunctionDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_FunctionDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_FunctionDefinition_getBody__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_FunctionDefinition_getBody__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'FunctionDefinition_getBody'");
  XSRETURN(0);
}


XS(_wrap_FunctionDefinition_getNumArguments) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_getNumArguments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_getNumArguments" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (unsigned int)((FunctionDefinition const *)arg1)->getNumArguments();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_getTypeCode) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_getTypeCode" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (SBMLTypeCode_t)((FunctionDefinition const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_getElementName) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_getElementName" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (std::string *) &((FunctionDefinition const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_hasRequiredAttributes) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_hasRequiredAttributes" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (bool)((FunctionDefinition const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_FunctionDefinition_hasRequiredElements) {
  {
    FunctionDefinition *arg1 = (FunctionDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: FunctionDefinition_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_FunctionDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "FunctionDefinition_hasRequiredElements" "', argument " "1"" of type '" "FunctionDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< FunctionDefinition * >(argp1);
    result = (bool)((FunctionDefinition const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfFunctionDefinitions_clone) {
  {
    ListOfFunctionDefinitions *arg1 = (ListOfFunctionDefinitions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfFunctionDefinitions *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfFunctionDefinitions_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfFunctionDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfFunctionDefinitions_clone" "', argument " "1"" of type '" "ListOfFunctionDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfFunctionDefinitions * >(argp1);
    result = (ListOfFunctionDefinitions *)((ListOfFunctionDefinitions const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfFunctionDefinitions, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfFunctionDefinitions_getTypeCode) {
  {
    ListOfFunctionDefinitions *arg1 = (ListOfFunctionDefinitions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfFunctionDefinitions_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfFunctionDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfFunctionDefinitions_getTypeCode" "', argument " "1"" of type '" "ListOfFunctionDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfFunctionDefinitions * >(argp1);
    result = (SBMLTypeCode_t)((ListOfFunctionDefinitions const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfFunctionDefinitions_getItemTypeCode) {
  {
    ListOfFunctionDefinitions *arg1 = (ListOfFunctionDefinitions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfFunctionDefinitions_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfFunctionDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfFunctionDefinitions_getItemTypeCode" "', argument " "1"" of type '" "ListOfFunctionDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfFunctionDefinitions * >(argp1);
    result = (SBMLTypeCode_t)((ListOfFunctionDefinitions const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfFunctionDefinitions_getElementName) {
  {
    ListOfFunctionDefinitions *arg1 = (ListOfFunctionDefinitions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfFunctionDefinitions_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfFunctionDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfFunctionDefinitions_getElementName" "', argument " "1"" of type '" "ListOfFunctionDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfFunctionDefinitions * >(argp1);
    result = (std::string *) &((ListOfFunctionDefinitions const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfFunctionDefinitions_get__SWIG_0) {
  {
    ListOfFunctionDefinitions *arg1 = (ListOfFunctionDefinitions *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfFunctionDefinitions_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfFunctionDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfFunctionDefinitions_get" "', argument " "1"" of type '" "ListOfFunctionDefinitions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfFunctionDefinitions * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfFunctionDefinitions_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (FunctionDefinition *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfFunctionDefinitions_get__SWIG_1) {
  {
    ListOfFunctionDefinitions *arg1 = (ListOfFunctionDefinitions *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfFunctionDefinitions_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfFunctionDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfFunctionDefinitions_get" "', argument " "1"" of type '" "ListOfFunctionDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfFunctionDefinitions * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfFunctionDefinitions_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (FunctionDefinition *)((ListOfFunctionDefinitions const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfFunctionDefinitions_get__SWIG_2) {
  {
    ListOfFunctionDefinitions *arg1 = (ListOfFunctionDefinitions *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfFunctionDefinitions_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfFunctionDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfFunctionDefinitions_get" "', argument " "1"" of type '" "ListOfFunctionDefinitions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfFunctionDefinitions * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfFunctionDefinitions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfFunctionDefinitions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (FunctionDefinition *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfFunctionDefinitions_get__SWIG_3) {
  {
    ListOfFunctionDefinitions *arg1 = (ListOfFunctionDefinitions *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfFunctionDefinitions_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfFunctionDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfFunctionDefinitions_get" "', argument " "1"" of type '" "ListOfFunctionDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfFunctionDefinitions * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfFunctionDefinitions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfFunctionDefinitions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (FunctionDefinition *)((ListOfFunctionDefinitions const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfFunctionDefinitions_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfFunctionDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfFunctionDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfFunctionDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfFunctionDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfFunctionDefinitions_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfFunctionDefinitions_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfFunctionDefinitions_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfFunctionDefinitions_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfFunctionDefinitions_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfFunctionDefinitions_remove__SWIG_0) {
  {
    ListOfFunctionDefinitions *arg1 = (ListOfFunctionDefinitions *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfFunctionDefinitions_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfFunctionDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfFunctionDefinitions_remove" "', argument " "1"" of type '" "ListOfFunctionDefinitions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfFunctionDefinitions * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfFunctionDefinitions_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (FunctionDefinition *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfFunctionDefinitions_remove__SWIG_1) {
  {
    ListOfFunctionDefinitions *arg1 = (ListOfFunctionDefinitions *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    FunctionDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfFunctionDefinitions_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfFunctionDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfFunctionDefinitions_remove" "', argument " "1"" of type '" "ListOfFunctionDefinitions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfFunctionDefinitions * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfFunctionDefinitions_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfFunctionDefinitions_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (FunctionDefinition *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FunctionDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfFunctionDefinitions_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfFunctionDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfFunctionDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfFunctionDefinitions_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfFunctionDefinitions_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfFunctionDefinitions_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfFunctionDefinitions) {
  {
    int argvi = 0;
    ListOfFunctionDefinitions *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfFunctionDefinitions();");
    }
    result = (ListOfFunctionDefinitions *)new ListOfFunctionDefinitions();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfFunctionDefinitions, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfFunctionDefinitions) {
  {
    ListOfFunctionDefinitions *arg1 = (ListOfFunctionDefinitions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfFunctionDefinitions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfFunctionDefinitions, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfFunctionDefinitions" "', argument " "1"" of type '" "ListOfFunctionDefinitions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfFunctionDefinitions * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitKind_equals) {
  {
    UnitKind_t arg1 ;
    UnitKind_t arg2 ;
    int val1 ;
    int ecode1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: UnitKind_equals(uk1,uk2);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "UnitKind_equals" "', argument " "1"" of type '" "UnitKind_t""'");
    } 
    arg1 = static_cast< UnitKind_t >(val1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "UnitKind_equals" "', argument " "2"" of type '" "UnitKind_t""'");
    } 
    arg2 = static_cast< UnitKind_t >(val2);
    result = (int)UnitKind_equals(arg1,arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitKind_forName) {
  {
    char *arg1 = (char *) 0 ;
    int res1 ;
    char *buf1 = 0 ;
    int alloc1 = 0 ;
    int argvi = 0;
    UnitKind_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitKind_forName(name);");
    }
    res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1);
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitKind_forName" "', argument " "1"" of type '" "char const *""'");
    }
    arg1 = reinterpret_cast< char * >(buf1);
    result = (UnitKind_t)UnitKind_forName((char const *)arg1);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    XSRETURN(argvi);
  fail:
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    SWIG_croak_null();
  }
}


XS(_wrap_UnitKind_toString) {
  {
    UnitKind_t arg1 ;
    int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    char *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitKind_toString(uk);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "UnitKind_toString" "', argument " "1"" of type '" "UnitKind_t""'");
    } 
    arg1 = static_cast< UnitKind_t >(val1);
    result = (char *)UnitKind_toString(arg1);
    ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitKind_isValidUnitKindString) {
  {
    char *arg1 = (char *) 0 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    int res1 ;
    char *buf1 = 0 ;
    int alloc1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: UnitKind_isValidUnitKindString(unit,level,version);");
    }
    res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1);
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitKind_isValidUnitKindString" "', argument " "1"" of type '" "char const *""'");
    }
    arg1 = reinterpret_cast< char * >(buf1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "UnitKind_isValidUnitKindString" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "UnitKind_isValidUnitKindString" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    result = (int)UnitKind_isValidUnitKindString((char const *)arg1,arg2,arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    
    
    XSRETURN(argvi);
  fail:
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Unit__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Unit(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Unit" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Unit" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (Unit *)new Unit(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Unit__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Unit(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Unit" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (Unit *)new Unit(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Unit) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Unit(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Unit" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Unit__SWIG_2) {
  {
    Unit *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Unit(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Unit,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Unit" "', argument " "1"" of type '" "Unit const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Unit" "', argument " "1"" of type '" "Unit const &""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    {
      try {
        result = (Unit *)new Unit((Unit const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Unit) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Unit, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Unit__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Unit__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Unit__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Unit'");
  XSRETURN(0);
}


XS(_wrap_Unit_clone) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_clone" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (Unit *)((Unit const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_initDefaults) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_initDefaults(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_initDefaults" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    (arg1)->initDefaults();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_getKind) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitKind_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_getKind(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_getKind" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (UnitKind_t)((Unit const *)arg1)->getKind();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_getExponent) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_getExponent(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_getExponent" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (int)((Unit const *)arg1)->getExponent();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_getExponentAsDouble) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_getExponentAsDouble(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_getExponentAsDouble" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (double)((Unit const *)arg1)->getExponentAsDouble();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_getScale) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_getScale(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_getScale" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (int)((Unit const *)arg1)->getScale();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_getMultiplier) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_getMultiplier(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_getMultiplier" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (double)((Unit const *)arg1)->getMultiplier();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_getOffset) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_getOffset(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_getOffset" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (double)((Unit const *)arg1)->getOffset();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isAmpere) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isAmpere(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isAmpere" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isAmpere();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isAvogadro) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isAvogadro(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isAvogadro" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isAvogadro();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isBecquerel) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isBecquerel(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isBecquerel" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isBecquerel();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isCandela) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isCandela(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isCandela" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isCandela();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isCelsius) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isCelsius(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isCelsius" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isCelsius();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isCoulomb) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isCoulomb(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isCoulomb" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isCoulomb();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isDimensionless) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isDimensionless(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isDimensionless" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isDimensionless();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isFarad) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isFarad(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isFarad" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isFarad();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isGram) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isGram(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isGram" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isGram();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isGray) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isGray(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isGray" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isGray();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isHenry) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isHenry(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isHenry" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isHenry();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isHertz) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isHertz(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isHertz" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isHertz();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isItem) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isItem(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isItem" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isItem();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isJoule) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isJoule(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isJoule" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isJoule();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isKatal) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isKatal(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isKatal" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isKatal();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isKelvin) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isKelvin(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isKelvin" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isKelvin();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isKilogram) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isKilogram(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isKilogram" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isKilogram();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isLitre) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isLitre(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isLitre" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isLitre();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isLumen) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isLumen(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isLumen" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isLumen();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isLux) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isLux(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isLux" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isLux();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isMetre) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isMetre(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isMetre" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isMetre();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isMole) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isMole(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isMole" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isMole();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isNewton) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isNewton(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isNewton" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isNewton();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isOhm) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isOhm(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isOhm" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isOhm();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isPascal) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isPascal(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isPascal" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isPascal();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isRadian) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isRadian(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isRadian" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isRadian();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isSecond) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isSecond(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isSecond" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isSecond();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isSiemens) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isSiemens(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isSiemens" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isSiemens();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isSievert) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isSievert(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isSievert" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isSievert();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isSteradian) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isSteradian(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isSteradian" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isSteradian();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isTesla) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isTesla(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isTesla" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isTesla();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isVolt) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isVolt(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isVolt" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isVolt();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isWatt) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isWatt(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isWatt" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isWatt();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isWeber) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isWeber(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isWeber" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isWeber();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isSetKind) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isSetKind(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isSetKind" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isSetKind();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isSetExponent) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isSetExponent(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isSetExponent" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isSetExponent();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isSetScale) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isSetScale(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isSetScale" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isSetScale();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isSetMultiplier) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_isSetMultiplier(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isSetMultiplier" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->isSetMultiplier();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_setKind) {
  {
    Unit *arg1 = (Unit *) 0 ;
    UnitKind_t arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Unit_setKind(self,kind);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_setKind" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Unit_setKind" "', argument " "2"" of type '" "UnitKind_t""'");
    } 
    arg2 = static_cast< UnitKind_t >(val2);
    result = (int)(arg1)->setKind(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_setExponent__SWIG_0) {
  {
    Unit *arg1 = (Unit *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Unit_setExponent(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_setExponent" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Unit_setExponent" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (int)(arg1)->setExponent(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_setExponent__SWIG_1) {
  {
    Unit *arg1 = (Unit *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Unit_setExponent(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_setExponent" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Unit_setExponent" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    result = (int)(arg1)->setExponent(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_setExponent) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Unit, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Unit, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Unit_setExponent__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Unit_setExponent__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Unit_setExponent'");
  XSRETURN(0);
}


XS(_wrap_Unit_setScale) {
  {
    Unit *arg1 = (Unit *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Unit_setScale(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_setScale" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Unit_setScale" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (int)(arg1)->setScale(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_setMultiplier) {
  {
    Unit *arg1 = (Unit *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Unit_setMultiplier(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_setMultiplier" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Unit_setMultiplier" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    result = (int)(arg1)->setMultiplier(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_setOffset) {
  {
    Unit *arg1 = (Unit *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Unit_setOffset(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_setOffset" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Unit_setOffset" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    result = (int)(arg1)->setOffset(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_getTypeCode) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_getTypeCode" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (SBMLTypeCode_t)((Unit const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_getElementName) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_getElementName" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (std::string *) &((Unit const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isBuiltIn) {
  {
    std::string *arg1 = 0 ;
    unsigned int arg2 ;
    int res1 = SWIG_OLDOBJ ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Unit_isBuiltIn(name,level);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isBuiltIn" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Unit_isBuiltIn" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Unit_isBuiltIn" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (bool)Unit::isBuiltIn((std::string const &)*arg1,arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_isUnitKind) {
  {
    std::string *arg1 = 0 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    int res1 = SWIG_OLDOBJ ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: Unit_isUnitKind(name,level,version);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_isUnitKind" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Unit_isUnitKind" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Unit_isUnitKind" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "Unit_isUnitKind" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    result = (bool)Unit::isUnitKind((std::string const &)*arg1,arg2,arg3);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_areIdentical) {
  {
    Unit *arg1 = (Unit *) 0 ;
    Unit *arg2 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Unit_areIdentical(unit1,unit2);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_areIdentical" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Unit_areIdentical" "', argument " "2"" of type '" "Unit *""'"); 
    }
    arg2 = reinterpret_cast< Unit * >(argp2);
    result = (bool)Unit::areIdentical(arg1,arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_areEquivalent) {
  {
    Unit *arg1 = (Unit *) 0 ;
    Unit *arg2 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Unit_areEquivalent(unit1,unit2);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_areEquivalent" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Unit_areEquivalent" "', argument " "2"" of type '" "Unit *""'"); 
    }
    arg2 = reinterpret_cast< Unit * >(argp2);
    result = (bool)Unit::areEquivalent(arg1,arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_removeScale) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_removeScale(unit);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_removeScale" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (int)Unit::removeScale(arg1);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_merge) {
  {
    Unit *arg1 = (Unit *) 0 ;
    Unit *arg2 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Unit_merge(unit1,unit2);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_merge" "', argument " "1"" of type '" "Unit *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Unit_merge" "', argument " "2"" of type '" "Unit *""'"); 
    }
    arg2 = reinterpret_cast< Unit * >(argp2);
    Unit::merge(arg1,arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_convertToSI) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_convertToSI(unit);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_convertToSI" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (UnitDefinition *)Unit::convertToSI((Unit const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Unit_hasRequiredAttributes) {
  {
    Unit *arg1 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Unit_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Unit_hasRequiredAttributes" "', argument " "1"" of type '" "Unit const *""'"); 
    }
    arg1 = reinterpret_cast< Unit * >(argp1);
    result = (bool)((Unit const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnits_clone) {
  {
    ListOfUnits *arg1 = (ListOfUnits *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfUnits *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfUnits_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnits, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnits_clone" "', argument " "1"" of type '" "ListOfUnits const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnits * >(argp1);
    result = (ListOfUnits *)((ListOfUnits const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfUnits, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnits_getTypeCode) {
  {
    ListOfUnits *arg1 = (ListOfUnits *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfUnits_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnits, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnits_getTypeCode" "', argument " "1"" of type '" "ListOfUnits const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnits * >(argp1);
    result = (SBMLTypeCode_t)((ListOfUnits const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnits_getItemTypeCode) {
  {
    ListOfUnits *arg1 = (ListOfUnits *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfUnits_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnits, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnits_getItemTypeCode" "', argument " "1"" of type '" "ListOfUnits const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnits * >(argp1);
    result = (SBMLTypeCode_t)((ListOfUnits const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnits_getElementName) {
  {
    ListOfUnits *arg1 = (ListOfUnits *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfUnits_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnits, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnits_getElementName" "', argument " "1"" of type '" "ListOfUnits const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnits * >(argp1);
    result = (std::string *) &((ListOfUnits const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnits_get__SWIG_0) {
  {
    ListOfUnits *arg1 = (ListOfUnits *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfUnits_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnits, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnits_get" "', argument " "1"" of type '" "ListOfUnits *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnits * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfUnits_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Unit *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnits_get__SWIG_1) {
  {
    ListOfUnits *arg1 = (ListOfUnits *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfUnits_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnits, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnits_get" "', argument " "1"" of type '" "ListOfUnits const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnits * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfUnits_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Unit *)((ListOfUnits const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnits_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfUnits, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfUnits, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfUnits_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfUnits_get__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfUnits_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfUnits_remove) {
  {
    ListOfUnits *arg1 = (ListOfUnits *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfUnits_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnits, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnits_remove" "', argument " "1"" of type '" "ListOfUnits *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnits * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfUnits_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Unit *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ListOfUnits) {
  {
    int argvi = 0;
    ListOfUnits *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfUnits();");
    }
    result = (ListOfUnits *)new ListOfUnits();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfUnits, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfUnits) {
  {
    ListOfUnits *arg1 = (ListOfUnits *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnits, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfUnits" "', argument " "1"" of type '" "ListOfUnits *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnits * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_UnitDefinition__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_UnitDefinition(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_UnitDefinition" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_UnitDefinition" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (UnitDefinition *)new UnitDefinition(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_UnitDefinition__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_UnitDefinition(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_UnitDefinition" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (UnitDefinition *)new UnitDefinition(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_UnitDefinition) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_UnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_UnitDefinition" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_UnitDefinition__SWIG_2) {
  {
    UnitDefinition *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_UnitDefinition(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_UnitDefinition,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_UnitDefinition" "', argument " "1"" of type '" "UnitDefinition const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_UnitDefinition" "', argument " "1"" of type '" "UnitDefinition const &""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    {
      try {
        result = (UnitDefinition *)new UnitDefinition((UnitDefinition const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_UnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_UnitDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_UnitDefinition__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_UnitDefinition__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_UnitDefinition__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_UnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_UnitDefinition_clone) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_clone" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (UnitDefinition *)((UnitDefinition const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_getId) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_getId" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (std::string *) &((UnitDefinition const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_getName) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_getName" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (std::string *) &((UnitDefinition const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_isSetId) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_isSetId" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_isSetName) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_isSetName" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_setId) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: UnitDefinition_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_setId" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "UnitDefinition_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "UnitDefinition_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_setName) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: UnitDefinition_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_setName" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "UnitDefinition_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "UnitDefinition_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_unsetName) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_unsetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_unsetName" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (int)(arg1)->unsetName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_isVariantOfArea) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_isVariantOfArea(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_isVariantOfArea" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->isVariantOfArea();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_isVariantOfLength) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_isVariantOfLength(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_isVariantOfLength" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->isVariantOfLength();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_isVariantOfSubstance) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_isVariantOfSubstance(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_isVariantOfSubstance" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->isVariantOfSubstance();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_isVariantOfTime) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_isVariantOfTime(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_isVariantOfTime" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->isVariantOfTime();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_isVariantOfVolume) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_isVariantOfVolume(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_isVariantOfVolume" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->isVariantOfVolume();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_isVariantOfDimensionless) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_isVariantOfDimensionless(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_isVariantOfDimensionless" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->isVariantOfDimensionless();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_isVariantOfMass) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_isVariantOfMass(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_isVariantOfMass" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->isVariantOfMass();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_isVariantOfSubstancePerTime) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_isVariantOfSubstancePerTime(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_isVariantOfSubstancePerTime" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->isVariantOfSubstancePerTime();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_addUnit) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    Unit *arg2 = (Unit *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: UnitDefinition_addUnit(self,u);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_addUnit" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Unit, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "UnitDefinition_addUnit" "', argument " "2"" of type '" "Unit const *""'"); 
    }
    arg2 = reinterpret_cast< Unit * >(argp2);
    result = (int)(arg1)->addUnit((Unit const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_createUnit) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_createUnit(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_createUnit" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (Unit *)(arg1)->createUnit();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_getListOfUnits__SWIG_0) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfUnits *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_getListOfUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_getListOfUnits" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (ListOfUnits *)((UnitDefinition const *)arg1)->getListOfUnits();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfUnits, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_getListOfUnits__SWIG_1) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfUnits *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_getListOfUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_getListOfUnits" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (ListOfUnits *)(arg1)->getListOfUnits();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfUnits, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_getListOfUnits) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_UnitDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_UnitDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_UnitDefinition_getListOfUnits__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_UnitDefinition_getListOfUnits__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'UnitDefinition_getListOfUnits'");
  XSRETURN(0);
}


XS(_wrap_UnitDefinition_getUnit__SWIG_0) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: UnitDefinition_getUnit(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_getUnit" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "UnitDefinition_getUnit" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Unit *)(arg1)->getUnit(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_getUnit__SWIG_1) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: UnitDefinition_getUnit(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_getUnit" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "UnitDefinition_getUnit" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Unit *)((UnitDefinition const *)arg1)->getUnit(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_getUnit) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_UnitDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_UnitDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_UnitDefinition_getUnit__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_UnitDefinition_getUnit__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'UnitDefinition_getUnit'");
  XSRETURN(0);
}


XS(_wrap_UnitDefinition_getNumUnits) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_getNumUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_getNumUnits" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (unsigned int)((UnitDefinition const *)arg1)->getNumUnits();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_removeUnit) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Unit *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: UnitDefinition_removeUnit(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_removeUnit" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "UnitDefinition_removeUnit" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Unit *)(arg1)->removeUnit(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Unit, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_getTypeCode) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_getTypeCode" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (SBMLTypeCode_t)((UnitDefinition const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_getElementName) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_getElementName" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (std::string *) &((UnitDefinition const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_simplify) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_simplify(ud);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_simplify" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    UnitDefinition::simplify(arg1);
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_reorder) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_reorder(ud);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_reorder" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    UnitDefinition::reorder(arg1);
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_convertToSI) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_convertToSI(ud);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_convertToSI" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (UnitDefinition *)UnitDefinition::convertToSI((UnitDefinition const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_areIdentical) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    UnitDefinition *arg2 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: UnitDefinition_areIdentical(ud1,ud2);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_areIdentical" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "UnitDefinition_areIdentical" "', argument " "2"" of type '" "UnitDefinition const *""'"); 
    }
    arg2 = reinterpret_cast< UnitDefinition * >(argp2);
    result = (bool)UnitDefinition::areIdentical((UnitDefinition const *)arg1,(UnitDefinition const *)arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_areEquivalent) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    UnitDefinition *arg2 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: UnitDefinition_areEquivalent(ud1,ud2);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_areEquivalent" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "UnitDefinition_areEquivalent" "', argument " "2"" of type '" "UnitDefinition const *""'"); 
    }
    arg2 = reinterpret_cast< UnitDefinition * >(argp2);
    result = (bool)UnitDefinition::areEquivalent((UnitDefinition const *)arg1,(UnitDefinition const *)arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_combine) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    UnitDefinition *arg2 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: UnitDefinition_combine(ud1,ud2);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_combine" "', argument " "1"" of type '" "UnitDefinition *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "UnitDefinition_combine" "', argument " "2"" of type '" "UnitDefinition *""'"); 
    }
    arg2 = reinterpret_cast< UnitDefinition * >(argp2);
    result = (UnitDefinition *)UnitDefinition::combine(arg1,arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_printUnits__SWIG_0) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: UnitDefinition_printUnits(ud,compact);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_printUnits" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "UnitDefinition_printUnits" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = UnitDefinition::printUnits((UnitDefinition const *)arg1,arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_printUnits__SWIG_1) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_printUnits(ud);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_printUnits" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = UnitDefinition::printUnits((UnitDefinition const *)arg1);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_printUnits) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_UnitDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_UnitDefinition, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_UnitDefinition_printUnits__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_UnitDefinition_printUnits__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'UnitDefinition_printUnits'");
  XSRETURN(0);
}


XS(_wrap_UnitDefinition_hasRequiredAttributes) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_hasRequiredAttributes" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_UnitDefinition_hasRequiredElements) {
  {
    UnitDefinition *arg1 = (UnitDefinition *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: UnitDefinition_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_UnitDefinition, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "UnitDefinition_hasRequiredElements" "', argument " "1"" of type '" "UnitDefinition const *""'"); 
    }
    arg1 = reinterpret_cast< UnitDefinition * >(argp1);
    result = (bool)((UnitDefinition const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnitDefinitions_clone) {
  {
    ListOfUnitDefinitions *arg1 = (ListOfUnitDefinitions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfUnitDefinitions *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfUnitDefinitions_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnitDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnitDefinitions_clone" "', argument " "1"" of type '" "ListOfUnitDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnitDefinitions * >(argp1);
    result = (ListOfUnitDefinitions *)((ListOfUnitDefinitions const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfUnitDefinitions, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnitDefinitions_getTypeCode) {
  {
    ListOfUnitDefinitions *arg1 = (ListOfUnitDefinitions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfUnitDefinitions_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnitDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnitDefinitions_getTypeCode" "', argument " "1"" of type '" "ListOfUnitDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnitDefinitions * >(argp1);
    result = (SBMLTypeCode_t)((ListOfUnitDefinitions const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnitDefinitions_getItemTypeCode) {
  {
    ListOfUnitDefinitions *arg1 = (ListOfUnitDefinitions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfUnitDefinitions_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnitDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnitDefinitions_getItemTypeCode" "', argument " "1"" of type '" "ListOfUnitDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnitDefinitions * >(argp1);
    result = (SBMLTypeCode_t)((ListOfUnitDefinitions const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnitDefinitions_getElementName) {
  {
    ListOfUnitDefinitions *arg1 = (ListOfUnitDefinitions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfUnitDefinitions_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnitDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnitDefinitions_getElementName" "', argument " "1"" of type '" "ListOfUnitDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnitDefinitions * >(argp1);
    result = (std::string *) &((ListOfUnitDefinitions const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnitDefinitions_get__SWIG_0) {
  {
    ListOfUnitDefinitions *arg1 = (ListOfUnitDefinitions *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfUnitDefinitions_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnitDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnitDefinitions_get" "', argument " "1"" of type '" "ListOfUnitDefinitions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnitDefinitions * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfUnitDefinitions_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (UnitDefinition *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnitDefinitions_get__SWIG_1) {
  {
    ListOfUnitDefinitions *arg1 = (ListOfUnitDefinitions *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfUnitDefinitions_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnitDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnitDefinitions_get" "', argument " "1"" of type '" "ListOfUnitDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnitDefinitions * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfUnitDefinitions_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (UnitDefinition *)((ListOfUnitDefinitions const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnitDefinitions_get__SWIG_2) {
  {
    ListOfUnitDefinitions *arg1 = (ListOfUnitDefinitions *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfUnitDefinitions_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnitDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnitDefinitions_get" "', argument " "1"" of type '" "ListOfUnitDefinitions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnitDefinitions * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfUnitDefinitions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfUnitDefinitions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (UnitDefinition *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnitDefinitions_get__SWIG_3) {
  {
    ListOfUnitDefinitions *arg1 = (ListOfUnitDefinitions *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfUnitDefinitions_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnitDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnitDefinitions_get" "', argument " "1"" of type '" "ListOfUnitDefinitions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnitDefinitions * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfUnitDefinitions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfUnitDefinitions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (UnitDefinition *)((ListOfUnitDefinitions const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnitDefinitions_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfUnitDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfUnitDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfUnitDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfUnitDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfUnitDefinitions_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfUnitDefinitions_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfUnitDefinitions_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfUnitDefinitions_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfUnitDefinitions_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfUnitDefinitions_remove__SWIG_0) {
  {
    ListOfUnitDefinitions *arg1 = (ListOfUnitDefinitions *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfUnitDefinitions_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnitDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnitDefinitions_remove" "', argument " "1"" of type '" "ListOfUnitDefinitions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnitDefinitions * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfUnitDefinitions_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (UnitDefinition *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnitDefinitions_remove__SWIG_1) {
  {
    ListOfUnitDefinitions *arg1 = (ListOfUnitDefinitions *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfUnitDefinitions_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnitDefinitions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfUnitDefinitions_remove" "', argument " "1"" of type '" "ListOfUnitDefinitions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnitDefinitions * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfUnitDefinitions_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfUnitDefinitions_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (UnitDefinition *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfUnitDefinitions_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfUnitDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfUnitDefinitions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfUnitDefinitions_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfUnitDefinitions_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfUnitDefinitions_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfUnitDefinitions) {
  {
    int argvi = 0;
    ListOfUnitDefinitions *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfUnitDefinitions();");
    }
    result = (ListOfUnitDefinitions *)new ListOfUnitDefinitions();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfUnitDefinitions, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfUnitDefinitions) {
  {
    ListOfUnitDefinitions *arg1 = (ListOfUnitDefinitions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfUnitDefinitions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfUnitDefinitions, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfUnitDefinitions" "', argument " "1"" of type '" "ListOfUnitDefinitions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfUnitDefinitions * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_CompartmentType__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_CompartmentType(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_CompartmentType" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_CompartmentType" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (CompartmentType *)new CompartmentType(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_CompartmentType__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_CompartmentType(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_CompartmentType" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (CompartmentType *)new CompartmentType(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_CompartmentType) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_CompartmentType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_CompartmentType" "', argument " "1"" of type '" "CompartmentType *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_CompartmentType__SWIG_2) {
  {
    CompartmentType *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_CompartmentType(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_CompartmentType,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_CompartmentType" "', argument " "1"" of type '" "CompartmentType const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_CompartmentType" "', argument " "1"" of type '" "CompartmentType const &""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    {
      try {
        result = (CompartmentType *)new CompartmentType((CompartmentType const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_CompartmentType) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_CompartmentType, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_CompartmentType__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_CompartmentType__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_CompartmentType__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_CompartmentType'");
  XSRETURN(0);
}


XS(_wrap_CompartmentType_clone) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CompartmentType_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CompartmentType_clone" "', argument " "1"" of type '" "CompartmentType const *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    result = (CompartmentType *)((CompartmentType const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CompartmentType_getId) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CompartmentType_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CompartmentType_getId" "', argument " "1"" of type '" "CompartmentType const *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    result = (std::string *) &((CompartmentType const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CompartmentType_getName) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CompartmentType_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CompartmentType_getName" "', argument " "1"" of type '" "CompartmentType const *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    result = (std::string *) &((CompartmentType const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CompartmentType_isSetId) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CompartmentType_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CompartmentType_isSetId" "', argument " "1"" of type '" "CompartmentType const *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    result = (bool)((CompartmentType const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CompartmentType_isSetName) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CompartmentType_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CompartmentType_isSetName" "', argument " "1"" of type '" "CompartmentType const *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    result = (bool)((CompartmentType const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CompartmentType_setId) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CompartmentType_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CompartmentType_setId" "', argument " "1"" of type '" "CompartmentType *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "CompartmentType_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "CompartmentType_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_CompartmentType_setName) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CompartmentType_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CompartmentType_setName" "', argument " "1"" of type '" "CompartmentType *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "CompartmentType_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "CompartmentType_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_CompartmentType_unsetName) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CompartmentType_unsetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CompartmentType_unsetName" "', argument " "1"" of type '" "CompartmentType *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    result = (int)(arg1)->unsetName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CompartmentType_getTypeCode) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CompartmentType_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CompartmentType_getTypeCode" "', argument " "1"" of type '" "CompartmentType const *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    result = (SBMLTypeCode_t)((CompartmentType const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CompartmentType_getElementName) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CompartmentType_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CompartmentType_getElementName" "', argument " "1"" of type '" "CompartmentType const *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    result = (std::string *) &((CompartmentType const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CompartmentType_hasRequiredAttributes) {
  {
    CompartmentType *arg1 = (CompartmentType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CompartmentType_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CompartmentType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CompartmentType_hasRequiredAttributes" "', argument " "1"" of type '" "CompartmentType const *""'"); 
    }
    arg1 = reinterpret_cast< CompartmentType * >(argp1);
    result = (bool)((CompartmentType const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartmentTypes_clone) {
  {
    ListOfCompartmentTypes *arg1 = (ListOfCompartmentTypes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfCompartmentTypes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfCompartmentTypes_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartmentTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartmentTypes_clone" "', argument " "1"" of type '" "ListOfCompartmentTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartmentTypes * >(argp1);
    result = (ListOfCompartmentTypes *)((ListOfCompartmentTypes const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfCompartmentTypes, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartmentTypes_getTypeCode) {
  {
    ListOfCompartmentTypes *arg1 = (ListOfCompartmentTypes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfCompartmentTypes_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartmentTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartmentTypes_getTypeCode" "', argument " "1"" of type '" "ListOfCompartmentTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartmentTypes * >(argp1);
    result = (SBMLTypeCode_t)((ListOfCompartmentTypes const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartmentTypes_getItemTypeCode) {
  {
    ListOfCompartmentTypes *arg1 = (ListOfCompartmentTypes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfCompartmentTypes_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartmentTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartmentTypes_getItemTypeCode" "', argument " "1"" of type '" "ListOfCompartmentTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartmentTypes * >(argp1);
    result = (SBMLTypeCode_t)((ListOfCompartmentTypes const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartmentTypes_getElementName) {
  {
    ListOfCompartmentTypes *arg1 = (ListOfCompartmentTypes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfCompartmentTypes_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartmentTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartmentTypes_getElementName" "', argument " "1"" of type '" "ListOfCompartmentTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartmentTypes * >(argp1);
    result = (std::string *) &((ListOfCompartmentTypes const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartmentTypes_get__SWIG_0) {
  {
    ListOfCompartmentTypes *arg1 = (ListOfCompartmentTypes *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartmentTypes_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartmentTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartmentTypes_get" "', argument " "1"" of type '" "ListOfCompartmentTypes *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartmentTypes * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfCompartmentTypes_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (CompartmentType *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartmentTypes_get__SWIG_1) {
  {
    ListOfCompartmentTypes *arg1 = (ListOfCompartmentTypes *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartmentTypes_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartmentTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartmentTypes_get" "', argument " "1"" of type '" "ListOfCompartmentTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartmentTypes * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfCompartmentTypes_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (CompartmentType *)((ListOfCompartmentTypes const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartmentTypes_get__SWIG_2) {
  {
    ListOfCompartmentTypes *arg1 = (ListOfCompartmentTypes *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartmentTypes_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartmentTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartmentTypes_get" "', argument " "1"" of type '" "ListOfCompartmentTypes *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartmentTypes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfCompartmentTypes_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfCompartmentTypes_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (CompartmentType *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartmentTypes_get__SWIG_3) {
  {
    ListOfCompartmentTypes *arg1 = (ListOfCompartmentTypes *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartmentTypes_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartmentTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartmentTypes_get" "', argument " "1"" of type '" "ListOfCompartmentTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartmentTypes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfCompartmentTypes_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfCompartmentTypes_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (CompartmentType *)((ListOfCompartmentTypes const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartmentTypes_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartmentTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartmentTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartmentTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartmentTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartmentTypes_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartmentTypes_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartmentTypes_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartmentTypes_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfCompartmentTypes_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfCompartmentTypes_remove__SWIG_0) {
  {
    ListOfCompartmentTypes *arg1 = (ListOfCompartmentTypes *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartmentTypes_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartmentTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartmentTypes_remove" "', argument " "1"" of type '" "ListOfCompartmentTypes *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartmentTypes * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfCompartmentTypes_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (CompartmentType *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartmentTypes_remove__SWIG_1) {
  {
    ListOfCompartmentTypes *arg1 = (ListOfCompartmentTypes *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    CompartmentType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartmentTypes_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartmentTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartmentTypes_remove" "', argument " "1"" of type '" "ListOfCompartmentTypes *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartmentTypes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfCompartmentTypes_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfCompartmentTypes_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (CompartmentType *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CompartmentType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartmentTypes_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartmentTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartmentTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartmentTypes_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartmentTypes_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfCompartmentTypes_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfCompartmentTypes) {
  {
    int argvi = 0;
    ListOfCompartmentTypes *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfCompartmentTypes();");
    }
    result = (ListOfCompartmentTypes *)new ListOfCompartmentTypes();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfCompartmentTypes, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfCompartmentTypes) {
  {
    ListOfCompartmentTypes *arg1 = (ListOfCompartmentTypes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfCompartmentTypes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartmentTypes, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfCompartmentTypes" "', argument " "1"" of type '" "ListOfCompartmentTypes *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartmentTypes * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SpeciesType__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_SpeciesType(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SpeciesType" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_SpeciesType" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (SpeciesType *)new SpeciesType(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SpeciesType__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SpeciesType(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_SpeciesType" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (SpeciesType *)new SpeciesType(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SpeciesType) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SpeciesType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SpeciesType" "', argument " "1"" of type '" "SpeciesType *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SpeciesType__SWIG_2) {
  {
    SpeciesType *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SpeciesType(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_SpeciesType,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_SpeciesType" "', argument " "1"" of type '" "SpeciesType const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_SpeciesType" "', argument " "1"" of type '" "SpeciesType const &""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    {
      try {
        result = (SpeciesType *)new SpeciesType((SpeciesType const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SpeciesType) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SpeciesType, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SpeciesType__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SpeciesType__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SpeciesType__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_SpeciesType'");
  XSRETURN(0);
}


XS(_wrap_SpeciesType_clone) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesType_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesType_clone" "', argument " "1"" of type '" "SpeciesType const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    result = (SpeciesType *)((SpeciesType const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesType_getId) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesType_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesType_getId" "', argument " "1"" of type '" "SpeciesType const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    result = (std::string *) &((SpeciesType const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesType_getName) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesType_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesType_getName" "', argument " "1"" of type '" "SpeciesType const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    result = (std::string *) &((SpeciesType const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesType_isSetId) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesType_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesType_isSetId" "', argument " "1"" of type '" "SpeciesType const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    result = (bool)((SpeciesType const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesType_isSetName) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesType_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesType_isSetName" "', argument " "1"" of type '" "SpeciesType const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    result = (bool)((SpeciesType const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesType_setId) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SpeciesType_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesType_setId" "', argument " "1"" of type '" "SpeciesType *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SpeciesType_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SpeciesType_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesType_setName) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SpeciesType_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesType_setName" "', argument " "1"" of type '" "SpeciesType *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SpeciesType_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SpeciesType_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesType_unsetName) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesType_unsetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesType_unsetName" "', argument " "1"" of type '" "SpeciesType *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    result = (int)(arg1)->unsetName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesType_getTypeCode) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesType_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesType_getTypeCode" "', argument " "1"" of type '" "SpeciesType const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    result = (SBMLTypeCode_t)((SpeciesType const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesType_getElementName) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesType_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesType_getElementName" "', argument " "1"" of type '" "SpeciesType const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    result = (std::string *) &((SpeciesType const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesType_hasRequiredAttributes) {
  {
    SpeciesType *arg1 = (SpeciesType *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesType_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesType, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesType_hasRequiredAttributes" "', argument " "1"" of type '" "SpeciesType const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesType * >(argp1);
    result = (bool)((SpeciesType const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesTypes_clone) {
  {
    ListOfSpeciesTypes *arg1 = (ListOfSpeciesTypes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpeciesTypes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpeciesTypes_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesTypes_clone" "', argument " "1"" of type '" "ListOfSpeciesTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesTypes * >(argp1);
    result = (ListOfSpeciesTypes *)((ListOfSpeciesTypes const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesTypes, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesTypes_getTypeCode) {
  {
    ListOfSpeciesTypes *arg1 = (ListOfSpeciesTypes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpeciesTypes_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesTypes_getTypeCode" "', argument " "1"" of type '" "ListOfSpeciesTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesTypes * >(argp1);
    result = (SBMLTypeCode_t)((ListOfSpeciesTypes const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesTypes_getItemTypeCode) {
  {
    ListOfSpeciesTypes *arg1 = (ListOfSpeciesTypes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpeciesTypes_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesTypes_getItemTypeCode" "', argument " "1"" of type '" "ListOfSpeciesTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesTypes * >(argp1);
    result = (SBMLTypeCode_t)((ListOfSpeciesTypes const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesTypes_getElementName) {
  {
    ListOfSpeciesTypes *arg1 = (ListOfSpeciesTypes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpeciesTypes_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesTypes_getElementName" "', argument " "1"" of type '" "ListOfSpeciesTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesTypes * >(argp1);
    result = (std::string *) &((ListOfSpeciesTypes const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesTypes_get__SWIG_0) {
  {
    ListOfSpeciesTypes *arg1 = (ListOfSpeciesTypes *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesTypes_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesTypes_get" "', argument " "1"" of type '" "ListOfSpeciesTypes *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesTypes * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfSpeciesTypes_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesType *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesTypes_get__SWIG_1) {
  {
    ListOfSpeciesTypes *arg1 = (ListOfSpeciesTypes *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesTypes_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesTypes_get" "', argument " "1"" of type '" "ListOfSpeciesTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesTypes * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfSpeciesTypes_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesType *)((ListOfSpeciesTypes const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesTypes_get__SWIG_2) {
  {
    ListOfSpeciesTypes *arg1 = (ListOfSpeciesTypes *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesTypes_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesTypes_get" "', argument " "1"" of type '" "ListOfSpeciesTypes *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesTypes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfSpeciesTypes_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfSpeciesTypes_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesType *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesTypes_get__SWIG_3) {
  {
    ListOfSpeciesTypes *arg1 = (ListOfSpeciesTypes *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesTypes_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesTypes_get" "', argument " "1"" of type '" "ListOfSpeciesTypes const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesTypes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfSpeciesTypes_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfSpeciesTypes_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesType *)((ListOfSpeciesTypes const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesTypes_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesTypes_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesTypes_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesTypes_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesTypes_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfSpeciesTypes_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfSpeciesTypes_remove__SWIG_0) {
  {
    ListOfSpeciesTypes *arg1 = (ListOfSpeciesTypes *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesTypes_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesTypes_remove" "', argument " "1"" of type '" "ListOfSpeciesTypes *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesTypes * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfSpeciesTypes_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesType *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesTypes_remove__SWIG_1) {
  {
    ListOfSpeciesTypes *arg1 = (ListOfSpeciesTypes *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesType *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesTypes_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesTypes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesTypes_remove" "', argument " "1"" of type '" "ListOfSpeciesTypes *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesTypes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfSpeciesTypes_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfSpeciesTypes_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesType *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesType, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesTypes_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesTypes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesTypes_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesTypes_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfSpeciesTypes_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfSpeciesTypes) {
  {
    int argvi = 0;
    ListOfSpeciesTypes *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfSpeciesTypes();");
    }
    result = (ListOfSpeciesTypes *)new ListOfSpeciesTypes();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesTypes, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfSpeciesTypes) {
  {
    ListOfSpeciesTypes *arg1 = (ListOfSpeciesTypes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfSpeciesTypes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesTypes, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfSpeciesTypes" "', argument " "1"" of type '" "ListOfSpeciesTypes *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesTypes * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Compartment__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Compartment(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Compartment" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Compartment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (Compartment *)new Compartment(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Compartment__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Compartment(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Compartment" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (Compartment *)new Compartment(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Compartment) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Compartment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Compartment" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Compartment__SWIG_2) {
  {
    Compartment *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Compartment(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Compartment,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Compartment" "', argument " "1"" of type '" "Compartment const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Compartment" "', argument " "1"" of type '" "Compartment const &""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    {
      try {
        result = (Compartment *)new Compartment((Compartment const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Compartment) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Compartment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Compartment__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Compartment__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Compartment__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Compartment'");
  XSRETURN(0);
}


XS(_wrap_Compartment_clone) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_clone" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (Compartment *)((Compartment const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_initDefaults) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_initDefaults(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_initDefaults" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    (arg1)->initDefaults();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getId) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getId" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (std::string *) &((Compartment const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getName) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getName" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (std::string *) &((Compartment const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getCompartmentType) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getCompartmentType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getCompartmentType" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (std::string *) &((Compartment const *)arg1)->getCompartmentType();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getSpatialDimensions) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getSpatialDimensions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getSpatialDimensions" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (unsigned int)((Compartment const *)arg1)->getSpatialDimensions();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getSpatialDimensionsAsDouble) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getSpatialDimensionsAsDouble(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getSpatialDimensionsAsDouble" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (double)((Compartment const *)arg1)->getSpatialDimensionsAsDouble();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getSize) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getSize(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getSize" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (double)((Compartment const *)arg1)->getSize();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getVolume) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getVolume(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getVolume" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (double)((Compartment const *)arg1)->getVolume();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getUnits) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getUnits" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (std::string *) &((Compartment const *)arg1)->getUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getOutside) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getOutside(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getOutside" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (std::string *) &((Compartment const *)arg1)->getOutside();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getConstant) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getConstant(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getConstant" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (bool)((Compartment const *)arg1)->getConstant();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_isSetId) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_isSetId" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (bool)((Compartment const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_isSetName) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_isSetName" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (bool)((Compartment const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_isSetCompartmentType) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_isSetCompartmentType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_isSetCompartmentType" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (bool)((Compartment const *)arg1)->isSetCompartmentType();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_isSetSize) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_isSetSize(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_isSetSize" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (bool)((Compartment const *)arg1)->isSetSize();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_isSetVolume) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_isSetVolume(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_isSetVolume" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (bool)((Compartment const *)arg1)->isSetVolume();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_isSetUnits) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_isSetUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_isSetUnits" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (bool)((Compartment const *)arg1)->isSetUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_isSetOutside) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_isSetOutside(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_isSetOutside" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (bool)((Compartment const *)arg1)->isSetOutside();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_isSetSpatialDimensions) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_isSetSpatialDimensions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_isSetSpatialDimensions" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (bool)((Compartment const *)arg1)->isSetSpatialDimensions();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_isSetConstant) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_isSetConstant(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_isSetConstant" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (bool)((Compartment const *)arg1)->isSetConstant();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_setId) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Compartment_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_setId" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Compartment_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Compartment_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_setName) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Compartment_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_setName" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Compartment_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Compartment_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_setCompartmentType) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Compartment_setCompartmentType(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_setCompartmentType" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Compartment_setCompartmentType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Compartment_setCompartmentType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setCompartmentType((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_setSpatialDimensions__SWIG_0) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Compartment_setSpatialDimensions(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_setSpatialDimensions" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Compartment_setSpatialDimensions" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setSpatialDimensions(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_setSpatialDimensions__SWIG_1) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Compartment_setSpatialDimensions(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_setSpatialDimensions" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Compartment_setSpatialDimensions" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    result = (int)(arg1)->setSpatialDimensions(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_setSpatialDimensions) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Compartment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Compartment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Compartment_setSpatialDimensions__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Compartment_setSpatialDimensions__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Compartment_setSpatialDimensions'");
  XSRETURN(0);
}


XS(_wrap_Compartment_setSize) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Compartment_setSize(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_setSize" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Compartment_setSize" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    result = (int)(arg1)->setSize(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_setVolume) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Compartment_setVolume(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_setVolume" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Compartment_setVolume" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    result = (int)(arg1)->setVolume(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_setUnits) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Compartment_setUnits(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_setUnits" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Compartment_setUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Compartment_setUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_setOutside) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Compartment_setOutside(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_setOutside" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Compartment_setOutside" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Compartment_setOutside" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setOutside((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_setConstant) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Compartment_setConstant(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_setConstant" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Compartment_setConstant" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (int)(arg1)->setConstant(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_unsetName) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_unsetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_unsetName" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (int)(arg1)->unsetName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_unsetCompartmentType) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_unsetCompartmentType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_unsetCompartmentType" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (int)(arg1)->unsetCompartmentType();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_unsetSize) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_unsetSize(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_unsetSize" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (int)(arg1)->unsetSize();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_unsetVolume) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_unsetVolume(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_unsetVolume" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (int)(arg1)->unsetVolume();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_unsetUnits) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_unsetUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_unsetUnits" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (int)(arg1)->unsetUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_unsetOutside) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_unsetOutside(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_unsetOutside" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (int)(arg1)->unsetOutside();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_unsetSpatialDimensions) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_unsetSpatialDimensions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_unsetSpatialDimensions" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (int)(arg1)->unsetSpatialDimensions();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getDerivedUnitDefinition__SWIG_0) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getDerivedUnitDefinition" "', argument " "1"" of type '" "Compartment *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (UnitDefinition *)(arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getDerivedUnitDefinition__SWIG_1) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getDerivedUnitDefinition" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (UnitDefinition *)((Compartment const *)arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getDerivedUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Compartment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Compartment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Compartment_getDerivedUnitDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Compartment_getDerivedUnitDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Compartment_getDerivedUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_Compartment_getTypeCode) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getTypeCode" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (SBMLTypeCode_t)((Compartment const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_getElementName) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_getElementName" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (std::string *) &((Compartment const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Compartment_hasRequiredAttributes) {
  {
    Compartment *arg1 = (Compartment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Compartment_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Compartment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Compartment_hasRequiredAttributes" "', argument " "1"" of type '" "Compartment const *""'"); 
    }
    arg1 = reinterpret_cast< Compartment * >(argp1);
    result = (bool)((Compartment const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartments_clone) {
  {
    ListOfCompartments *arg1 = (ListOfCompartments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfCompartments *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfCompartments_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartments_clone" "', argument " "1"" of type '" "ListOfCompartments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartments * >(argp1);
    result = (ListOfCompartments *)((ListOfCompartments const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfCompartments, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartments_getTypeCode) {
  {
    ListOfCompartments *arg1 = (ListOfCompartments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfCompartments_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartments_getTypeCode" "', argument " "1"" of type '" "ListOfCompartments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartments * >(argp1);
    result = (SBMLTypeCode_t)((ListOfCompartments const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartments_getItemTypeCode) {
  {
    ListOfCompartments *arg1 = (ListOfCompartments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfCompartments_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartments_getItemTypeCode" "', argument " "1"" of type '" "ListOfCompartments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartments * >(argp1);
    result = (SBMLTypeCode_t)((ListOfCompartments const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartments_getElementName) {
  {
    ListOfCompartments *arg1 = (ListOfCompartments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfCompartments_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartments_getElementName" "', argument " "1"" of type '" "ListOfCompartments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartments * >(argp1);
    result = (std::string *) &((ListOfCompartments const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartments_get__SWIG_0) {
  {
    ListOfCompartments *arg1 = (ListOfCompartments *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartments_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartments_get" "', argument " "1"" of type '" "ListOfCompartments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartments * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfCompartments_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Compartment *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartments_get__SWIG_1) {
  {
    ListOfCompartments *arg1 = (ListOfCompartments *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartments_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartments_get" "', argument " "1"" of type '" "ListOfCompartments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartments * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfCompartments_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Compartment *)((ListOfCompartments const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartments_get__SWIG_2) {
  {
    ListOfCompartments *arg1 = (ListOfCompartments *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartments_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartments_get" "', argument " "1"" of type '" "ListOfCompartments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartments * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfCompartments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfCompartments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Compartment *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartments_get__SWIG_3) {
  {
    ListOfCompartments *arg1 = (ListOfCompartments *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartments_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartments_get" "', argument " "1"" of type '" "ListOfCompartments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartments * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfCompartments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfCompartments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Compartment *)((ListOfCompartments const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartments_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartments_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartments_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartments_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartments_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfCompartments_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfCompartments_remove__SWIG_0) {
  {
    ListOfCompartments *arg1 = (ListOfCompartments *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartments_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartments_remove" "', argument " "1"" of type '" "ListOfCompartments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartments * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfCompartments_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Compartment *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartments_remove__SWIG_1) {
  {
    ListOfCompartments *arg1 = (ListOfCompartments *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Compartment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfCompartments_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfCompartments_remove" "', argument " "1"" of type '" "ListOfCompartments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartments * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfCompartments_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfCompartments_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Compartment *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Compartment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfCompartments_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfCompartments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartments_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfCompartments_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfCompartments_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfCompartments) {
  {
    int argvi = 0;
    ListOfCompartments *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfCompartments();");
    }
    result = (ListOfCompartments *)new ListOfCompartments();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfCompartments, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfCompartments) {
  {
    ListOfCompartments *arg1 = (ListOfCompartments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfCompartments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfCompartments, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfCompartments" "', argument " "1"" of type '" "ListOfCompartments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfCompartments * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Species__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Species(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Species" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Species" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (Species *)new Species(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Species__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Species(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Species" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (Species *)new Species(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Species) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Species(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Species" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Species__SWIG_2) {
  {
    Species *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Species(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Species,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Species" "', argument " "1"" of type '" "Species const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Species" "', argument " "1"" of type '" "Species const &""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    {
      try {
        result = (Species *)new Species((Species const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Species) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Species, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Species__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Species__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Species__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Species'");
  XSRETURN(0);
}


XS(_wrap_Species_clone) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_clone" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (Species *)((Species const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_initDefaults) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_initDefaults(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_initDefaults" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    (arg1)->initDefaults();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getId) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getId" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (std::string *) &((Species const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getName) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getName" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (std::string *) &((Species const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getSpeciesType) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getSpeciesType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getSpeciesType" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (std::string *) &((Species const *)arg1)->getSpeciesType();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getCompartment) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getCompartment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getCompartment" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (std::string *) &((Species const *)arg1)->getCompartment();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getInitialAmount) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getInitialAmount(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getInitialAmount" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (double)((Species const *)arg1)->getInitialAmount();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getInitialConcentration) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getInitialConcentration(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getInitialConcentration" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (double)((Species const *)arg1)->getInitialConcentration();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getSubstanceUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getSubstanceUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getSubstanceUnits" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (std::string *) &((Species const *)arg1)->getSubstanceUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getSpatialSizeUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getSpatialSizeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getSpatialSizeUnits" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (std::string *) &((Species const *)arg1)->getSpatialSizeUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getUnits" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (std::string *) &((Species const *)arg1)->getUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getHasOnlySubstanceUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getHasOnlySubstanceUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getHasOnlySubstanceUnits" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->getHasOnlySubstanceUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getBoundaryCondition) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getBoundaryCondition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getBoundaryCondition" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->getBoundaryCondition();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getCharge) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getCharge(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getCharge" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (int)((Species const *)arg1)->getCharge();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getConstant) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getConstant(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getConstant" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->getConstant();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getConversionFactor) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getConversionFactor(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getConversionFactor" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (std::string *) &((Species const *)arg1)->getConversionFactor();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetId) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetId" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetName) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetName" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetSpeciesType) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetSpeciesType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetSpeciesType" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetSpeciesType();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetCompartment) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetCompartment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetCompartment" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetCompartment();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetInitialAmount) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetInitialAmount(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetInitialAmount" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetInitialAmount();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetInitialConcentration) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetInitialConcentration(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetInitialConcentration" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetInitialConcentration();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetSubstanceUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetSubstanceUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetSubstanceUnits" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetSubstanceUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetSpatialSizeUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetSpatialSizeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetSpatialSizeUnits" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetSpatialSizeUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetUnits" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetCharge) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetCharge(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetCharge" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetCharge();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetConversionFactor) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetConversionFactor(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetConversionFactor" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetConversionFactor();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetBoundaryCondition) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetBoundaryCondition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetBoundaryCondition" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetBoundaryCondition();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetHasOnlySubstanceUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetHasOnlySubstanceUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetHasOnlySubstanceUnits" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetHasOnlySubstanceUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_isSetConstant) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_isSetConstant(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_isSetConstant" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->isSetConstant();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setId) {
  {
    Species *arg1 = (Species *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setId" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Species_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Species_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setName) {
  {
    Species *arg1 = (Species *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setName" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Species_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Species_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setSpeciesType) {
  {
    Species *arg1 = (Species *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setSpeciesType(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setSpeciesType" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Species_setSpeciesType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Species_setSpeciesType" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setSpeciesType((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setCompartment) {
  {
    Species *arg1 = (Species *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setCompartment(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setCompartment" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Species_setCompartment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Species_setCompartment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setCompartment((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setInitialAmount) {
  {
    Species *arg1 = (Species *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setInitialAmount(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setInitialAmount" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Species_setInitialAmount" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    result = (int)(arg1)->setInitialAmount(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setInitialConcentration) {
  {
    Species *arg1 = (Species *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setInitialConcentration(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setInitialConcentration" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Species_setInitialConcentration" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    result = (int)(arg1)->setInitialConcentration(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setSubstanceUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setSubstanceUnits(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setSubstanceUnits" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Species_setSubstanceUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Species_setSubstanceUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setSubstanceUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setSpatialSizeUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setSpatialSizeUnits(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setSpatialSizeUnits" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Species_setSpatialSizeUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Species_setSpatialSizeUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setSpatialSizeUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setUnits(self,sname);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setUnits" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Species_setUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Species_setUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setHasOnlySubstanceUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setHasOnlySubstanceUnits(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setHasOnlySubstanceUnits" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Species_setHasOnlySubstanceUnits" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (int)(arg1)->setHasOnlySubstanceUnits(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setBoundaryCondition) {
  {
    Species *arg1 = (Species *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setBoundaryCondition(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setBoundaryCondition" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Species_setBoundaryCondition" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (int)(arg1)->setBoundaryCondition(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setCharge) {
  {
    Species *arg1 = (Species *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setCharge(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setCharge" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Species_setCharge" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (int)(arg1)->setCharge(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setConstant) {
  {
    Species *arg1 = (Species *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setConstant(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setConstant" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Species_setConstant" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (int)(arg1)->setConstant(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_setConversionFactor) {
  {
    Species *arg1 = (Species *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Species_setConversionFactor(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_setConversionFactor" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Species_setConversionFactor" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Species_setConversionFactor" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setConversionFactor((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Species_unsetName) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_unsetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_unsetName" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (int)(arg1)->unsetName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_unsetSpeciesType) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_unsetSpeciesType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_unsetSpeciesType" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (int)(arg1)->unsetSpeciesType();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_unsetInitialAmount) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_unsetInitialAmount(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_unsetInitialAmount" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (int)(arg1)->unsetInitialAmount();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_unsetInitialConcentration) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_unsetInitialConcentration(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_unsetInitialConcentration" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (int)(arg1)->unsetInitialConcentration();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_unsetSubstanceUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_unsetSubstanceUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_unsetSubstanceUnits" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (int)(arg1)->unsetSubstanceUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_unsetSpatialSizeUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_unsetSpatialSizeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_unsetSpatialSizeUnits" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (int)(arg1)->unsetSpatialSizeUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_unsetUnits) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_unsetUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_unsetUnits" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (int)(arg1)->unsetUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_unsetCharge) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_unsetCharge(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_unsetCharge" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (int)(arg1)->unsetCharge();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_unsetConversionFactor) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_unsetConversionFactor(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_unsetConversionFactor" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (int)(arg1)->unsetConversionFactor();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getDerivedUnitDefinition__SWIG_0) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getDerivedUnitDefinition" "', argument " "1"" of type '" "Species *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (UnitDefinition *)(arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getDerivedUnitDefinition__SWIG_1) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getDerivedUnitDefinition" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (UnitDefinition *)((Species const *)arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getDerivedUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Species, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Species, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Species_getDerivedUnitDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Species_getDerivedUnitDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Species_getDerivedUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_Species_getTypeCode) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getTypeCode" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (SBMLTypeCode_t)((Species const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_getElementName) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_getElementName" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (std::string *) &((Species const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Species_hasRequiredAttributes) {
  {
    Species *arg1 = (Species *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Species_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Species, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Species_hasRequiredAttributes" "', argument " "1"" of type '" "Species const *""'"); 
    }
    arg1 = reinterpret_cast< Species * >(argp1);
    result = (bool)((Species const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpecies_clone) {
  {
    ListOfSpecies *arg1 = (ListOfSpecies *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpecies *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpecies_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpecies, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpecies_clone" "', argument " "1"" of type '" "ListOfSpecies const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpecies * >(argp1);
    result = (ListOfSpecies *)((ListOfSpecies const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpecies, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpecies_getTypeCode) {
  {
    ListOfSpecies *arg1 = (ListOfSpecies *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpecies_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpecies, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpecies_getTypeCode" "', argument " "1"" of type '" "ListOfSpecies const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpecies * >(argp1);
    result = (SBMLTypeCode_t)((ListOfSpecies const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpecies_getItemTypeCode) {
  {
    ListOfSpecies *arg1 = (ListOfSpecies *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpecies_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpecies, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpecies_getItemTypeCode" "', argument " "1"" of type '" "ListOfSpecies const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpecies * >(argp1);
    result = (SBMLTypeCode_t)((ListOfSpecies const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpecies_getElementName) {
  {
    ListOfSpecies *arg1 = (ListOfSpecies *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpecies_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpecies, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpecies_getElementName" "', argument " "1"" of type '" "ListOfSpecies const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpecies * >(argp1);
    result = (std::string *) &((ListOfSpecies const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpecies_get__SWIG_0) {
  {
    ListOfSpecies *arg1 = (ListOfSpecies *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpecies_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpecies, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpecies_get" "', argument " "1"" of type '" "ListOfSpecies *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpecies * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfSpecies_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Species *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpecies_get__SWIG_1) {
  {
    ListOfSpecies *arg1 = (ListOfSpecies *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpecies_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpecies, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpecies_get" "', argument " "1"" of type '" "ListOfSpecies const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpecies * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfSpecies_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Species *)((ListOfSpecies const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpecies_get__SWIG_2) {
  {
    ListOfSpecies *arg1 = (ListOfSpecies *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpecies_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpecies, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpecies_get" "', argument " "1"" of type '" "ListOfSpecies *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpecies * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfSpecies_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfSpecies_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Species *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpecies_get__SWIG_3) {
  {
    ListOfSpecies *arg1 = (ListOfSpecies *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpecies_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpecies, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpecies_get" "', argument " "1"" of type '" "ListOfSpecies const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpecies * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfSpecies_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfSpecies_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Species *)((ListOfSpecies const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpecies_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpecies, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpecies, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpecies, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpecies, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpecies_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpecies_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpecies_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpecies_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfSpecies_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfSpecies_remove__SWIG_0) {
  {
    ListOfSpecies *arg1 = (ListOfSpecies *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpecies_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpecies, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpecies_remove" "', argument " "1"" of type '" "ListOfSpecies *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpecies * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfSpecies_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Species *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpecies_remove__SWIG_1) {
  {
    ListOfSpecies *arg1 = (ListOfSpecies *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Species *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpecies_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpecies, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpecies_remove" "', argument " "1"" of type '" "ListOfSpecies *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpecies * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfSpecies_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfSpecies_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Species *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Species, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpecies_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpecies, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpecies, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpecies_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpecies_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfSpecies_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfSpecies) {
  {
    int argvi = 0;
    ListOfSpecies *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfSpecies();");
    }
    result = (ListOfSpecies *)new ListOfSpecies();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpecies, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfSpecies) {
  {
    ListOfSpecies *arg1 = (ListOfSpecies *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfSpecies(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpecies, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfSpecies" "', argument " "1"" of type '" "ListOfSpecies *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpecies * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Parameter__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Parameter(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Parameter" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Parameter" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (Parameter *)new Parameter(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Parameter__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Parameter(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Parameter" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (Parameter *)new Parameter(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Parameter) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Parameter(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Parameter" "', argument " "1"" of type '" "Parameter *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Parameter__SWIG_2) {
  {
    Parameter *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Parameter(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Parameter,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Parameter" "', argument " "1"" of type '" "Parameter const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Parameter" "', argument " "1"" of type '" "Parameter const &""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    {
      try {
        result = (Parameter *)new Parameter((Parameter const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Parameter) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Parameter, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Parameter__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Parameter__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Parameter__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Parameter'");
  XSRETURN(0);
}


XS(_wrap_Parameter_clone) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_clone" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (Parameter *)((Parameter const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_initDefaults) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_initDefaults(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_initDefaults" "', argument " "1"" of type '" "Parameter *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    (arg1)->initDefaults();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_getId) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_getId" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (std::string *) &((Parameter const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_getName) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_getName" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (std::string *) &((Parameter const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_getValue) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_getValue(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_getValue" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (double)((Parameter const *)arg1)->getValue();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_getUnits) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_getUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_getUnits" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (std::string *) &((Parameter const *)arg1)->getUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_getConstant) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_getConstant(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_getConstant" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (bool)((Parameter const *)arg1)->getConstant();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_isSetId) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_isSetId" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (bool)((Parameter const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_isSetName) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_isSetName" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (bool)((Parameter const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_isSetValue) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_isSetValue(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_isSetValue" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (bool)((Parameter const *)arg1)->isSetValue();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_isSetUnits) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_isSetUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_isSetUnits" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (bool)((Parameter const *)arg1)->isSetUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_isSetConstant) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_isSetConstant(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_isSetConstant" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (bool)((Parameter const *)arg1)->isSetConstant();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_setId) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Parameter_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_setId" "', argument " "1"" of type '" "Parameter *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Parameter_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Parameter_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_setName) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Parameter_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_setName" "', argument " "1"" of type '" "Parameter *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Parameter_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Parameter_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_setValue) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Parameter_setValue(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_setValue" "', argument " "1"" of type '" "Parameter *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Parameter_setValue" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    result = (int)(arg1)->setValue(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_setUnits) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Parameter_setUnits(self,units);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_setUnits" "', argument " "1"" of type '" "Parameter *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Parameter_setUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Parameter_setUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_setConstant) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Parameter_setConstant(self,flag);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_setConstant" "', argument " "1"" of type '" "Parameter *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Parameter_setConstant" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (int)(arg1)->setConstant(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_unsetName) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_unsetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_unsetName" "', argument " "1"" of type '" "Parameter *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (int)(arg1)->unsetName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_unsetValue) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_unsetValue(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_unsetValue" "', argument " "1"" of type '" "Parameter *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (int)(arg1)->unsetValue();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_unsetUnits) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_unsetUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_unsetUnits" "', argument " "1"" of type '" "Parameter *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (int)(arg1)->unsetUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_getDerivedUnitDefinition__SWIG_0) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_getDerivedUnitDefinition" "', argument " "1"" of type '" "Parameter *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (UnitDefinition *)(arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_getDerivedUnitDefinition__SWIG_1) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_getDerivedUnitDefinition" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (UnitDefinition *)((Parameter const *)arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_getDerivedUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Parameter, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Parameter, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Parameter_getDerivedUnitDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Parameter_getDerivedUnitDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Parameter_getDerivedUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_Parameter_getTypeCode) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_getTypeCode" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (SBMLTypeCode_t)((Parameter const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_getElementName) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_getElementName" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (std::string *) &((Parameter const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Parameter_hasRequiredAttributes) {
  {
    Parameter *arg1 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Parameter_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Parameter_hasRequiredAttributes" "', argument " "1"" of type '" "Parameter const *""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    result = (bool)((Parameter const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfParameters_clone) {
  {
    ListOfParameters *arg1 = (ListOfParameters *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfParameters *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfParameters_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfParameters_clone" "', argument " "1"" of type '" "ListOfParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfParameters * >(argp1);
    result = (ListOfParameters *)((ListOfParameters const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfParameters, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfParameters_getTypeCode) {
  {
    ListOfParameters *arg1 = (ListOfParameters *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfParameters_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfParameters_getTypeCode" "', argument " "1"" of type '" "ListOfParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfParameters * >(argp1);
    result = (SBMLTypeCode_t)((ListOfParameters const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfParameters_getItemTypeCode) {
  {
    ListOfParameters *arg1 = (ListOfParameters *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfParameters_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfParameters_getItemTypeCode" "', argument " "1"" of type '" "ListOfParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfParameters * >(argp1);
    result = (SBMLTypeCode_t)((ListOfParameters const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfParameters_getElementName) {
  {
    ListOfParameters *arg1 = (ListOfParameters *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfParameters_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfParameters_getElementName" "', argument " "1"" of type '" "ListOfParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfParameters * >(argp1);
    result = (std::string *) &((ListOfParameters const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfParameters_get__SWIG_0) {
  {
    ListOfParameters *arg1 = (ListOfParameters *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfParameters_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfParameters_get" "', argument " "1"" of type '" "ListOfParameters *""'"); 
    }
    arg1 = reinterpret_cast< ListOfParameters * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfParameters_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Parameter *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfParameters_get__SWIG_1) {
  {
    ListOfParameters *arg1 = (ListOfParameters *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfParameters_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfParameters_get" "', argument " "1"" of type '" "ListOfParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfParameters * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfParameters_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Parameter *)((ListOfParameters const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfParameters_get__SWIG_2) {
  {
    ListOfParameters *arg1 = (ListOfParameters *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfParameters_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfParameters_get" "', argument " "1"" of type '" "ListOfParameters *""'"); 
    }
    arg1 = reinterpret_cast< ListOfParameters * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfParameters_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfParameters_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Parameter *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfParameters_get__SWIG_3) {
  {
    ListOfParameters *arg1 = (ListOfParameters *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfParameters_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfParameters_get" "', argument " "1"" of type '" "ListOfParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfParameters * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfParameters_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfParameters_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Parameter *)((ListOfParameters const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfParameters_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfParameters_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfParameters_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfParameters_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfParameters_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfParameters_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfParameters_remove__SWIG_0) {
  {
    ListOfParameters *arg1 = (ListOfParameters *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfParameters_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfParameters_remove" "', argument " "1"" of type '" "ListOfParameters *""'"); 
    }
    arg1 = reinterpret_cast< ListOfParameters * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfParameters_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Parameter *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfParameters_remove__SWIG_1) {
  {
    ListOfParameters *arg1 = (ListOfParameters *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfParameters_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfParameters_remove" "', argument " "1"" of type '" "ListOfParameters *""'"); 
    }
    arg1 = reinterpret_cast< ListOfParameters * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfParameters_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfParameters_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Parameter *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfParameters_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfParameters_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfParameters_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfParameters_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfParameters) {
  {
    int argvi = 0;
    ListOfParameters *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfParameters();");
    }
    result = (ListOfParameters *)new ListOfParameters();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfParameters, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfParameters) {
  {
    ListOfParameters *arg1 = (ListOfParameters *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfParameters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfParameters, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfParameters" "', argument " "1"" of type '" "ListOfParameters *""'"); 
    }
    arg1 = reinterpret_cast< ListOfParameters * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_LocalParameter__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_LocalParameter(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_LocalParameter" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_LocalParameter" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (LocalParameter *)new LocalParameter(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_LocalParameter__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_LocalParameter(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_LocalParameter" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (LocalParameter *)new LocalParameter(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_LocalParameter) {
  {
    LocalParameter *arg1 = (LocalParameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_LocalParameter(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_LocalParameter, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_LocalParameter" "', argument " "1"" of type '" "LocalParameter *""'"); 
    }
    arg1 = reinterpret_cast< LocalParameter * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_LocalParameter__SWIG_2) {
  {
    LocalParameter *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_LocalParameter(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_LocalParameter,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_LocalParameter" "', argument " "1"" of type '" "LocalParameter const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_LocalParameter" "', argument " "1"" of type '" "LocalParameter const &""'"); 
    }
    arg1 = reinterpret_cast< LocalParameter * >(argp1);
    {
      try {
        result = (LocalParameter *)new LocalParameter((LocalParameter const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_LocalParameter__SWIG_3) {
  {
    Parameter *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_LocalParameter(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Parameter,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_LocalParameter" "', argument " "1"" of type '" "Parameter const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_LocalParameter" "', argument " "1"" of type '" "Parameter const &""'"); 
    }
    arg1 = reinterpret_cast< Parameter * >(argp1);
    {
      try {
        result = (LocalParameter *)new LocalParameter((Parameter const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_LocalParameter) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_LocalParameter, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Parameter, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_LocalParameter__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_LocalParameter__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_LocalParameter__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_LocalParameter__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_LocalParameter'");
  XSRETURN(0);
}


XS(_wrap_LocalParameter_clone) {
  {
    LocalParameter *arg1 = (LocalParameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: LocalParameter_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_LocalParameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "LocalParameter_clone" "', argument " "1"" of type '" "LocalParameter const *""'"); 
    }
    arg1 = reinterpret_cast< LocalParameter * >(argp1);
    result = (LocalParameter *)((LocalParameter const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_LocalParameter_getDerivedUnitDefinition__SWIG_0) {
  {
    LocalParameter *arg1 = (LocalParameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: LocalParameter_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_LocalParameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "LocalParameter_getDerivedUnitDefinition" "', argument " "1"" of type '" "LocalParameter *""'"); 
    }
    arg1 = reinterpret_cast< LocalParameter * >(argp1);
    result = (UnitDefinition *)(arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_LocalParameter_getDerivedUnitDefinition__SWIG_1) {
  {
    LocalParameter *arg1 = (LocalParameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: LocalParameter_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_LocalParameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "LocalParameter_getDerivedUnitDefinition" "', argument " "1"" of type '" "LocalParameter const *""'"); 
    }
    arg1 = reinterpret_cast< LocalParameter * >(argp1);
    result = (UnitDefinition *)((LocalParameter const *)arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_LocalParameter_getDerivedUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_LocalParameter, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_LocalParameter, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_LocalParameter_getDerivedUnitDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_LocalParameter_getDerivedUnitDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'LocalParameter_getDerivedUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_LocalParameter_getTypeCode) {
  {
    LocalParameter *arg1 = (LocalParameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: LocalParameter_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_LocalParameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "LocalParameter_getTypeCode" "', argument " "1"" of type '" "LocalParameter const *""'"); 
    }
    arg1 = reinterpret_cast< LocalParameter * >(argp1);
    result = (SBMLTypeCode_t)((LocalParameter const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_LocalParameter_getElementName) {
  {
    LocalParameter *arg1 = (LocalParameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: LocalParameter_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_LocalParameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "LocalParameter_getElementName" "', argument " "1"" of type '" "LocalParameter const *""'"); 
    }
    arg1 = reinterpret_cast< LocalParameter * >(argp1);
    result = (std::string *) &((LocalParameter const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_LocalParameter_hasRequiredAttributes) {
  {
    LocalParameter *arg1 = (LocalParameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: LocalParameter_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_LocalParameter, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "LocalParameter_hasRequiredAttributes" "', argument " "1"" of type '" "LocalParameter const *""'"); 
    }
    arg1 = reinterpret_cast< LocalParameter * >(argp1);
    result = (bool)((LocalParameter const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfLocalParameters_clone) {
  {
    ListOfLocalParameters *arg1 = (ListOfLocalParameters *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfLocalParameters *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfLocalParameters_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfLocalParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfLocalParameters_clone" "', argument " "1"" of type '" "ListOfLocalParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfLocalParameters * >(argp1);
    result = (ListOfLocalParameters *)((ListOfLocalParameters const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfLocalParameters, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfLocalParameters_getTypeCode) {
  {
    ListOfLocalParameters *arg1 = (ListOfLocalParameters *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfLocalParameters_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfLocalParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfLocalParameters_getTypeCode" "', argument " "1"" of type '" "ListOfLocalParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfLocalParameters * >(argp1);
    result = (SBMLTypeCode_t)((ListOfLocalParameters const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfLocalParameters_getItemTypeCode) {
  {
    ListOfLocalParameters *arg1 = (ListOfLocalParameters *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfLocalParameters_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfLocalParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfLocalParameters_getItemTypeCode" "', argument " "1"" of type '" "ListOfLocalParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfLocalParameters * >(argp1);
    result = (SBMLTypeCode_t)((ListOfLocalParameters const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfLocalParameters_getElementName) {
  {
    ListOfLocalParameters *arg1 = (ListOfLocalParameters *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfLocalParameters_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfLocalParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfLocalParameters_getElementName" "', argument " "1"" of type '" "ListOfLocalParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfLocalParameters * >(argp1);
    result = (std::string *) &((ListOfLocalParameters const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfLocalParameters_get__SWIG_0) {
  {
    ListOfLocalParameters *arg1 = (ListOfLocalParameters *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfLocalParameters_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfLocalParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfLocalParameters_get" "', argument " "1"" of type '" "ListOfLocalParameters *""'"); 
    }
    arg1 = reinterpret_cast< ListOfLocalParameters * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfLocalParameters_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (LocalParameter *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfLocalParameters_get__SWIG_1) {
  {
    ListOfLocalParameters *arg1 = (ListOfLocalParameters *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfLocalParameters_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfLocalParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfLocalParameters_get" "', argument " "1"" of type '" "ListOfLocalParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfLocalParameters * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfLocalParameters_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (LocalParameter *)((ListOfLocalParameters const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfLocalParameters_get__SWIG_2) {
  {
    ListOfLocalParameters *arg1 = (ListOfLocalParameters *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfLocalParameters_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfLocalParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfLocalParameters_get" "', argument " "1"" of type '" "ListOfLocalParameters *""'"); 
    }
    arg1 = reinterpret_cast< ListOfLocalParameters * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfLocalParameters_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfLocalParameters_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (LocalParameter *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfLocalParameters_get__SWIG_3) {
  {
    ListOfLocalParameters *arg1 = (ListOfLocalParameters *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfLocalParameters_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfLocalParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfLocalParameters_get" "', argument " "1"" of type '" "ListOfLocalParameters const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfLocalParameters * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfLocalParameters_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfLocalParameters_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (LocalParameter *)((ListOfLocalParameters const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfLocalParameters_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfLocalParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfLocalParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfLocalParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfLocalParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfLocalParameters_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfLocalParameters_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfLocalParameters_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfLocalParameters_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfLocalParameters_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfLocalParameters_remove__SWIG_0) {
  {
    ListOfLocalParameters *arg1 = (ListOfLocalParameters *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfLocalParameters_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfLocalParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfLocalParameters_remove" "', argument " "1"" of type '" "ListOfLocalParameters *""'"); 
    }
    arg1 = reinterpret_cast< ListOfLocalParameters * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfLocalParameters_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (LocalParameter *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfLocalParameters_remove__SWIG_1) {
  {
    ListOfLocalParameters *arg1 = (ListOfLocalParameters *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfLocalParameters_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfLocalParameters, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfLocalParameters_remove" "', argument " "1"" of type '" "ListOfLocalParameters *""'"); 
    }
    arg1 = reinterpret_cast< ListOfLocalParameters * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfLocalParameters_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfLocalParameters_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (LocalParameter *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfLocalParameters_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfLocalParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfLocalParameters, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfLocalParameters_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfLocalParameters_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfLocalParameters_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfLocalParameters) {
  {
    int argvi = 0;
    ListOfLocalParameters *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfLocalParameters();");
    }
    result = (ListOfLocalParameters *)new ListOfLocalParameters();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfLocalParameters, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfLocalParameters) {
  {
    ListOfLocalParameters *arg1 = (ListOfLocalParameters *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfLocalParameters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfLocalParameters, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfLocalParameters" "', argument " "1"" of type '" "ListOfLocalParameters *""'"); 
    }
    arg1 = reinterpret_cast< ListOfLocalParameters * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_InitialAssignment__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_InitialAssignment(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_InitialAssignment" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_InitialAssignment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (InitialAssignment *)new InitialAssignment(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_InitialAssignment__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_InitialAssignment(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_InitialAssignment" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (InitialAssignment *)new InitialAssignment(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_InitialAssignment) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_InitialAssignment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_InitialAssignment" "', argument " "1"" of type '" "InitialAssignment *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_InitialAssignment__SWIG_2) {
  {
    InitialAssignment *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_InitialAssignment(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_InitialAssignment,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_InitialAssignment" "', argument " "1"" of type '" "InitialAssignment const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_InitialAssignment" "', argument " "1"" of type '" "InitialAssignment const &""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    {
      try {
        result = (InitialAssignment *)new InitialAssignment((InitialAssignment const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_InitialAssignment) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_InitialAssignment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_InitialAssignment__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_InitialAssignment__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_InitialAssignment__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_InitialAssignment'");
  XSRETURN(0);
}


XS(_wrap_InitialAssignment_clone) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_clone" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (InitialAssignment *)((InitialAssignment const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_getSymbol) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_getSymbol(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_getSymbol" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (std::string *) &((InitialAssignment const *)arg1)->getSymbol();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_getMath) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_getMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_getMath" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (ASTNode *)((InitialAssignment const *)arg1)->getMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_isSetSymbol) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_isSetSymbol(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_isSetSymbol" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (bool)((InitialAssignment const *)arg1)->isSetSymbol();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_isSetMath) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_isSetMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_isSetMath" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (bool)((InitialAssignment const *)arg1)->isSetMath();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_setSymbol) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: InitialAssignment_setSymbol(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_setSymbol" "', argument " "1"" of type '" "InitialAssignment *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "InitialAssignment_setSymbol" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "InitialAssignment_setSymbol" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setSymbol((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_setMath) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: InitialAssignment_setMath(self,math);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_setMath" "', argument " "1"" of type '" "InitialAssignment *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "InitialAssignment_setMath" "', argument " "2"" of type '" "ASTNode const *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->setMath((ASTNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_getDerivedUnitDefinition__SWIG_0) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_getDerivedUnitDefinition" "', argument " "1"" of type '" "InitialAssignment *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (UnitDefinition *)(arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_getDerivedUnitDefinition__SWIG_1) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_getDerivedUnitDefinition" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (UnitDefinition *)((InitialAssignment const *)arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_getDerivedUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_InitialAssignment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_InitialAssignment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_InitialAssignment_getDerivedUnitDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_InitialAssignment_getDerivedUnitDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'InitialAssignment_getDerivedUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_InitialAssignment_containsUndeclaredUnits__SWIG_0) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_containsUndeclaredUnits" "', argument " "1"" of type '" "InitialAssignment *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (bool)(arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_containsUndeclaredUnits__SWIG_1) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_containsUndeclaredUnits" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (bool)((InitialAssignment const *)arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_containsUndeclaredUnits) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_InitialAssignment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_InitialAssignment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_InitialAssignment_containsUndeclaredUnits__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_InitialAssignment_containsUndeclaredUnits__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'InitialAssignment_containsUndeclaredUnits'");
  XSRETURN(0);
}


XS(_wrap_InitialAssignment_getTypeCode) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_getTypeCode" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (SBMLTypeCode_t)((InitialAssignment const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_getElementName) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_getElementName" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (std::string *) &((InitialAssignment const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_hasRequiredAttributes) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_hasRequiredAttributes" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (bool)((InitialAssignment const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_hasRequiredElements) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_hasRequiredElements" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = (bool)((InitialAssignment const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_InitialAssignment_getId) {
  {
    InitialAssignment *arg1 = (InitialAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: InitialAssignment_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_InitialAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "InitialAssignment_getId" "', argument " "1"" of type '" "InitialAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< InitialAssignment * >(argp1);
    result = ((InitialAssignment const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfInitialAssignments_clone) {
  {
    ListOfInitialAssignments *arg1 = (ListOfInitialAssignments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfInitialAssignments *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfInitialAssignments_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfInitialAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfInitialAssignments_clone" "', argument " "1"" of type '" "ListOfInitialAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfInitialAssignments * >(argp1);
    result = (ListOfInitialAssignments *)((ListOfInitialAssignments const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfInitialAssignments, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfInitialAssignments_getTypeCode) {
  {
    ListOfInitialAssignments *arg1 = (ListOfInitialAssignments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfInitialAssignments_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfInitialAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfInitialAssignments_getTypeCode" "', argument " "1"" of type '" "ListOfInitialAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfInitialAssignments * >(argp1);
    result = (SBMLTypeCode_t)((ListOfInitialAssignments const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfInitialAssignments_getItemTypeCode) {
  {
    ListOfInitialAssignments *arg1 = (ListOfInitialAssignments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfInitialAssignments_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfInitialAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfInitialAssignments_getItemTypeCode" "', argument " "1"" of type '" "ListOfInitialAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfInitialAssignments * >(argp1);
    result = (SBMLTypeCode_t)((ListOfInitialAssignments const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfInitialAssignments_getElementName) {
  {
    ListOfInitialAssignments *arg1 = (ListOfInitialAssignments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfInitialAssignments_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfInitialAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfInitialAssignments_getElementName" "', argument " "1"" of type '" "ListOfInitialAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfInitialAssignments * >(argp1);
    result = (std::string *) &((ListOfInitialAssignments const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfInitialAssignments_get__SWIG_0) {
  {
    ListOfInitialAssignments *arg1 = (ListOfInitialAssignments *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfInitialAssignments_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfInitialAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfInitialAssignments_get" "', argument " "1"" of type '" "ListOfInitialAssignments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfInitialAssignments * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfInitialAssignments_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (InitialAssignment *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfInitialAssignments_get__SWIG_1) {
  {
    ListOfInitialAssignments *arg1 = (ListOfInitialAssignments *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfInitialAssignments_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfInitialAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfInitialAssignments_get" "', argument " "1"" of type '" "ListOfInitialAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfInitialAssignments * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfInitialAssignments_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (InitialAssignment *)((ListOfInitialAssignments const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfInitialAssignments_get__SWIG_2) {
  {
    ListOfInitialAssignments *arg1 = (ListOfInitialAssignments *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfInitialAssignments_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfInitialAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfInitialAssignments_get" "', argument " "1"" of type '" "ListOfInitialAssignments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfInitialAssignments * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfInitialAssignments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfInitialAssignments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (InitialAssignment *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfInitialAssignments_get__SWIG_3) {
  {
    ListOfInitialAssignments *arg1 = (ListOfInitialAssignments *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfInitialAssignments_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfInitialAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfInitialAssignments_get" "', argument " "1"" of type '" "ListOfInitialAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfInitialAssignments * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfInitialAssignments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfInitialAssignments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (InitialAssignment *)((ListOfInitialAssignments const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfInitialAssignments_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfInitialAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfInitialAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfInitialAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfInitialAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfInitialAssignments_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfInitialAssignments_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfInitialAssignments_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfInitialAssignments_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfInitialAssignments_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfInitialAssignments_remove__SWIG_0) {
  {
    ListOfInitialAssignments *arg1 = (ListOfInitialAssignments *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfInitialAssignments_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfInitialAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfInitialAssignments_remove" "', argument " "1"" of type '" "ListOfInitialAssignments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfInitialAssignments * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfInitialAssignments_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (InitialAssignment *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfInitialAssignments_remove__SWIG_1) {
  {
    ListOfInitialAssignments *arg1 = (ListOfInitialAssignments *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    InitialAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfInitialAssignments_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfInitialAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfInitialAssignments_remove" "', argument " "1"" of type '" "ListOfInitialAssignments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfInitialAssignments * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfInitialAssignments_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfInitialAssignments_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (InitialAssignment *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_InitialAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfInitialAssignments_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfInitialAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfInitialAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfInitialAssignments_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfInitialAssignments_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfInitialAssignments_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfInitialAssignments) {
  {
    int argvi = 0;
    ListOfInitialAssignments *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfInitialAssignments();");
    }
    result = (ListOfInitialAssignments *)new ListOfInitialAssignments();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfInitialAssignments, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfInitialAssignments) {
  {
    ListOfInitialAssignments *arg1 = (ListOfInitialAssignments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfInitialAssignments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfInitialAssignments, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfInitialAssignments" "', argument " "1"" of type '" "ListOfInitialAssignments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfInitialAssignments * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Rule) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Rule(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Rule" "', argument " "1"" of type '" "Rule *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Rule) {
  {
    Rule *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Rule(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Rule,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Rule" "', argument " "1"" of type '" "Rule const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Rule" "', argument " "1"" of type '" "Rule const &""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (Rule *)new Rule((Rule const &)*arg1);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        SWIG_OWNER | SWIG_SHADOW);
      argvi++;
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_clone) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_clone" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (Rule *)((Rule const *)arg1)->clone();
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        SWIG_OWNER | SWIG_SHADOW);
      argvi++;
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_getFormula) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_getFormula(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_getFormula" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (std::string *) &((Rule const *)arg1)->getFormula();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_getMath) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_getMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_getMath" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (ASTNode *)((Rule const *)arg1)->getMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_getVariable) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_getVariable(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_getVariable" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (std::string *) &((Rule const *)arg1)->getVariable();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_getUnits) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_getUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_getUnits" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (std::string *) &((Rule const *)arg1)->getUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_isSetFormula) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_isSetFormula(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_isSetFormula" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->isSetFormula();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_isSetMath) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_isSetMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_isSetMath" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->isSetMath();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_isSetVariable) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_isSetVariable(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_isSetVariable" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->isSetVariable();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_isSetUnits) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_isSetUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_isSetUnits" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->isSetUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_setFormula) {
  {
    Rule *arg1 = (Rule *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Rule_setFormula(self,formula);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_setFormula" "', argument " "1"" of type '" "Rule *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Rule_setFormula" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Rule_setFormula" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setFormula((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_setMath) {
  {
    Rule *arg1 = (Rule *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Rule_setMath(self,math);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_setMath" "', argument " "1"" of type '" "Rule *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Rule_setMath" "', argument " "2"" of type '" "ASTNode const *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->setMath((ASTNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_setVariable) {
  {
    Rule *arg1 = (Rule *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Rule_setVariable(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_setVariable" "', argument " "1"" of type '" "Rule *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Rule_setVariable" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Rule_setVariable" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setVariable((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_setUnits) {
  {
    Rule *arg1 = (Rule *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Rule_setUnits(self,sname);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_setUnits" "', argument " "1"" of type '" "Rule *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Rule_setUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Rule_setUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_unsetUnits) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_unsetUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_unsetUnits" "', argument " "1"" of type '" "Rule *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (int)(arg1)->unsetUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_getDerivedUnitDefinition__SWIG_0) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_getDerivedUnitDefinition" "', argument " "1"" of type '" "Rule *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (UnitDefinition *)(arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_getDerivedUnitDefinition__SWIG_1) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_getDerivedUnitDefinition" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (UnitDefinition *)((Rule const *)arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_getDerivedUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Rule, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Rule, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Rule_getDerivedUnitDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Rule_getDerivedUnitDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Rule_getDerivedUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_Rule_containsUndeclaredUnits__SWIG_0) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_containsUndeclaredUnits" "', argument " "1"" of type '" "Rule *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)(arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_containsUndeclaredUnits__SWIG_1) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_containsUndeclaredUnits" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_containsUndeclaredUnits) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Rule, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Rule, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Rule_containsUndeclaredUnits__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Rule_containsUndeclaredUnits__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Rule_containsUndeclaredUnits'");
  XSRETURN(0);
}


XS(_wrap_Rule_getType) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    RuleType_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_getType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_getType" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (RuleType_t)((Rule const *)arg1)->getType();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_isAlgebraic) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_isAlgebraic(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_isAlgebraic" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->isAlgebraic();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_isAssignment) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_isAssignment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_isAssignment" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->isAssignment();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_isCompartmentVolume) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_isCompartmentVolume(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_isCompartmentVolume" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->isCompartmentVolume();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_isParameter) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_isParameter(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_isParameter" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->isParameter();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_isRate) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_isRate(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_isRate" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->isRate();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_isScalar) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_isScalar(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_isScalar" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->isScalar();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_isSpeciesConcentration) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_isSpeciesConcentration(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_isSpeciesConcentration" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->isSpeciesConcentration();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_getTypeCode) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_getTypeCode" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (SBMLTypeCode_t)((Rule const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_getL1TypeCode) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_getL1TypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_getL1TypeCode" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (SBMLTypeCode_t)((Rule const *)arg1)->getL1TypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_getElementName) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_getElementName" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (std::string *) &((Rule const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_setL1TypeCode) {
  {
    Rule *arg1 = (Rule *) 0 ;
    SBMLTypeCode_t arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Rule_setL1TypeCode(self,type);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_setL1TypeCode" "', argument " "1"" of type '" "Rule *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Rule_setL1TypeCode" "', argument " "2"" of type '" "SBMLTypeCode_t""'");
    } 
    arg2 = static_cast< SBMLTypeCode_t >(val2);
    result = (int)(arg1)->setL1TypeCode(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_hasRequiredElements) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_hasRequiredElements" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_hasRequiredAttributes) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_hasRequiredAttributes" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = (bool)((Rule const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Rule_getId) {
  {
    Rule *arg1 = (Rule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Rule_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Rule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Rule_getId" "', argument " "1"" of type '" "Rule const *""'"); 
    }
    arg1 = reinterpret_cast< Rule * >(argp1);
    result = ((Rule const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_AlgebraicRule__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    AlgebraicRule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_AlgebraicRule(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_AlgebraicRule" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_AlgebraicRule" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (AlgebraicRule *)new AlgebraicRule(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_AlgebraicRule, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_AlgebraicRule__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    AlgebraicRule *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_AlgebraicRule(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_AlgebraicRule" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (AlgebraicRule *)new AlgebraicRule(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_AlgebraicRule, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_AlgebraicRule) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_AlgebraicRule__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_AlgebraicRule__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_AlgebraicRule'");
  XSRETURN(0);
}


XS(_wrap_delete_AlgebraicRule) {
  {
    AlgebraicRule *arg1 = (AlgebraicRule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_AlgebraicRule(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_AlgebraicRule, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_AlgebraicRule" "', argument " "1"" of type '" "AlgebraicRule *""'"); 
    }
    arg1 = reinterpret_cast< AlgebraicRule * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_AlgebraicRule_clone) {
  {
    AlgebraicRule *arg1 = (AlgebraicRule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    AlgebraicRule *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: AlgebraicRule_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_AlgebraicRule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "AlgebraicRule_clone" "', argument " "1"" of type '" "AlgebraicRule const *""'"); 
    }
    arg1 = reinterpret_cast< AlgebraicRule * >(argp1);
    result = (AlgebraicRule *)((AlgebraicRule const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_AlgebraicRule, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_AlgebraicRule_hasRequiredAttributes) {
  {
    AlgebraicRule *arg1 = (AlgebraicRule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: AlgebraicRule_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_AlgebraicRule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "AlgebraicRule_hasRequiredAttributes" "', argument " "1"" of type '" "AlgebraicRule const *""'"); 
    }
    arg1 = reinterpret_cast< AlgebraicRule * >(argp1);
    result = (bool)((AlgebraicRule const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_AssignmentRule__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    AssignmentRule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_AssignmentRule(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_AssignmentRule" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_AssignmentRule" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (AssignmentRule *)new AssignmentRule(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_AssignmentRule, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_AssignmentRule__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    AssignmentRule *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_AssignmentRule(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_AssignmentRule" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (AssignmentRule *)new AssignmentRule(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_AssignmentRule, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_AssignmentRule) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_AssignmentRule__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_AssignmentRule__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_AssignmentRule'");
  XSRETURN(0);
}


XS(_wrap_delete_AssignmentRule) {
  {
    AssignmentRule *arg1 = (AssignmentRule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_AssignmentRule(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_AssignmentRule, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_AssignmentRule" "', argument " "1"" of type '" "AssignmentRule *""'"); 
    }
    arg1 = reinterpret_cast< AssignmentRule * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_AssignmentRule_clone) {
  {
    AssignmentRule *arg1 = (AssignmentRule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    AssignmentRule *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: AssignmentRule_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_AssignmentRule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "AssignmentRule_clone" "', argument " "1"" of type '" "AssignmentRule const *""'"); 
    }
    arg1 = reinterpret_cast< AssignmentRule * >(argp1);
    result = (AssignmentRule *)((AssignmentRule const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_AssignmentRule, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_AssignmentRule_hasRequiredAttributes) {
  {
    AssignmentRule *arg1 = (AssignmentRule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: AssignmentRule_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_AssignmentRule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "AssignmentRule_hasRequiredAttributes" "', argument " "1"" of type '" "AssignmentRule const *""'"); 
    }
    arg1 = reinterpret_cast< AssignmentRule * >(argp1);
    result = (bool)((AssignmentRule const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_RateRule__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    RateRule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_RateRule(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_RateRule" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_RateRule" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (RateRule *)new RateRule(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_RateRule, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_RateRule__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    RateRule *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_RateRule(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_RateRule" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (RateRule *)new RateRule(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_RateRule, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_RateRule) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_RateRule__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_RateRule__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_RateRule'");
  XSRETURN(0);
}


XS(_wrap_delete_RateRule) {
  {
    RateRule *arg1 = (RateRule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_RateRule(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_RateRule, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_RateRule" "', argument " "1"" of type '" "RateRule *""'"); 
    }
    arg1 = reinterpret_cast< RateRule * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_RateRule_clone) {
  {
    RateRule *arg1 = (RateRule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    RateRule *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: RateRule_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_RateRule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "RateRule_clone" "', argument " "1"" of type '" "RateRule const *""'"); 
    }
    arg1 = reinterpret_cast< RateRule * >(argp1);
    result = (RateRule *)((RateRule const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_RateRule, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_RateRule_hasRequiredAttributes) {
  {
    RateRule *arg1 = (RateRule *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: RateRule_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_RateRule, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "RateRule_hasRequiredAttributes" "', argument " "1"" of type '" "RateRule const *""'"); 
    }
    arg1 = reinterpret_cast< RateRule * >(argp1);
    result = (bool)((RateRule const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfRules_clone) {
  {
    ListOfRules *arg1 = (ListOfRules *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfRules *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfRules_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfRules, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfRules_clone" "', argument " "1"" of type '" "ListOfRules const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfRules * >(argp1);
    result = (ListOfRules *)((ListOfRules const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfRules, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfRules_getTypeCode) {
  {
    ListOfRules *arg1 = (ListOfRules *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfRules_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfRules, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfRules_getTypeCode" "', argument " "1"" of type '" "ListOfRules const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfRules * >(argp1);
    result = (SBMLTypeCode_t)((ListOfRules const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfRules_getItemTypeCode) {
  {
    ListOfRules *arg1 = (ListOfRules *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfRules_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfRules, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfRules_getItemTypeCode" "', argument " "1"" of type '" "ListOfRules const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfRules * >(argp1);
    result = (SBMLTypeCode_t)((ListOfRules const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfRules_getElementName) {
  {
    ListOfRules *arg1 = (ListOfRules *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfRules_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfRules, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfRules_getElementName" "', argument " "1"" of type '" "ListOfRules const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfRules * >(argp1);
    result = (std::string *) &((ListOfRules const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfRules_get__SWIG_0) {
  {
    ListOfRules *arg1 = (ListOfRules *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfRules_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfRules, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfRules_get" "', argument " "1"" of type '" "ListOfRules *""'"); 
    }
    arg1 = reinterpret_cast< ListOfRules * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfRules_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Rule *)(arg1)->get(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfRules_get__SWIG_1) {
  {
    ListOfRules *arg1 = (ListOfRules *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfRules_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfRules, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfRules_get" "', argument " "1"" of type '" "ListOfRules const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfRules * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfRules_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Rule *)((ListOfRules const *)arg1)->get(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfRules_get__SWIG_2) {
  {
    ListOfRules *arg1 = (ListOfRules *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfRules_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfRules, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfRules_get" "', argument " "1"" of type '" "ListOfRules *""'"); 
    }
    arg1 = reinterpret_cast< ListOfRules * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfRules_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfRules_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Rule *)(arg1)->get((std::string const &)*arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfRules_get__SWIG_3) {
  {
    ListOfRules *arg1 = (ListOfRules *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfRules_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfRules, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfRules_get" "', argument " "1"" of type '" "ListOfRules const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfRules * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfRules_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfRules_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Rule *)((ListOfRules const *)arg1)->get((std::string const &)*arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfRules_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfRules, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfRules, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfRules, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfRules, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfRules_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfRules_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfRules_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfRules_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfRules_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfRules_remove__SWIG_0) {
  {
    ListOfRules *arg1 = (ListOfRules *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfRules_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfRules, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfRules_remove" "', argument " "1"" of type '" "ListOfRules *""'"); 
    }
    arg1 = reinterpret_cast< ListOfRules * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfRules_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Rule *)(arg1)->remove(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        SWIG_OWNER | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfRules_remove__SWIG_1) {
  {
    ListOfRules *arg1 = (ListOfRules *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Rule *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfRules_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfRules, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfRules_remove" "', argument " "1"" of type '" "ListOfRules *""'"); 
    }
    arg1 = reinterpret_cast< ListOfRules * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfRules_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfRules_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Rule *)(arg1)->remove((std::string const &)*arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        SWIG_OWNER | SWIG_SHADOW);
      argvi++;
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfRules_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfRules, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfRules, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfRules_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfRules_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfRules_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfRules) {
  {
    int argvi = 0;
    ListOfRules *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfRules();");
    }
    result = (ListOfRules *)new ListOfRules();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfRules, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfRules) {
  {
    ListOfRules *arg1 = (ListOfRules *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfRules(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfRules, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfRules" "', argument " "1"" of type '" "ListOfRules *""'"); 
    }
    arg1 = reinterpret_cast< ListOfRules * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Constraint__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Constraint *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Constraint(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Constraint" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Constraint" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (Constraint *)new Constraint(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Constraint, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Constraint__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Constraint *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Constraint(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Constraint" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (Constraint *)new Constraint(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Constraint, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Constraint) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Constraint(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Constraint" "', argument " "1"" of type '" "Constraint *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Constraint__SWIG_2) {
  {
    Constraint *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Constraint *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Constraint(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Constraint,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Constraint" "', argument " "1"" of type '" "Constraint const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Constraint" "', argument " "1"" of type '" "Constraint const &""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    {
      try {
        result = (Constraint *)new Constraint((Constraint const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Constraint, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Constraint) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Constraint, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Constraint__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Constraint__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Constraint__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Constraint'");
  XSRETURN(0);
}


XS(_wrap_Constraint_clone) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Constraint *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Constraint_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_clone" "', argument " "1"" of type '" "Constraint const *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    result = (Constraint *)((Constraint const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Constraint, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Constraint_getMessage) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Constraint_getMessage(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_getMessage" "', argument " "1"" of type '" "Constraint const *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    result = (XMLNode *)((Constraint const *)arg1)->getMessage();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Constraint_getMessageString) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Constraint_getMessageString(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_getMessageString" "', argument " "1"" of type '" "Constraint const *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    result = ((Constraint const *)arg1)->getMessageString();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Constraint_getMath) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Constraint_getMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_getMath" "', argument " "1"" of type '" "Constraint const *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    result = (ASTNode *)((Constraint const *)arg1)->getMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Constraint_isSetMessage) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Constraint_isSetMessage(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_isSetMessage" "', argument " "1"" of type '" "Constraint const *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    result = (bool)((Constraint const *)arg1)->isSetMessage();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Constraint_isSetMath) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Constraint_isSetMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_isSetMath" "', argument " "1"" of type '" "Constraint const *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    result = (bool)((Constraint const *)arg1)->isSetMath();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Constraint_setMessage) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    XMLNode *arg2 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Constraint_setMessage(self,xhtml);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_setMessage" "', argument " "1"" of type '" "Constraint *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Constraint_setMessage" "', argument " "2"" of type '" "XMLNode const *""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (int)(arg1)->setMessage((XMLNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Constraint_setMath) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Constraint_setMath(self,math);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_setMath" "', argument " "1"" of type '" "Constraint *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Constraint_setMath" "', argument " "2"" of type '" "ASTNode const *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->setMath((ASTNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Constraint_unsetMessage) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Constraint_unsetMessage(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_unsetMessage" "', argument " "1"" of type '" "Constraint *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    result = (int)(arg1)->unsetMessage();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Constraint_getTypeCode) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Constraint_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_getTypeCode" "', argument " "1"" of type '" "Constraint const *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    result = (SBMLTypeCode_t)((Constraint const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Constraint_getElementName) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Constraint_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_getElementName" "', argument " "1"" of type '" "Constraint const *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    result = (std::string *) &((Constraint const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Constraint_hasRequiredElements) {
  {
    Constraint *arg1 = (Constraint *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Constraint_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Constraint, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Constraint_hasRequiredElements" "', argument " "1"" of type '" "Constraint const *""'"); 
    }
    arg1 = reinterpret_cast< Constraint * >(argp1);
    result = (bool)((Constraint const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfConstraints_clone) {
  {
    ListOfConstraints *arg1 = (ListOfConstraints *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfConstraints *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfConstraints_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfConstraints, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfConstraints_clone" "', argument " "1"" of type '" "ListOfConstraints const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfConstraints * >(argp1);
    result = (ListOfConstraints *)((ListOfConstraints const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfConstraints, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfConstraints_getTypeCode) {
  {
    ListOfConstraints *arg1 = (ListOfConstraints *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfConstraints_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfConstraints, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfConstraints_getTypeCode" "', argument " "1"" of type '" "ListOfConstraints const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfConstraints * >(argp1);
    result = (SBMLTypeCode_t)((ListOfConstraints const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfConstraints_getItemTypeCode) {
  {
    ListOfConstraints *arg1 = (ListOfConstraints *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfConstraints_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfConstraints, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfConstraints_getItemTypeCode" "', argument " "1"" of type '" "ListOfConstraints const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfConstraints * >(argp1);
    result = (SBMLTypeCode_t)((ListOfConstraints const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfConstraints_getElementName) {
  {
    ListOfConstraints *arg1 = (ListOfConstraints *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfConstraints_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfConstraints, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfConstraints_getElementName" "', argument " "1"" of type '" "ListOfConstraints const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfConstraints * >(argp1);
    result = (std::string *) &((ListOfConstraints const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfConstraints_get__SWIG_0) {
  {
    ListOfConstraints *arg1 = (ListOfConstraints *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Constraint *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfConstraints_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfConstraints, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfConstraints_get" "', argument " "1"" of type '" "ListOfConstraints *""'"); 
    }
    arg1 = reinterpret_cast< ListOfConstraints * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfConstraints_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Constraint *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Constraint, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfConstraints_get__SWIG_1) {
  {
    ListOfConstraints *arg1 = (ListOfConstraints *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Constraint *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfConstraints_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfConstraints, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfConstraints_get" "', argument " "1"" of type '" "ListOfConstraints const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfConstraints * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfConstraints_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Constraint *)((ListOfConstraints const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Constraint, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfConstraints_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfConstraints, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfConstraints, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfConstraints_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfConstraints_get__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfConstraints_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfConstraints_remove) {
  {
    ListOfConstraints *arg1 = (ListOfConstraints *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Constraint *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfConstraints_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfConstraints, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfConstraints_remove" "', argument " "1"" of type '" "ListOfConstraints *""'"); 
    }
    arg1 = reinterpret_cast< ListOfConstraints * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfConstraints_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Constraint *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Constraint, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ListOfConstraints) {
  {
    int argvi = 0;
    ListOfConstraints *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfConstraints();");
    }
    result = (ListOfConstraints *)new ListOfConstraints();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfConstraints, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfConstraints) {
  {
    ListOfConstraints *arg1 = (ListOfConstraints *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfConstraints(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfConstraints, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfConstraints" "', argument " "1"" of type '" "ListOfConstraints *""'"); 
    }
    arg1 = reinterpret_cast< ListOfConstraints * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Reaction__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Reaction(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Reaction" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Reaction" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (Reaction *)new Reaction(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Reaction__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Reaction(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Reaction" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (Reaction *)new Reaction(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Reaction) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Reaction(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Reaction" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Reaction__SWIG_2) {
  {
    Reaction *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Reaction(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Reaction,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Reaction" "', argument " "1"" of type '" "Reaction const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Reaction" "', argument " "1"" of type '" "Reaction const &""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      try {
        result = (Reaction *)new Reaction((Reaction const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Reaction) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Reaction__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Reaction__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Reaction__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Reaction'");
  XSRETURN(0);
}


XS(_wrap_Reaction_clone) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_clone" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (Reaction *)((Reaction const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_initDefaults) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_initDefaults(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_initDefaults" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    (arg1)->initDefaults();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getId) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getId" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (std::string *) &((Reaction const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getName) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getName" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (std::string *) &((Reaction const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getKineticLaw__SWIG_0) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    KineticLaw *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getKineticLaw(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getKineticLaw" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (KineticLaw *)((Reaction const *)arg1)->getKineticLaw();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_KineticLaw, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getKineticLaw__SWIG_1) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    KineticLaw *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getKineticLaw(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getKineticLaw" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (KineticLaw *)(arg1)->getKineticLaw();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_KineticLaw, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getKineticLaw) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getKineticLaw__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getKineticLaw__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Reaction_getKineticLaw'");
  XSRETURN(0);
}


XS(_wrap_Reaction_getReversible) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getReversible(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getReversible" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (bool)((Reaction const *)arg1)->getReversible();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getFast) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getFast(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getFast" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (bool)((Reaction const *)arg1)->getFast();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getCompartment) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getCompartment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getCompartment" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (std::string *) &((Reaction const *)arg1)->getCompartment();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_isSetId) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_isSetId" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (bool)((Reaction const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_isSetName) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_isSetName" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (bool)((Reaction const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_isSetKineticLaw) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_isSetKineticLaw(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_isSetKineticLaw" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (bool)((Reaction const *)arg1)->isSetKineticLaw();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_isSetFast) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_isSetFast(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_isSetFast" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (bool)((Reaction const *)arg1)->isSetFast();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_isSetCompartment) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_isSetCompartment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_isSetCompartment" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (bool)((Reaction const *)arg1)->isSetCompartment();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_isSetReversible) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_isSetReversible(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_isSetReversible" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (bool)((Reaction const *)arg1)->isSetReversible();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_setId) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_setId" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_setName) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_setName" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_setKineticLaw) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    KineticLaw *arg2 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_setKineticLaw(self,kl);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_setKineticLaw" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_setKineticLaw" "', argument " "2"" of type '" "KineticLaw const *""'"); 
    }
    arg2 = reinterpret_cast< KineticLaw * >(argp2);
    result = (int)(arg1)->setKineticLaw((KineticLaw const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_setReversible) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_setReversible(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_setReversible" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Reaction_setReversible" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (int)(arg1)->setReversible(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_setFast) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_setFast(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_setFast" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Reaction_setFast" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (int)(arg1)->setFast(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_setCompartment) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_setCompartment(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_setCompartment" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_setCompartment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_setCompartment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setCompartment((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_unsetName) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_unsetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_unsetName" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (int)(arg1)->unsetName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_unsetKineticLaw) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_unsetKineticLaw(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_unsetKineticLaw" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (int)(arg1)->unsetKineticLaw();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_unsetFast) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_unsetFast(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_unsetFast" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (int)(arg1)->unsetFast();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_unsetCompartment) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_unsetCompartment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_unsetCompartment" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (int)(arg1)->unsetCompartment();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_addReactant) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    SpeciesReference *arg2 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_addReactant(self,sr);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_addReactant" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_addReactant" "', argument " "2"" of type '" "SpeciesReference const *""'"); 
    }
    arg2 = reinterpret_cast< SpeciesReference * >(argp2);
    result = (int)(arg1)->addReactant((SpeciesReference const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_addProduct) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    SpeciesReference *arg2 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_addProduct(self,sr);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_addProduct" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_addProduct" "', argument " "2"" of type '" "SpeciesReference const *""'"); 
    }
    arg2 = reinterpret_cast< SpeciesReference * >(argp2);
    result = (int)(arg1)->addProduct((SpeciesReference const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_addModifier) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    ModifierSpeciesReference *arg2 = (ModifierSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_addModifier(self,msr);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_addModifier" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ModifierSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_addModifier" "', argument " "2"" of type '" "ModifierSpeciesReference const *""'"); 
    }
    arg2 = reinterpret_cast< ModifierSpeciesReference * >(argp2);
    result = (int)(arg1)->addModifier((ModifierSpeciesReference const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_createReactant) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_createReactant(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_createReactant" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (SpeciesReference *)(arg1)->createReactant();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_createProduct) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_createProduct(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_createProduct" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (SpeciesReference *)(arg1)->createProduct();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_createModifier) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ModifierSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_createModifier(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_createModifier" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (ModifierSpeciesReference *)(arg1)->createModifier();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModifierSpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_createKineticLaw) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    KineticLaw *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_createKineticLaw(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_createKineticLaw" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (KineticLaw *)(arg1)->createKineticLaw();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_KineticLaw, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getListOfReactants__SWIG_0) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpeciesReferences *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getListOfReactants(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getListOfReactants" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (ListOfSpeciesReferences *)((Reaction const *)arg1)->getListOfReactants();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesReferences, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getListOfReactants__SWIG_1) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpeciesReferences *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getListOfReactants(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getListOfReactants" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (ListOfSpeciesReferences *)(arg1)->getListOfReactants();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesReferences, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getListOfReactants) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getListOfReactants__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getListOfReactants__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Reaction_getListOfReactants'");
  XSRETURN(0);
}


XS(_wrap_Reaction_getListOfProducts__SWIG_0) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpeciesReferences *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getListOfProducts(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getListOfProducts" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (ListOfSpeciesReferences *)((Reaction const *)arg1)->getListOfProducts();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesReferences, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getListOfProducts__SWIG_1) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpeciesReferences *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getListOfProducts(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getListOfProducts" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (ListOfSpeciesReferences *)(arg1)->getListOfProducts();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesReferences, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getListOfProducts) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getListOfProducts__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getListOfProducts__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Reaction_getListOfProducts'");
  XSRETURN(0);
}


XS(_wrap_Reaction_getListOfModifiers__SWIG_0) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpeciesReferences *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getListOfModifiers(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getListOfModifiers" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (ListOfSpeciesReferences *)((Reaction const *)arg1)->getListOfModifiers();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesReferences, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getListOfModifiers__SWIG_1) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpeciesReferences *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getListOfModifiers(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getListOfModifiers" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (ListOfSpeciesReferences *)(arg1)->getListOfModifiers();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesReferences, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getListOfModifiers) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getListOfModifiers__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getListOfModifiers__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Reaction_getListOfModifiers'");
  XSRETURN(0);
}


XS(_wrap_Reaction_getReactant__SWIG_0) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getReactant(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getReactant" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Reaction_getReactant" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesReference *)((Reaction const *)arg1)->getReactant(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getReactant__SWIG_1) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getReactant(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getReactant" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Reaction_getReactant" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesReference *)(arg1)->getReactant(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getReactant__SWIG_2) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getReactant(self,species);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getReactant" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_getReactant" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_getReactant" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesReference *)((Reaction const *)arg1)->getReactant((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getReactant__SWIG_3) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getReactant(self,species);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getReactant" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_getReactant" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_getReactant" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesReference *)(arg1)->getReactant((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getReactant) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getReactant__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getReactant__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getReactant__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getReactant__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Reaction_getReactant'");
  XSRETURN(0);
}


XS(_wrap_Reaction_getProduct__SWIG_0) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getProduct(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getProduct" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Reaction_getProduct" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesReference *)((Reaction const *)arg1)->getProduct(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getProduct__SWIG_1) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getProduct(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getProduct" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Reaction_getProduct" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesReference *)(arg1)->getProduct(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getProduct__SWIG_2) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getProduct(self,species);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getProduct" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_getProduct" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_getProduct" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesReference *)((Reaction const *)arg1)->getProduct((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getProduct__SWIG_3) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getProduct(self,species);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getProduct" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_getProduct" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_getProduct" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesReference *)(arg1)->getProduct((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getProduct) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getProduct__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getProduct__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getProduct__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getProduct__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Reaction_getProduct'");
  XSRETURN(0);
}


XS(_wrap_Reaction_getModifier__SWIG_0) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    ModifierSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getModifier(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getModifier" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Reaction_getModifier" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (ModifierSpeciesReference *)((Reaction const *)arg1)->getModifier(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModifierSpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getModifier__SWIG_1) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    ModifierSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getModifier(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getModifier" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Reaction_getModifier" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (ModifierSpeciesReference *)(arg1)->getModifier(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModifierSpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getModifier__SWIG_2) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    ModifierSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getModifier(self,species);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getModifier" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_getModifier" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_getModifier" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (ModifierSpeciesReference *)((Reaction const *)arg1)->getModifier((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModifierSpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getModifier__SWIG_3) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    ModifierSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_getModifier(self,species);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getModifier" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_getModifier" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_getModifier" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (ModifierSpeciesReference *)(arg1)->getModifier((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModifierSpeciesReference, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getModifier) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getModifier__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getModifier__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getModifier__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_getModifier__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Reaction_getModifier'");
  XSRETURN(0);
}


XS(_wrap_Reaction_getNumReactants) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getNumReactants(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getNumReactants" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (unsigned int)((Reaction const *)arg1)->getNumReactants();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getNumProducts) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getNumProducts(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getNumProducts" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (unsigned int)((Reaction const *)arg1)->getNumProducts();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getNumModifiers) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getNumModifiers(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getNumModifiers" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (unsigned int)((Reaction const *)arg1)->getNumModifiers();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_removeReactant__SWIG_0) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_removeReactant(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_removeReactant" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Reaction_removeReactant" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesReference *)(arg1)->removeReactant(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_removeReactant__SWIG_1) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_removeReactant(self,species);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_removeReactant" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_removeReactant" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_removeReactant" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesReference *)(arg1)->removeReactant((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_removeReactant) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_removeReactant__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_removeReactant__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Reaction_removeReactant'");
  XSRETURN(0);
}


XS(_wrap_Reaction_removeProduct__SWIG_0) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_removeProduct(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_removeProduct" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Reaction_removeProduct" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SpeciesReference *)(arg1)->removeProduct(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_removeProduct__SWIG_1) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_removeProduct(self,species);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_removeProduct" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_removeProduct" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_removeProduct" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SpeciesReference *)(arg1)->removeProduct((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_removeProduct) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_removeProduct__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_removeProduct__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Reaction_removeProduct'");
  XSRETURN(0);
}


XS(_wrap_Reaction_removeModifier__SWIG_0) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    ModifierSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_removeModifier(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_removeModifier" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Reaction_removeModifier" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (ModifierSpeciesReference *)(arg1)->removeModifier(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModifierSpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_removeModifier__SWIG_1) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    ModifierSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Reaction_removeModifier(self,species);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_removeModifier" "', argument " "1"" of type '" "Reaction *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Reaction_removeModifier" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Reaction_removeModifier" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (ModifierSpeciesReference *)(arg1)->removeModifier((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModifierSpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_removeModifier) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Reaction, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_removeModifier__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Reaction_removeModifier__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Reaction_removeModifier'");
  XSRETURN(0);
}


XS(_wrap_Reaction_getTypeCode) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getTypeCode" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (SBMLTypeCode_t)((Reaction const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_getElementName) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_getElementName" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (std::string *) &((Reaction const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Reaction_hasRequiredAttributes) {
  {
    Reaction *arg1 = (Reaction *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Reaction_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Reaction, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Reaction_hasRequiredAttributes" "', argument " "1"" of type '" "Reaction const *""'"); 
    }
    arg1 = reinterpret_cast< Reaction * >(argp1);
    result = (bool)((Reaction const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfReactions_clone) {
  {
    ListOfReactions *arg1 = (ListOfReactions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfReactions *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfReactions_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfReactions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfReactions_clone" "', argument " "1"" of type '" "ListOfReactions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfReactions * >(argp1);
    result = (ListOfReactions *)((ListOfReactions const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfReactions, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfReactions_getTypeCode) {
  {
    ListOfReactions *arg1 = (ListOfReactions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfReactions_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfReactions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfReactions_getTypeCode" "', argument " "1"" of type '" "ListOfReactions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfReactions * >(argp1);
    result = (SBMLTypeCode_t)((ListOfReactions const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfReactions_getItemTypeCode) {
  {
    ListOfReactions *arg1 = (ListOfReactions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfReactions_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfReactions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfReactions_getItemTypeCode" "', argument " "1"" of type '" "ListOfReactions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfReactions * >(argp1);
    result = (SBMLTypeCode_t)((ListOfReactions const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfReactions_getElementName) {
  {
    ListOfReactions *arg1 = (ListOfReactions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfReactions_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfReactions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfReactions_getElementName" "', argument " "1"" of type '" "ListOfReactions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfReactions * >(argp1);
    result = (std::string *) &((ListOfReactions const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfReactions_get__SWIG_0) {
  {
    ListOfReactions *arg1 = (ListOfReactions *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfReactions_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfReactions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfReactions_get" "', argument " "1"" of type '" "ListOfReactions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfReactions * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfReactions_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Reaction *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfReactions_get__SWIG_1) {
  {
    ListOfReactions *arg1 = (ListOfReactions *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfReactions_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfReactions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfReactions_get" "', argument " "1"" of type '" "ListOfReactions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfReactions * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfReactions_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Reaction *)((ListOfReactions const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfReactions_get__SWIG_2) {
  {
    ListOfReactions *arg1 = (ListOfReactions *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfReactions_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfReactions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfReactions_get" "', argument " "1"" of type '" "ListOfReactions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfReactions * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfReactions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfReactions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Reaction *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfReactions_get__SWIG_3) {
  {
    ListOfReactions *arg1 = (ListOfReactions *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfReactions_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfReactions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfReactions_get" "', argument " "1"" of type '" "ListOfReactions const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfReactions * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfReactions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfReactions_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Reaction *)((ListOfReactions const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfReactions_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfReactions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfReactions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfReactions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfReactions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfReactions_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfReactions_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfReactions_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfReactions_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfReactions_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfReactions_remove__SWIG_0) {
  {
    ListOfReactions *arg1 = (ListOfReactions *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfReactions_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfReactions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfReactions_remove" "', argument " "1"" of type '" "ListOfReactions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfReactions * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfReactions_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Reaction *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfReactions_remove__SWIG_1) {
  {
    ListOfReactions *arg1 = (ListOfReactions *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Reaction *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfReactions_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfReactions, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfReactions_remove" "', argument " "1"" of type '" "ListOfReactions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfReactions * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfReactions_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfReactions_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Reaction *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Reaction, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfReactions_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfReactions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfReactions, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfReactions_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfReactions_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfReactions_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfReactions) {
  {
    int argvi = 0;
    ListOfReactions *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfReactions();");
    }
    result = (ListOfReactions *)new ListOfReactions();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfReactions, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfReactions) {
  {
    ListOfReactions *arg1 = (ListOfReactions *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfReactions(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfReactions, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfReactions" "', argument " "1"" of type '" "ListOfReactions *""'"); 
    }
    arg1 = reinterpret_cast< ListOfReactions * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_KineticLaw__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    KineticLaw *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_KineticLaw(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_KineticLaw" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_KineticLaw" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (KineticLaw *)new KineticLaw(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_KineticLaw, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_KineticLaw__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    KineticLaw *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_KineticLaw(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_KineticLaw" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (KineticLaw *)new KineticLaw(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_KineticLaw, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_KineticLaw) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_KineticLaw(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_KineticLaw" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_KineticLaw__SWIG_2) {
  {
    KineticLaw *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    KineticLaw *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_KineticLaw(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_KineticLaw,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_KineticLaw" "', argument " "1"" of type '" "KineticLaw const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_KineticLaw" "', argument " "1"" of type '" "KineticLaw const &""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    {
      try {
        result = (KineticLaw *)new KineticLaw((KineticLaw const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_KineticLaw, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_KineticLaw) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_KineticLaw__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_KineticLaw__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_KineticLaw__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_KineticLaw'");
  XSRETURN(0);
}


XS(_wrap_KineticLaw_clone) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    KineticLaw *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_clone" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (KineticLaw *)((KineticLaw const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_KineticLaw, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getFormula) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getFormula(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getFormula" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (std::string *) &((KineticLaw const *)arg1)->getFormula();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getMath) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getMath" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (ASTNode *)((KineticLaw const *)arg1)->getMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getTimeUnits) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getTimeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getTimeUnits" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (std::string *) &((KineticLaw const *)arg1)->getTimeUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getSubstanceUnits) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getSubstanceUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getSubstanceUnits" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (std::string *) &((KineticLaw const *)arg1)->getSubstanceUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_isSetFormula) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_isSetFormula(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_isSetFormula" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (bool)((KineticLaw const *)arg1)->isSetFormula();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_isSetMath) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_isSetMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_isSetMath" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (bool)((KineticLaw const *)arg1)->isSetMath();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_isSetTimeUnits) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_isSetTimeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_isSetTimeUnits" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (bool)((KineticLaw const *)arg1)->isSetTimeUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_isSetSubstanceUnits) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_isSetSubstanceUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_isSetSubstanceUnits" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (bool)((KineticLaw const *)arg1)->isSetSubstanceUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_setFormula) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_setFormula(self,formula);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_setFormula" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_setFormula" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "KineticLaw_setFormula" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setFormula((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_setMath) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_setMath(self,math);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_setMath" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_setMath" "', argument " "2"" of type '" "ASTNode const *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->setMath((ASTNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_setTimeUnits) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_setTimeUnits(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_setTimeUnits" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_setTimeUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "KineticLaw_setTimeUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setTimeUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_setSubstanceUnits) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_setSubstanceUnits(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_setSubstanceUnits" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_setSubstanceUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "KineticLaw_setSubstanceUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setSubstanceUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_unsetTimeUnits) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_unsetTimeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_unsetTimeUnits" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (int)(arg1)->unsetTimeUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_unsetSubstanceUnits) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_unsetSubstanceUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_unsetSubstanceUnits" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (int)(arg1)->unsetSubstanceUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_addParameter) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    Parameter *arg2 = (Parameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_addParameter(self,p);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_addParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Parameter, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_addParameter" "', argument " "2"" of type '" "Parameter const *""'"); 
    }
    arg2 = reinterpret_cast< Parameter * >(argp2);
    result = (int)(arg1)->addParameter((Parameter const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_addLocalParameter) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    LocalParameter *arg2 = (LocalParameter *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_addLocalParameter(self,p);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_addLocalParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_LocalParameter, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_addLocalParameter" "', argument " "2"" of type '" "LocalParameter const *""'"); 
    }
    arg2 = reinterpret_cast< LocalParameter * >(argp2);
    result = (int)(arg1)->addLocalParameter((LocalParameter const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_createParameter) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_createParameter(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_createParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (Parameter *)(arg1)->createParameter();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_createLocalParameter) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_createLocalParameter(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_createLocalParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (LocalParameter *)(arg1)->createLocalParameter();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getListOfParameters__SWIG_0) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfParameters *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getListOfParameters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getListOfParameters" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (ListOfParameters *)((KineticLaw const *)arg1)->getListOfParameters();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfParameters, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getListOfParameters__SWIG_1) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfParameters *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getListOfParameters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getListOfParameters" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (ListOfParameters *)(arg1)->getListOfParameters();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfParameters, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getListOfParameters) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getListOfParameters__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getListOfParameters__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'KineticLaw_getListOfParameters'");
  XSRETURN(0);
}


XS(_wrap_KineticLaw_getListOfLocalParameters__SWIG_0) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfLocalParameters *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getListOfLocalParameters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getListOfLocalParameters" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (ListOfLocalParameters *)((KineticLaw const *)arg1)->getListOfLocalParameters();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfLocalParameters, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getListOfLocalParameters__SWIG_1) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfLocalParameters *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getListOfLocalParameters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getListOfLocalParameters" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (ListOfLocalParameters *)(arg1)->getListOfLocalParameters();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfLocalParameters, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getListOfLocalParameters) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getListOfLocalParameters__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getListOfLocalParameters__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'KineticLaw_getListOfLocalParameters'");
  XSRETURN(0);
}


XS(_wrap_KineticLaw_getParameter__SWIG_0) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_getParameter(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getParameter" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "KineticLaw_getParameter" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Parameter *)((KineticLaw const *)arg1)->getParameter(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getParameter__SWIG_1) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_getParameter(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "KineticLaw_getParameter" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Parameter *)(arg1)->getParameter(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getLocalParameter__SWIG_0) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_getLocalParameter(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getLocalParameter" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "KineticLaw_getLocalParameter" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (LocalParameter *)((KineticLaw const *)arg1)->getLocalParameter(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getLocalParameter__SWIG_1) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_getLocalParameter(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getLocalParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "KineticLaw_getLocalParameter" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (LocalParameter *)(arg1)->getLocalParameter(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getParameter__SWIG_2) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_getParameter(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getParameter" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_getParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "KineticLaw_getParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Parameter *)((KineticLaw const *)arg1)->getParameter((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getParameter__SWIG_3) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_getParameter(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_getParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "KineticLaw_getParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Parameter *)(arg1)->getParameter((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getParameter) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getParameter__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getParameter__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getParameter__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getParameter__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'KineticLaw_getParameter'");
  XSRETURN(0);
}


XS(_wrap_KineticLaw_getLocalParameter__SWIG_2) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_getLocalParameter(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getLocalParameter" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_getLocalParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "KineticLaw_getLocalParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (LocalParameter *)((KineticLaw const *)arg1)->getLocalParameter((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getLocalParameter__SWIG_3) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_getLocalParameter(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getLocalParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_getLocalParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "KineticLaw_getLocalParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (LocalParameter *)(arg1)->getLocalParameter((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getLocalParameter) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getLocalParameter__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getLocalParameter__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getLocalParameter__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getLocalParameter__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'KineticLaw_getLocalParameter'");
  XSRETURN(0);
}


XS(_wrap_KineticLaw_getNumParameters) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getNumParameters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getNumParameters" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (unsigned int)((KineticLaw const *)arg1)->getNumParameters();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getNumLocalParameters) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getNumLocalParameters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getNumLocalParameters" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (unsigned int)((KineticLaw const *)arg1)->getNumLocalParameters();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getDerivedUnitDefinition__SWIG_0) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getDerivedUnitDefinition" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (UnitDefinition *)(arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getDerivedUnitDefinition__SWIG_1) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getDerivedUnitDefinition" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (UnitDefinition *)((KineticLaw const *)arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getDerivedUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getDerivedUnitDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_getDerivedUnitDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'KineticLaw_getDerivedUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_KineticLaw_containsUndeclaredUnits__SWIG_0) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_containsUndeclaredUnits" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (bool)(arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_containsUndeclaredUnits__SWIG_1) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_containsUndeclaredUnits" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (bool)((KineticLaw const *)arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_containsUndeclaredUnits) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_containsUndeclaredUnits__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_containsUndeclaredUnits__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'KineticLaw_containsUndeclaredUnits'");
  XSRETURN(0);
}


XS(_wrap_KineticLaw_removeParameter__SWIG_0) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_removeParameter(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_removeParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "KineticLaw_removeParameter" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Parameter *)(arg1)->removeParameter(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_removeLocalParameter__SWIG_0) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_removeLocalParameter(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_removeLocalParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "KineticLaw_removeLocalParameter" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (LocalParameter *)(arg1)->removeLocalParameter(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_removeParameter__SWIG_1) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Parameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_removeParameter(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_removeParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_removeParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "KineticLaw_removeParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Parameter *)(arg1)->removeParameter((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Parameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_removeParameter) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_removeParameter__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_removeParameter__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'KineticLaw_removeParameter'");
  XSRETURN(0);
}


XS(_wrap_KineticLaw_removeLocalParameter__SWIG_1) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    LocalParameter *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: KineticLaw_removeLocalParameter(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_removeLocalParameter" "', argument " "1"" of type '" "KineticLaw *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "KineticLaw_removeLocalParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "KineticLaw_removeLocalParameter" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (LocalParameter *)(arg1)->removeLocalParameter((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_LocalParameter, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_removeLocalParameter) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_KineticLaw, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_removeLocalParameter__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_KineticLaw_removeLocalParameter__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'KineticLaw_removeLocalParameter'");
  XSRETURN(0);
}


XS(_wrap_KineticLaw_getTypeCode) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getTypeCode" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (SBMLTypeCode_t)((KineticLaw const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_getElementName) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_getElementName" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (std::string *) &((KineticLaw const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_hasRequiredAttributes) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_hasRequiredAttributes" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (bool)((KineticLaw const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_KineticLaw_hasRequiredElements) {
  {
    KineticLaw *arg1 = (KineticLaw *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: KineticLaw_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_KineticLaw, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "KineticLaw_hasRequiredElements" "', argument " "1"" of type '" "KineticLaw const *""'"); 
    }
    arg1 = reinterpret_cast< KineticLaw * >(argp1);
    result = (bool)((KineticLaw const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SimpleSpeciesReference) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SimpleSpeciesReference(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SimpleSpeciesReference" "', argument " "1"" of type '" "SimpleSpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_getId) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SimpleSpeciesReference_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_getId" "', argument " "1"" of type '" "SimpleSpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    result = (std::string *) &((SimpleSpeciesReference const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_getName) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SimpleSpeciesReference_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_getName" "', argument " "1"" of type '" "SimpleSpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    result = (std::string *) &((SimpleSpeciesReference const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_getSpecies) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SimpleSpeciesReference_getSpecies(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_getSpecies" "', argument " "1"" of type '" "SimpleSpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    result = (std::string *) &((SimpleSpeciesReference const *)arg1)->getSpecies();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_isSetId) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SimpleSpeciesReference_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_isSetId" "', argument " "1"" of type '" "SimpleSpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    result = (bool)((SimpleSpeciesReference const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_isSetName) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SimpleSpeciesReference_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_isSetName" "', argument " "1"" of type '" "SimpleSpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    result = (bool)((SimpleSpeciesReference const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_isSetSpecies) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SimpleSpeciesReference_isSetSpecies(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_isSetSpecies" "', argument " "1"" of type '" "SimpleSpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    result = (bool)((SimpleSpeciesReference const *)arg1)->isSetSpecies();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_setSpecies) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SimpleSpeciesReference_setSpecies(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_setSpecies" "', argument " "1"" of type '" "SimpleSpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SimpleSpeciesReference_setSpecies" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SimpleSpeciesReference_setSpecies" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setSpecies((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_setId) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SimpleSpeciesReference_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_setId" "', argument " "1"" of type '" "SimpleSpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SimpleSpeciesReference_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SimpleSpeciesReference_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_setName) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SimpleSpeciesReference_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_setName" "', argument " "1"" of type '" "SimpleSpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SimpleSpeciesReference_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SimpleSpeciesReference_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_unsetId) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SimpleSpeciesReference_unsetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_unsetId" "', argument " "1"" of type '" "SimpleSpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    result = (int)(arg1)->unsetId();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_unsetName) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SimpleSpeciesReference_unsetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_unsetName" "', argument " "1"" of type '" "SimpleSpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    result = (int)(arg1)->unsetName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SimpleSpeciesReference_isModifier) {
  {
    SimpleSpeciesReference *arg1 = (SimpleSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SimpleSpeciesReference_isModifier(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SimpleSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SimpleSpeciesReference_isModifier" "', argument " "1"" of type '" "SimpleSpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SimpleSpeciesReference * >(argp1);
    result = (bool)((SimpleSpeciesReference const *)arg1)->isModifier();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SpeciesReference__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_SpeciesReference(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SpeciesReference" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_SpeciesReference" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (SpeciesReference *)new SpeciesReference(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SpeciesReference__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SpeciesReference(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_SpeciesReference" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (SpeciesReference *)new SpeciesReference(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SpeciesReference) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SpeciesReference(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SpeciesReference" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SpeciesReference__SWIG_2) {
  {
    SpeciesReference *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SpeciesReference(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_SpeciesReference,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_SpeciesReference" "', argument " "1"" of type '" "SpeciesReference const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_SpeciesReference" "', argument " "1"" of type '" "SpeciesReference const &""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    {
      try {
        result = (SpeciesReference *)new SpeciesReference((SpeciesReference const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SpeciesReference) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SpeciesReference, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SpeciesReference__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SpeciesReference__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SpeciesReference__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_SpeciesReference'");
  XSRETURN(0);
}


XS(_wrap_SpeciesReference_clone) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_clone" "', argument " "1"" of type '" "SpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (SpeciesReference *)((SpeciesReference const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_initDefaults) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_initDefaults(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_initDefaults" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    (arg1)->initDefaults();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_getStoichiometry) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_getStoichiometry(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_getStoichiometry" "', argument " "1"" of type '" "SpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (double)((SpeciesReference const *)arg1)->getStoichiometry();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_getStoichiometryMath__SWIG_0) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    StoichiometryMath *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_getStoichiometryMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_getStoichiometryMath" "', argument " "1"" of type '" "SpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (StoichiometryMath *)((SpeciesReference const *)arg1)->getStoichiometryMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_StoichiometryMath, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_getStoichiometryMath__SWIG_1) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    StoichiometryMath *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_getStoichiometryMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_getStoichiometryMath" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (StoichiometryMath *)(arg1)->getStoichiometryMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_StoichiometryMath, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_getStoichiometryMath) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SpeciesReference, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SpeciesReference, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SpeciesReference_getStoichiometryMath__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SpeciesReference_getStoichiometryMath__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'SpeciesReference_getStoichiometryMath'");
  XSRETURN(0);
}


XS(_wrap_SpeciesReference_getDenominator) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_getDenominator(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_getDenominator" "', argument " "1"" of type '" "SpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (int)((SpeciesReference const *)arg1)->getDenominator();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_getConstant) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_getConstant(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_getConstant" "', argument " "1"" of type '" "SpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (bool)((SpeciesReference const *)arg1)->getConstant();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_isSetStoichiometryMath) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_isSetStoichiometryMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_isSetStoichiometryMath" "', argument " "1"" of type '" "SpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (bool)((SpeciesReference const *)arg1)->isSetStoichiometryMath();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_isSetConstant) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_isSetConstant(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_isSetConstant" "', argument " "1"" of type '" "SpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (bool)((SpeciesReference const *)arg1)->isSetConstant();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_isSetStoichiometry) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_isSetStoichiometry(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_isSetStoichiometry" "', argument " "1"" of type '" "SpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (bool)((SpeciesReference const *)arg1)->isSetStoichiometry();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_setStoichiometry) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SpeciesReference_setStoichiometry(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_setStoichiometry" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SpeciesReference_setStoichiometry" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    result = (int)(arg1)->setStoichiometry(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_setStoichiometryMath) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    StoichiometryMath *arg2 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SpeciesReference_setStoichiometryMath(self,math);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_setStoichiometryMath" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SpeciesReference_setStoichiometryMath" "', argument " "2"" of type '" "StoichiometryMath const *""'"); 
    }
    arg2 = reinterpret_cast< StoichiometryMath * >(argp2);
    result = (int)(arg1)->setStoichiometryMath((StoichiometryMath const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_setDenominator) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SpeciesReference_setDenominator(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_setDenominator" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SpeciesReference_setDenominator" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (int)(arg1)->setDenominator(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_setConstant) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SpeciesReference_setConstant(self,flag);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_setConstant" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SpeciesReference_setConstant" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (int)(arg1)->setConstant(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_unsetStoichiometryMath) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_unsetStoichiometryMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_unsetStoichiometryMath" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (int)(arg1)->unsetStoichiometryMath();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_unsetStoichiometry) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_unsetStoichiometry(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_unsetStoichiometry" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (int)(arg1)->unsetStoichiometry();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_createStoichiometryMath) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    StoichiometryMath *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_createStoichiometryMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_createStoichiometryMath" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (StoichiometryMath *)(arg1)->createStoichiometryMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_StoichiometryMath, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_setAnnotation__SWIG_0) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    XMLNode *arg2 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SpeciesReference_setAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_setAnnotation" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SpeciesReference_setAnnotation" "', argument " "2"" of type '" "XMLNode const *""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (int)(arg1)->setAnnotation((XMLNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_setAnnotation__SWIG_1) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SpeciesReference_setAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_setAnnotation" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SpeciesReference_setAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SpeciesReference_setAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setAnnotation((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_setAnnotation) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SpeciesReference, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SpeciesReference, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SpeciesReference_setAnnotation__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SpeciesReference_setAnnotation__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'SpeciesReference_setAnnotation'");
  XSRETURN(0);
}


XS(_wrap_SpeciesReference_appendAnnotation__SWIG_0) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    XMLNode *arg2 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SpeciesReference_appendAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_appendAnnotation" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SpeciesReference_appendAnnotation" "', argument " "2"" of type '" "XMLNode const *""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (int)(arg1)->appendAnnotation((XMLNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_appendAnnotation__SWIG_1) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SpeciesReference_appendAnnotation(self,annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_appendAnnotation" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SpeciesReference_appendAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SpeciesReference_appendAnnotation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->appendAnnotation((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_appendAnnotation) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SpeciesReference, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SpeciesReference, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SpeciesReference_appendAnnotation__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SpeciesReference_appendAnnotation__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'SpeciesReference_appendAnnotation'");
  XSRETURN(0);
}


XS(_wrap_SpeciesReference_getTypeCode) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_getTypeCode" "', argument " "1"" of type '" "SpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (SBMLTypeCode_t)((SpeciesReference const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_getElementName) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_getElementName" "', argument " "1"" of type '" "SpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (std::string *) &((SpeciesReference const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_initL2Stoichiometry) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_initL2Stoichiometry(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_initL2Stoichiometry" "', argument " "1"" of type '" "SpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    (arg1)->initL2Stoichiometry();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SpeciesReference_hasRequiredAttributes) {
  {
    SpeciesReference *arg1 = (SpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SpeciesReference_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SpeciesReference_hasRequiredAttributes" "', argument " "1"" of type '" "SpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< SpeciesReference * >(argp1);
    result = (bool)((SpeciesReference const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ModifierSpeciesReference__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    ModifierSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_ModifierSpeciesReference(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_ModifierSpeciesReference" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_ModifierSpeciesReference" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (ModifierSpeciesReference *)new ModifierSpeciesReference(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModifierSpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ModifierSpeciesReference__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ModifierSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_ModifierSpeciesReference(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_ModifierSpeciesReference" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (ModifierSpeciesReference *)new ModifierSpeciesReference(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModifierSpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ModifierSpeciesReference) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ModifierSpeciesReference__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ModifierSpeciesReference__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_ModifierSpeciesReference'");
  XSRETURN(0);
}


XS(_wrap_delete_ModifierSpeciesReference) {
  {
    ModifierSpeciesReference *arg1 = (ModifierSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ModifierSpeciesReference(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModifierSpeciesReference, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ModifierSpeciesReference" "', argument " "1"" of type '" "ModifierSpeciesReference *""'"); 
    }
    arg1 = reinterpret_cast< ModifierSpeciesReference * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModifierSpeciesReference_clone) {
  {
    ModifierSpeciesReference *arg1 = (ModifierSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ModifierSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModifierSpeciesReference_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModifierSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModifierSpeciesReference_clone" "', argument " "1"" of type '" "ModifierSpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< ModifierSpeciesReference * >(argp1);
    result = (ModifierSpeciesReference *)((ModifierSpeciesReference const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModifierSpeciesReference, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModifierSpeciesReference_getTypeCode) {
  {
    ModifierSpeciesReference *arg1 = (ModifierSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModifierSpeciesReference_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModifierSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModifierSpeciesReference_getTypeCode" "', argument " "1"" of type '" "ModifierSpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< ModifierSpeciesReference * >(argp1);
    result = (SBMLTypeCode_t)((ModifierSpeciesReference const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModifierSpeciesReference_getElementName) {
  {
    ModifierSpeciesReference *arg1 = (ModifierSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModifierSpeciesReference_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModifierSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModifierSpeciesReference_getElementName" "', argument " "1"" of type '" "ModifierSpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< ModifierSpeciesReference * >(argp1);
    result = (std::string *) &((ModifierSpeciesReference const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModifierSpeciesReference_hasRequiredAttributes) {
  {
    ModifierSpeciesReference *arg1 = (ModifierSpeciesReference *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModifierSpeciesReference_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModifierSpeciesReference, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModifierSpeciesReference_hasRequiredAttributes" "', argument " "1"" of type '" "ModifierSpeciesReference const *""'"); 
    }
    arg1 = reinterpret_cast< ModifierSpeciesReference * >(argp1);
    result = (bool)((ModifierSpeciesReference const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ListOfSpeciesReferences) {
  {
    int argvi = 0;
    ListOfSpeciesReferences *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfSpeciesReferences();");
    }
    result = (ListOfSpeciesReferences *)new ListOfSpeciesReferences();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesReferences, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesReferences_clone) {
  {
    ListOfSpeciesReferences *arg1 = (ListOfSpeciesReferences *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfSpeciesReferences *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpeciesReferences_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesReferences, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesReferences_clone" "', argument " "1"" of type '" "ListOfSpeciesReferences const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesReferences * >(argp1);
    result = (ListOfSpeciesReferences *)((ListOfSpeciesReferences const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfSpeciesReferences, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesReferences_getTypeCode) {
  {
    ListOfSpeciesReferences *arg1 = (ListOfSpeciesReferences *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpeciesReferences_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesReferences, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesReferences_getTypeCode" "', argument " "1"" of type '" "ListOfSpeciesReferences const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesReferences * >(argp1);
    result = (SBMLTypeCode_t)((ListOfSpeciesReferences const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesReferences_getItemTypeCode) {
  {
    ListOfSpeciesReferences *arg1 = (ListOfSpeciesReferences *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpeciesReferences_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesReferences, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesReferences_getItemTypeCode" "', argument " "1"" of type '" "ListOfSpeciesReferences const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesReferences * >(argp1);
    result = (SBMLTypeCode_t)((ListOfSpeciesReferences const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesReferences_getElementName) {
  {
    ListOfSpeciesReferences *arg1 = (ListOfSpeciesReferences *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfSpeciesReferences_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesReferences, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesReferences_getElementName" "', argument " "1"" of type '" "ListOfSpeciesReferences const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesReferences * >(argp1);
    result = (std::string *) &((ListOfSpeciesReferences const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesReferences_get__SWIG_0) {
  {
    ListOfSpeciesReferences *arg1 = (ListOfSpeciesReferences *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SimpleSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesReferences_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesReferences, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesReferences_get" "', argument " "1"" of type '" "ListOfSpeciesReferences *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesReferences * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfSpeciesReferences_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SimpleSpeciesReference *)(arg1)->get(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesReferences_get__SWIG_1) {
  {
    ListOfSpeciesReferences *arg1 = (ListOfSpeciesReferences *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SimpleSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesReferences_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesReferences, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesReferences_get" "', argument " "1"" of type '" "ListOfSpeciesReferences const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesReferences * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfSpeciesReferences_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SimpleSpeciesReference *)((ListOfSpeciesReferences const *)arg1)->get(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesReferences_get__SWIG_2) {
  {
    ListOfSpeciesReferences *arg1 = (ListOfSpeciesReferences *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SimpleSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesReferences_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesReferences, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesReferences_get" "', argument " "1"" of type '" "ListOfSpeciesReferences *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesReferences * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfSpeciesReferences_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfSpeciesReferences_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SimpleSpeciesReference *)(arg1)->get((std::string const &)*arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesReferences_get__SWIG_3) {
  {
    ListOfSpeciesReferences *arg1 = (ListOfSpeciesReferences *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SimpleSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesReferences_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesReferences, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesReferences_get" "', argument " "1"" of type '" "ListOfSpeciesReferences const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesReferences * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfSpeciesReferences_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfSpeciesReferences_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SimpleSpeciesReference *)((ListOfSpeciesReferences const *)arg1)->get((std::string const &)*arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesReferences_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesReferences, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesReferences, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesReferences, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesReferences, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesReferences_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesReferences_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesReferences_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesReferences_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfSpeciesReferences_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfSpeciesReferences_remove__SWIG_0) {
  {
    ListOfSpeciesReferences *arg1 = (ListOfSpeciesReferences *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SimpleSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesReferences_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesReferences, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesReferences_remove" "', argument " "1"" of type '" "ListOfSpeciesReferences *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesReferences * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfSpeciesReferences_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SimpleSpeciesReference *)(arg1)->remove(arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        SWIG_OWNER | SWIG_SHADOW);
      argvi++;
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesReferences_remove__SWIG_1) {
  {
    ListOfSpeciesReferences *arg1 = (ListOfSpeciesReferences *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    SimpleSpeciesReference *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfSpeciesReferences_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesReferences, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfSpeciesReferences_remove" "', argument " "1"" of type '" "ListOfSpeciesReferences *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesReferences * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfSpeciesReferences_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfSpeciesReferences_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (SimpleSpeciesReference *)(arg1)->remove((std::string const &)*arg2);
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        SWIG_OWNER | SWIG_SHADOW);
      argvi++;
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfSpeciesReferences_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesReferences, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfSpeciesReferences, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesReferences_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfSpeciesReferences_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfSpeciesReferences_remove'");
  XSRETURN(0);
}


XS(_wrap_delete_ListOfSpeciesReferences) {
  {
    ListOfSpeciesReferences *arg1 = (ListOfSpeciesReferences *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfSpeciesReferences(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfSpeciesReferences, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfSpeciesReferences" "', argument " "1"" of type '" "ListOfSpeciesReferences *""'"); 
    }
    arg1 = reinterpret_cast< ListOfSpeciesReferences * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Event__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Event(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Event" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Event" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (Event *)new Event(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Event__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Event(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Event" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (Event *)new Event(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Event) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Event(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Event" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Event__SWIG_2) {
  {
    Event *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Event(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Event,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Event" "', argument " "1"" of type '" "Event const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Event" "', argument " "1"" of type '" "Event const &""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    {
      try {
        result = (Event *)new Event((Event const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Event) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Event__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Event__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Event__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Event'");
  XSRETURN(0);
}


XS(_wrap_Event_clone) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_clone" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (Event *)((Event const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getId) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getId" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (std::string *) &((Event const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getName) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getName" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (std::string *) &((Event const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getTrigger__SWIG_0) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Trigger *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getTrigger(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getTrigger" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (Trigger *)((Event const *)arg1)->getTrigger();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Trigger, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getTrigger__SWIG_1) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Trigger *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getTrigger(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getTrigger" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (Trigger *)(arg1)->getTrigger();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Trigger, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getTrigger) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getTrigger__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getTrigger__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Event_getTrigger'");
  XSRETURN(0);
}


XS(_wrap_Event_getDelay__SWIG_0) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Delay *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getDelay(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getDelay" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (Delay *)((Event const *)arg1)->getDelay();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Delay, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getDelay__SWIG_1) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Delay *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getDelay(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getDelay" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (Delay *)(arg1)->getDelay();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Delay, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getDelay) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getDelay__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getDelay__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Event_getDelay'");
  XSRETURN(0);
}


XS(_wrap_Event_getPriority__SWIG_0) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Priority *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getPriority(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getPriority" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (Priority *)((Event const *)arg1)->getPriority();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Priority, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getPriority__SWIG_1) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Priority *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getPriority(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getPriority" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (Priority *)(arg1)->getPriority();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Priority, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getPriority) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getPriority__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getPriority__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Event_getPriority'");
  XSRETURN(0);
}


XS(_wrap_Event_getTimeUnits) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getTimeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getTimeUnits" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (std::string *) &((Event const *)arg1)->getTimeUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getUseValuesFromTriggerTime) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getUseValuesFromTriggerTime(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getUseValuesFromTriggerTime" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (bool)((Event const *)arg1)->getUseValuesFromTriggerTime();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_isSetId) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_isSetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_isSetId" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (bool)((Event const *)arg1)->isSetId();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_isSetName) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_isSetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_isSetName" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (bool)((Event const *)arg1)->isSetName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_isSetTrigger) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_isSetTrigger(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_isSetTrigger" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (bool)((Event const *)arg1)->isSetTrigger();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_isSetDelay) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_isSetDelay(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_isSetDelay" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (bool)((Event const *)arg1)->isSetDelay();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_isSetPriority) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_isSetPriority(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_isSetPriority" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (bool)((Event const *)arg1)->isSetPriority();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_isSetTimeUnits) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_isSetTimeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_isSetTimeUnits" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (bool)((Event const *)arg1)->isSetTimeUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_isSetUseValuesFromTriggerTime) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_isSetUseValuesFromTriggerTime(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_isSetUseValuesFromTriggerTime" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (bool)((Event const *)arg1)->isSetUseValuesFromTriggerTime();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_setId) {
  {
    Event *arg1 = (Event *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_setId(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_setId" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Event_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Event_setId" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setId((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Event_setName) {
  {
    Event *arg1 = (Event *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_setName" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Event_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Event_setName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Event_setTrigger) {
  {
    Event *arg1 = (Event *) 0 ;
    Trigger *arg2 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_setTrigger(self,trigger);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_setTrigger" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Event_setTrigger" "', argument " "2"" of type '" "Trigger const *""'"); 
    }
    arg2 = reinterpret_cast< Trigger * >(argp2);
    result = (int)(arg1)->setTrigger((Trigger const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_setDelay) {
  {
    Event *arg1 = (Event *) 0 ;
    Delay *arg2 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_setDelay(self,delay);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_setDelay" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Event_setDelay" "', argument " "2"" of type '" "Delay const *""'"); 
    }
    arg2 = reinterpret_cast< Delay * >(argp2);
    result = (int)(arg1)->setDelay((Delay const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_setPriority) {
  {
    Event *arg1 = (Event *) 0 ;
    Priority *arg2 = (Priority *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_setPriority(self,priority);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_setPriority" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Priority, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Event_setPriority" "', argument " "2"" of type '" "Priority const *""'"); 
    }
    arg2 = reinterpret_cast< Priority * >(argp2);
    result = (int)(arg1)->setPriority((Priority const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_setTimeUnits) {
  {
    Event *arg1 = (Event *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_setTimeUnits(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_setTimeUnits" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Event_setTimeUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Event_setTimeUnits" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setTimeUnits((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Event_setUseValuesFromTriggerTime) {
  {
    Event *arg1 = (Event *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_setUseValuesFromTriggerTime(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_setUseValuesFromTriggerTime" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Event_setUseValuesFromTriggerTime" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (int)(arg1)->setUseValuesFromTriggerTime(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_unsetId) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_unsetId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_unsetId" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (int)(arg1)->unsetId();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_unsetName) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_unsetName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_unsetName" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (int)(arg1)->unsetName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_unsetDelay) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_unsetDelay(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_unsetDelay" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (int)(arg1)->unsetDelay();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_unsetPriority) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_unsetPriority(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_unsetPriority" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (int)(arg1)->unsetPriority();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_unsetTimeUnits) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_unsetTimeUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_unsetTimeUnits" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (int)(arg1)->unsetTimeUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_addEventAssignment) {
  {
    Event *arg1 = (Event *) 0 ;
    EventAssignment *arg2 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_addEventAssignment(self,ea);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_addEventAssignment" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Event_addEventAssignment" "', argument " "2"" of type '" "EventAssignment const *""'"); 
    }
    arg2 = reinterpret_cast< EventAssignment * >(argp2);
    result = (int)(arg1)->addEventAssignment((EventAssignment const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_createEventAssignment) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_createEventAssignment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_createEventAssignment" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (EventAssignment *)(arg1)->createEventAssignment();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_createTrigger) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Trigger *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_createTrigger(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_createTrigger" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (Trigger *)(arg1)->createTrigger();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Trigger, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_createDelay) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Delay *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_createDelay(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_createDelay" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (Delay *)(arg1)->createDelay();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Delay, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_createPriority) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Priority *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_createPriority(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_createPriority" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (Priority *)(arg1)->createPriority();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Priority, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getListOfEventAssignments__SWIG_0) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfEventAssignments *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getListOfEventAssignments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getListOfEventAssignments" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (ListOfEventAssignments *)((Event const *)arg1)->getListOfEventAssignments();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfEventAssignments, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getListOfEventAssignments__SWIG_1) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfEventAssignments *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getListOfEventAssignments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getListOfEventAssignments" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (ListOfEventAssignments *)(arg1)->getListOfEventAssignments();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfEventAssignments, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getListOfEventAssignments) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getListOfEventAssignments__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getListOfEventAssignments__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'Event_getListOfEventAssignments'");
  XSRETURN(0);
}


XS(_wrap_Event_getEventAssignment__SWIG_0) {
  {
    Event *arg1 = (Event *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_getEventAssignment(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getEventAssignment" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Event_getEventAssignment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (EventAssignment *)((Event const *)arg1)->getEventAssignment(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getEventAssignment__SWIG_1) {
  {
    Event *arg1 = (Event *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_getEventAssignment(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getEventAssignment" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Event_getEventAssignment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (EventAssignment *)(arg1)->getEventAssignment(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getEventAssignment__SWIG_2) {
  {
    Event *arg1 = (Event *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_getEventAssignment(self,variable);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getEventAssignment" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Event_getEventAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Event_getEventAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (EventAssignment *)((Event const *)arg1)->getEventAssignment((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getEventAssignment__SWIG_3) {
  {
    Event *arg1 = (Event *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_getEventAssignment(self,variable);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getEventAssignment" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Event_getEventAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Event_getEventAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (EventAssignment *)(arg1)->getEventAssignment((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getEventAssignment) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getEventAssignment__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getEventAssignment__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getEventAssignment__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_getEventAssignment__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'Event_getEventAssignment'");
  XSRETURN(0);
}


XS(_wrap_Event_getNumEventAssignments) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getNumEventAssignments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getNumEventAssignments" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (unsigned int)((Event const *)arg1)->getNumEventAssignments();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_removeEventAssignment__SWIG_0) {
  {
    Event *arg1 = (Event *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_removeEventAssignment(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_removeEventAssignment" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Event_removeEventAssignment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (EventAssignment *)(arg1)->removeEventAssignment(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_removeEventAssignment__SWIG_1) {
  {
    Event *arg1 = (Event *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Event_removeEventAssignment(self,variable);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_removeEventAssignment" "', argument " "1"" of type '" "Event *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Event_removeEventAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Event_removeEventAssignment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (EventAssignment *)(arg1)->removeEventAssignment((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Event_removeEventAssignment) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Event, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_removeEventAssignment__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Event_removeEventAssignment__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Event_removeEventAssignment'");
  XSRETURN(0);
}


XS(_wrap_Event_getTypeCode) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getTypeCode" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (SBMLTypeCode_t)((Event const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_getElementName) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_getElementName" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (std::string *) &((Event const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_hasRequiredAttributes) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_hasRequiredAttributes" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (bool)((Event const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Event_hasRequiredElements) {
  {
    Event *arg1 = (Event *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Event_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Event, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Event_hasRequiredElements" "', argument " "1"" of type '" "Event const *""'"); 
    }
    arg1 = reinterpret_cast< Event * >(argp1);
    result = (bool)((Event const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEvents_clone) {
  {
    ListOfEvents *arg1 = (ListOfEvents *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfEvents *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfEvents_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEvents, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEvents_clone" "', argument " "1"" of type '" "ListOfEvents const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEvents * >(argp1);
    result = (ListOfEvents *)((ListOfEvents const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfEvents, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEvents_getTypeCode) {
  {
    ListOfEvents *arg1 = (ListOfEvents *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfEvents_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEvents, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEvents_getTypeCode" "', argument " "1"" of type '" "ListOfEvents const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEvents * >(argp1);
    result = (SBMLTypeCode_t)((ListOfEvents const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEvents_getItemTypeCode) {
  {
    ListOfEvents *arg1 = (ListOfEvents *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfEvents_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEvents, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEvents_getItemTypeCode" "', argument " "1"" of type '" "ListOfEvents const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEvents * >(argp1);
    result = (SBMLTypeCode_t)((ListOfEvents const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEvents_getElementName) {
  {
    ListOfEvents *arg1 = (ListOfEvents *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfEvents_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEvents, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEvents_getElementName" "', argument " "1"" of type '" "ListOfEvents const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEvents * >(argp1);
    result = (std::string *) &((ListOfEvents const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEvents_get__SWIG_0) {
  {
    ListOfEvents *arg1 = (ListOfEvents *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEvents_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEvents, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEvents_get" "', argument " "1"" of type '" "ListOfEvents *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEvents * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfEvents_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Event *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEvents_get__SWIG_1) {
  {
    ListOfEvents *arg1 = (ListOfEvents *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEvents_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEvents, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEvents_get" "', argument " "1"" of type '" "ListOfEvents const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEvents * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfEvents_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Event *)((ListOfEvents const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEvents_get__SWIG_2) {
  {
    ListOfEvents *arg1 = (ListOfEvents *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEvents_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEvents, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEvents_get" "', argument " "1"" of type '" "ListOfEvents *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEvents * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfEvents_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfEvents_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Event *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEvents_get__SWIG_3) {
  {
    ListOfEvents *arg1 = (ListOfEvents *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEvents_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEvents, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEvents_get" "', argument " "1"" of type '" "ListOfEvents const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEvents * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfEvents_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfEvents_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Event *)((ListOfEvents const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEvents_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEvents, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEvents, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEvents, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEvents, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEvents_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEvents_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEvents_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEvents_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfEvents_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfEvents_remove__SWIG_0) {
  {
    ListOfEvents *arg1 = (ListOfEvents *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEvents_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEvents, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEvents_remove" "', argument " "1"" of type '" "ListOfEvents *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEvents * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfEvents_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Event *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEvents_remove__SWIG_1) {
  {
    ListOfEvents *arg1 = (ListOfEvents *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    Event *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEvents_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEvents, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEvents_remove" "', argument " "1"" of type '" "ListOfEvents *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEvents * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfEvents_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfEvents_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (Event *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Event, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEvents_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEvents, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEvents, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEvents_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEvents_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfEvents_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfEvents) {
  {
    int argvi = 0;
    ListOfEvents *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfEvents();");
    }
    result = (ListOfEvents *)new ListOfEvents();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfEvents, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfEvents) {
  {
    ListOfEvents *arg1 = (ListOfEvents *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfEvents(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEvents, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfEvents" "', argument " "1"" of type '" "ListOfEvents *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEvents * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_EventAssignment__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_EventAssignment(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_EventAssignment" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_EventAssignment" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (EventAssignment *)new EventAssignment(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_EventAssignment__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_EventAssignment(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_EventAssignment" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (EventAssignment *)new EventAssignment(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_EventAssignment) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_EventAssignment(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_EventAssignment" "', argument " "1"" of type '" "EventAssignment *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_EventAssignment__SWIG_2) {
  {
    EventAssignment *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_EventAssignment(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_EventAssignment,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_EventAssignment" "', argument " "1"" of type '" "EventAssignment const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_EventAssignment" "', argument " "1"" of type '" "EventAssignment const &""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    {
      try {
        result = (EventAssignment *)new EventAssignment((EventAssignment const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_EventAssignment) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_EventAssignment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_EventAssignment__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_EventAssignment__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_EventAssignment__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_EventAssignment'");
  XSRETURN(0);
}


XS(_wrap_EventAssignment_clone) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_clone" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (EventAssignment *)((EventAssignment const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_getVariable) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_getVariable(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_getVariable" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (std::string *) &((EventAssignment const *)arg1)->getVariable();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_getMath) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_getMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_getMath" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (ASTNode *)((EventAssignment const *)arg1)->getMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_isSetVariable) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_isSetVariable(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_isSetVariable" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (bool)((EventAssignment const *)arg1)->isSetVariable();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_isSetMath) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_isSetMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_isSetMath" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (bool)((EventAssignment const *)arg1)->isSetMath();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_setVariable) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: EventAssignment_setVariable(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_setVariable" "', argument " "1"" of type '" "EventAssignment *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "EventAssignment_setVariable" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "EventAssignment_setVariable" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setVariable((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_setMath) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: EventAssignment_setMath(self,math);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_setMath" "', argument " "1"" of type '" "EventAssignment *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "EventAssignment_setMath" "', argument " "2"" of type '" "ASTNode const *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->setMath((ASTNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_getDerivedUnitDefinition__SWIG_0) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_getDerivedUnitDefinition" "', argument " "1"" of type '" "EventAssignment *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (UnitDefinition *)(arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_getDerivedUnitDefinition__SWIG_1) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_getDerivedUnitDefinition" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (UnitDefinition *)((EventAssignment const *)arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_getDerivedUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_EventAssignment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_EventAssignment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_EventAssignment_getDerivedUnitDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_EventAssignment_getDerivedUnitDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'EventAssignment_getDerivedUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_EventAssignment_containsUndeclaredUnits__SWIG_0) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_containsUndeclaredUnits" "', argument " "1"" of type '" "EventAssignment *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (bool)(arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_containsUndeclaredUnits__SWIG_1) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_containsUndeclaredUnits" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (bool)((EventAssignment const *)arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_containsUndeclaredUnits) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_EventAssignment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_EventAssignment, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_EventAssignment_containsUndeclaredUnits__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_EventAssignment_containsUndeclaredUnits__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'EventAssignment_containsUndeclaredUnits'");
  XSRETURN(0);
}


XS(_wrap_EventAssignment_getTypeCode) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_getTypeCode" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (SBMLTypeCode_t)((EventAssignment const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_getElementName) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_getElementName" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (std::string *) &((EventAssignment const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_hasRequiredAttributes) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_hasRequiredAttributes" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (bool)((EventAssignment const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_hasRequiredElements) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_hasRequiredElements" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = (bool)((EventAssignment const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_EventAssignment_getId) {
  {
    EventAssignment *arg1 = (EventAssignment *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: EventAssignment_getId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_EventAssignment, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "EventAssignment_getId" "', argument " "1"" of type '" "EventAssignment const *""'"); 
    }
    arg1 = reinterpret_cast< EventAssignment * >(argp1);
    result = ((EventAssignment const *)arg1)->getId();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEventAssignments_clone) {
  {
    ListOfEventAssignments *arg1 = (ListOfEventAssignments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListOfEventAssignments *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfEventAssignments_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEventAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEventAssignments_clone" "', argument " "1"" of type '" "ListOfEventAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEventAssignments * >(argp1);
    result = (ListOfEventAssignments *)((ListOfEventAssignments const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfEventAssignments, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEventAssignments_getTypeCode) {
  {
    ListOfEventAssignments *arg1 = (ListOfEventAssignments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfEventAssignments_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEventAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEventAssignments_getTypeCode" "', argument " "1"" of type '" "ListOfEventAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEventAssignments * >(argp1);
    result = (SBMLTypeCode_t)((ListOfEventAssignments const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEventAssignments_getItemTypeCode) {
  {
    ListOfEventAssignments *arg1 = (ListOfEventAssignments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfEventAssignments_getItemTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEventAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEventAssignments_getItemTypeCode" "', argument " "1"" of type '" "ListOfEventAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEventAssignments * >(argp1);
    result = (SBMLTypeCode_t)((ListOfEventAssignments const *)arg1)->getItemTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEventAssignments_getElementName) {
  {
    ListOfEventAssignments *arg1 = (ListOfEventAssignments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ListOfEventAssignments_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEventAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEventAssignments_getElementName" "', argument " "1"" of type '" "ListOfEventAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEventAssignments * >(argp1);
    result = (std::string *) &((ListOfEventAssignments const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEventAssignments_get__SWIG_0) {
  {
    ListOfEventAssignments *arg1 = (ListOfEventAssignments *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEventAssignments_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEventAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEventAssignments_get" "', argument " "1"" of type '" "ListOfEventAssignments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEventAssignments * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfEventAssignments_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (EventAssignment *)(arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEventAssignments_get__SWIG_1) {
  {
    ListOfEventAssignments *arg1 = (ListOfEventAssignments *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEventAssignments_get(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEventAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEventAssignments_get" "', argument " "1"" of type '" "ListOfEventAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEventAssignments * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfEventAssignments_get" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (EventAssignment *)((ListOfEventAssignments const *)arg1)->get(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEventAssignments_get__SWIG_2) {
  {
    ListOfEventAssignments *arg1 = (ListOfEventAssignments *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEventAssignments_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEventAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEventAssignments_get" "', argument " "1"" of type '" "ListOfEventAssignments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEventAssignments * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfEventAssignments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfEventAssignments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (EventAssignment *)(arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEventAssignments_get__SWIG_3) {
  {
    ListOfEventAssignments *arg1 = (ListOfEventAssignments *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEventAssignments_get(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEventAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEventAssignments_get" "', argument " "1"" of type '" "ListOfEventAssignments const *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEventAssignments * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfEventAssignments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfEventAssignments_get" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (EventAssignment *)((ListOfEventAssignments const *)arg1)->get((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEventAssignments_get) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEventAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEventAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEventAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEventAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEventAssignments_get__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEventAssignments_get__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEventAssignments_get__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEventAssignments_get__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfEventAssignments_get'");
  XSRETURN(0);
}


XS(_wrap_ListOfEventAssignments_remove__SWIG_0) {
  {
    ListOfEventAssignments *arg1 = (ListOfEventAssignments *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEventAssignments_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEventAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEventAssignments_remove" "', argument " "1"" of type '" "ListOfEventAssignments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEventAssignments * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ListOfEventAssignments_remove" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (EventAssignment *)(arg1)->remove(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEventAssignments_remove__SWIG_1) {
  {
    ListOfEventAssignments *arg1 = (ListOfEventAssignments *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    EventAssignment *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ListOfEventAssignments_remove(self,sid);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEventAssignments, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ListOfEventAssignments_remove" "', argument " "1"" of type '" "ListOfEventAssignments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEventAssignments * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ListOfEventAssignments_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ListOfEventAssignments_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (EventAssignment *)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_EventAssignment, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ListOfEventAssignments_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEventAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ListOfEventAssignments, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEventAssignments_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ListOfEventAssignments_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ListOfEventAssignments_remove'");
  XSRETURN(0);
}


XS(_wrap_new_ListOfEventAssignments) {
  {
    int argvi = 0;
    ListOfEventAssignments *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ListOfEventAssignments();");
    }
    result = (ListOfEventAssignments *)new ListOfEventAssignments();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListOfEventAssignments, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ListOfEventAssignments) {
  {
    ListOfEventAssignments *arg1 = (ListOfEventAssignments *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ListOfEventAssignments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ListOfEventAssignments, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ListOfEventAssignments" "', argument " "1"" of type '" "ListOfEventAssignments *""'"); 
    }
    arg1 = reinterpret_cast< ListOfEventAssignments * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Trigger__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Trigger *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Trigger(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Trigger" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Trigger" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (Trigger *)new Trigger(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Trigger, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Trigger__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Trigger *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Trigger(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Trigger" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (Trigger *)new Trigger(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Trigger, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Trigger) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Trigger(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Trigger" "', argument " "1"" of type '" "Trigger *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Trigger__SWIG_2) {
  {
    Trigger *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Trigger *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Trigger(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Trigger,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Trigger" "', argument " "1"" of type '" "Trigger const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Trigger" "', argument " "1"" of type '" "Trigger const &""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    {
      try {
        result = (Trigger *)new Trigger((Trigger const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Trigger, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Trigger) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Trigger, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Trigger__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Trigger__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Trigger__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Trigger'");
  XSRETURN(0);
}


XS(_wrap_Trigger_clone) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Trigger *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Trigger_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_clone" "', argument " "1"" of type '" "Trigger const *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    result = (Trigger *)((Trigger const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Trigger, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_getMath) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Trigger_getMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_getMath" "', argument " "1"" of type '" "Trigger const *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    result = (ASTNode *)((Trigger const *)arg1)->getMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_getInitialValue) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Trigger_getInitialValue(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_getInitialValue" "', argument " "1"" of type '" "Trigger const *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    result = (bool)((Trigger const *)arg1)->getInitialValue();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_getPersistent) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Trigger_getPersistent(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_getPersistent" "', argument " "1"" of type '" "Trigger const *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    result = (bool)((Trigger const *)arg1)->getPersistent();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_isSetMath) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Trigger_isSetMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_isSetMath" "', argument " "1"" of type '" "Trigger const *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    result = (bool)((Trigger const *)arg1)->isSetMath();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_isSetInitialValue) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Trigger_isSetInitialValue(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_isSetInitialValue" "', argument " "1"" of type '" "Trigger const *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    result = (bool)((Trigger const *)arg1)->isSetInitialValue();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_isSetPersistent) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Trigger_isSetPersistent(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_isSetPersistent" "', argument " "1"" of type '" "Trigger const *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    result = (bool)((Trigger const *)arg1)->isSetPersistent();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_setMath) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Trigger_setMath(self,math);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_setMath" "', argument " "1"" of type '" "Trigger *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Trigger_setMath" "', argument " "2"" of type '" "ASTNode const *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->setMath((ASTNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_setInitialValue) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Trigger_setInitialValue(self,initialValue);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_setInitialValue" "', argument " "1"" of type '" "Trigger *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Trigger_setInitialValue" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (int)(arg1)->setInitialValue(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_setPersistent) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Trigger_setPersistent(self,persistent);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_setPersistent" "', argument " "1"" of type '" "Trigger *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Trigger_setPersistent" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    result = (int)(arg1)->setPersistent(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_getTypeCode) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Trigger_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_getTypeCode" "', argument " "1"" of type '" "Trigger const *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    result = (SBMLTypeCode_t)((Trigger const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_getElementName) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Trigger_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_getElementName" "', argument " "1"" of type '" "Trigger const *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    result = (std::string *) &((Trigger const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_hasRequiredElements) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Trigger_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_hasRequiredElements" "', argument " "1"" of type '" "Trigger const *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    result = (bool)((Trigger const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Trigger_hasRequiredAttributes) {
  {
    Trigger *arg1 = (Trigger *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Trigger_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Trigger, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Trigger_hasRequiredAttributes" "', argument " "1"" of type '" "Trigger const *""'"); 
    }
    arg1 = reinterpret_cast< Trigger * >(argp1);
    result = (bool)((Trigger const *)arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Delay__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Delay *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Delay(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Delay" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Delay" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (Delay *)new Delay(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Delay, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Delay__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Delay *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Delay(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Delay" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (Delay *)new Delay(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Delay, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Delay) {
  {
    Delay *arg1 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Delay(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Delay" "', argument " "1"" of type '" "Delay *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Delay__SWIG_2) {
  {
    Delay *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Delay *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Delay(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Delay,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Delay" "', argument " "1"" of type '" "Delay const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Delay" "', argument " "1"" of type '" "Delay const &""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    {
      try {
        result = (Delay *)new Delay((Delay const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Delay, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Delay) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Delay, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Delay__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Delay__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Delay__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Delay'");
  XSRETURN(0);
}


XS(_wrap_Delay_clone) {
  {
    Delay *arg1 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Delay *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Delay_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Delay_clone" "', argument " "1"" of type '" "Delay const *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    result = (Delay *)((Delay const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Delay, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Delay_getMath) {
  {
    Delay *arg1 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Delay_getMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Delay_getMath" "', argument " "1"" of type '" "Delay const *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    result = (ASTNode *)((Delay const *)arg1)->getMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Delay_isSetMath) {
  {
    Delay *arg1 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Delay_isSetMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Delay_isSetMath" "', argument " "1"" of type '" "Delay const *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    result = (bool)((Delay const *)arg1)->isSetMath();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Delay_setMath) {
  {
    Delay *arg1 = (Delay *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Delay_setMath(self,math);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Delay_setMath" "', argument " "1"" of type '" "Delay *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Delay_setMath" "', argument " "2"" of type '" "ASTNode const *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->setMath((ASTNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Delay_getDerivedUnitDefinition__SWIG_0) {
  {
    Delay *arg1 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Delay_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Delay_getDerivedUnitDefinition" "', argument " "1"" of type '" "Delay *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    result = (UnitDefinition *)(arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Delay_getDerivedUnitDefinition__SWIG_1) {
  {
    Delay *arg1 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Delay_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Delay_getDerivedUnitDefinition" "', argument " "1"" of type '" "Delay const *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    result = (UnitDefinition *)((Delay const *)arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Delay_getDerivedUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Delay, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Delay, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Delay_getDerivedUnitDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Delay_getDerivedUnitDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Delay_getDerivedUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_Delay_containsUndeclaredUnits__SWIG_0) {
  {
    Delay *arg1 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Delay_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Delay_containsUndeclaredUnits" "', argument " "1"" of type '" "Delay *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    result = (bool)(arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Delay_containsUndeclaredUnits__SWIG_1) {
  {
    Delay *arg1 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Delay_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Delay_containsUndeclaredUnits" "', argument " "1"" of type '" "Delay const *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    result = (bool)((Delay const *)arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Delay_containsUndeclaredUnits) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Delay, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Delay, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Delay_containsUndeclaredUnits__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_Delay_containsUndeclaredUnits__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'Delay_containsUndeclaredUnits'");
  XSRETURN(0);
}


XS(_wrap_Delay_getTypeCode) {
  {
    Delay *arg1 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Delay_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Delay_getTypeCode" "', argument " "1"" of type '" "Delay const *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    result = (SBMLTypeCode_t)((Delay const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Delay_getElementName) {
  {
    Delay *arg1 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Delay_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Delay_getElementName" "', argument " "1"" of type '" "Delay const *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    result = (std::string *) &((Delay const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Delay_hasRequiredElements) {
  {
    Delay *arg1 = (Delay *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Delay_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Delay, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Delay_hasRequiredElements" "', argument " "1"" of type '" "Delay const *""'"); 
    }
    arg1 = reinterpret_cast< Delay * >(argp1);
    result = (bool)((Delay const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Priority__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Priority *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Priority(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Priority" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Priority" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (Priority *)new Priority(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Priority, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Priority__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Priority *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Priority(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Priority" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (Priority *)new Priority(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Priority, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Priority) {
  {
    Priority *arg1 = (Priority *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Priority(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Priority, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Priority" "', argument " "1"" of type '" "Priority *""'"); 
    }
    arg1 = reinterpret_cast< Priority * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Priority__SWIG_2) {
  {
    Priority *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Priority *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Priority(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Priority,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Priority" "', argument " "1"" of type '" "Priority const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Priority" "', argument " "1"" of type '" "Priority const &""'"); 
    }
    arg1 = reinterpret_cast< Priority * >(argp1);
    {
      try {
        result = (Priority *)new Priority((Priority const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Priority, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Priority) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Priority, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Priority__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Priority__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Priority__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Priority'");
  XSRETURN(0);
}


XS(_wrap_Priority_clone) {
  {
    Priority *arg1 = (Priority *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Priority *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Priority_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Priority, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Priority_clone" "', argument " "1"" of type '" "Priority const *""'"); 
    }
    arg1 = reinterpret_cast< Priority * >(argp1);
    result = (Priority *)((Priority const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Priority, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Priority_getMath) {
  {
    Priority *arg1 = (Priority *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Priority_getMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Priority, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Priority_getMath" "', argument " "1"" of type '" "Priority const *""'"); 
    }
    arg1 = reinterpret_cast< Priority * >(argp1);
    result = (ASTNode *)((Priority const *)arg1)->getMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Priority_isSetMath) {
  {
    Priority *arg1 = (Priority *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Priority_isSetMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Priority, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Priority_isSetMath" "', argument " "1"" of type '" "Priority const *""'"); 
    }
    arg1 = reinterpret_cast< Priority * >(argp1);
    result = (bool)((Priority const *)arg1)->isSetMath();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Priority_setMath) {
  {
    Priority *arg1 = (Priority *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Priority_setMath(self,math);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Priority, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Priority_setMath" "', argument " "1"" of type '" "Priority *""'"); 
    }
    arg1 = reinterpret_cast< Priority * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Priority_setMath" "', argument " "2"" of type '" "ASTNode const *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->setMath((ASTNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Priority_getTypeCode) {
  {
    Priority *arg1 = (Priority *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Priority_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Priority, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Priority_getTypeCode" "', argument " "1"" of type '" "Priority const *""'"); 
    }
    arg1 = reinterpret_cast< Priority * >(argp1);
    result = (SBMLTypeCode_t)((Priority const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Priority_getElementName) {
  {
    Priority *arg1 = (Priority *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Priority_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Priority, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Priority_getElementName" "', argument " "1"" of type '" "Priority const *""'"); 
    }
    arg1 = reinterpret_cast< Priority * >(argp1);
    result = (std::string *) &((Priority const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Priority_hasRequiredElements) {
  {
    Priority *arg1 = (Priority *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Priority_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Priority, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Priority_hasRequiredElements" "', argument " "1"" of type '" "Priority const *""'"); 
    }
    arg1 = reinterpret_cast< Priority * >(argp1);
    result = (bool)((Priority const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isQuantitativeParameter) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isQuantitativeParameter(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isQuantitativeParameter" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isQuantitativeParameter(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isParticipantRole) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isParticipantRole(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isParticipantRole" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isParticipantRole(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isModellingFramework) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isModellingFramework(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isModellingFramework" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isModellingFramework(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isMathematicalExpression) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isMathematicalExpression(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isMathematicalExpression" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isMathematicalExpression(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isKineticConstant) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isKineticConstant(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isKineticConstant" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isKineticConstant(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isReactant) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isReactant(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isReactant" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isReactant(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isProduct) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isProduct(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isProduct" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isProduct(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isModifier) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isModifier(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isModifier" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isModifier(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isRateLaw) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isRateLaw(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isRateLaw" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isRateLaw(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isEvent) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isEvent(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isEvent" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isEvent(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isPhysicalParticipant) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isPhysicalParticipant(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isPhysicalParticipant" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isPhysicalParticipant(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isParticipant) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isParticipant(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isParticipant" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isParticipant(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isInteraction) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isInteraction(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isInteraction" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isInteraction(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isEntity) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isEntity(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isEntity" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isEntity(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isFunctionalEntity) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isFunctionalEntity(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isFunctionalEntity" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isFunctionalEntity(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isMaterialEntity) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isMaterialEntity(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isMaterialEntity" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isMaterialEntity(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isConservationLaw) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isConservationLaw(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isConservationLaw" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isConservationLaw(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isSteadyStateExpression) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isSteadyStateExpression(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isSteadyStateExpression" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isSteadyStateExpression(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isFunctionalCompartment) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isFunctionalCompartment(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isFunctionalCompartment" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isFunctionalCompartment(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isContinuousFramework) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isContinuousFramework(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isContinuousFramework" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isContinuousFramework(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isDiscreteFramework) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isDiscreteFramework(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isDiscreteFramework" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isDiscreteFramework(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isLogicalFramework) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isLogicalFramework(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isLogicalFramework" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isLogicalFramework(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_isObselete) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_isObselete(term);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_isObselete" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (bool)SBO::isObselete(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_intToString) {
  {
    int arg1 ;
    int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_intToString(sboTerm);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_intToString" "', argument " "1"" of type '" "int""'");
    } 
    arg1 = static_cast< int >(val1);
    result = SBO::intToString(arg1);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_stringToInt) {
  {
    std::string *arg1 = 0 ;
    int res1 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_stringToInt(sboTerm);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBO_stringToInt" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBO_stringToInt" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    result = (int)SBO::stringToInt((std::string const &)*arg1);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_checkTerm__SWIG_0) {
  {
    std::string *arg1 = 0 ;
    int res1 = SWIG_OLDOBJ ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_checkTerm(sboTerm);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBO_checkTerm" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SBO_checkTerm" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    result = (bool)SBO::checkTerm((std::string const &)*arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    if (SWIG_IsNewObj(res1)) delete arg1;
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_checkTerm__SWIG_1) {
  {
    int arg1 ;
    int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBO_checkTerm(sboTerm);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBO_checkTerm" "', argument " "1"" of type '" "int""'");
    } 
    arg1 = static_cast< int >(val1);
    result = (bool)SBO::checkTerm(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBO_checkTerm) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBO_checkTerm__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBO_checkTerm__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'SBO_checkTerm'");
  XSRETURN(0);
}


XS(_wrap_new_SBO) {
  {
    int argvi = 0;
    SBO *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_SBO();");
    }
    result = (SBO *)new SBO();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBO, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SBO) {
  {
    SBO *arg1 = (SBO *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SBO(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBO, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SBO" "', argument " "1"" of type '" "SBO *""'"); 
    }
    arg1 = reinterpret_cast< SBO * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SyntaxChecker_isValidSBMLSId) {
  {
    std::string arg1 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SyntaxChecker_isValidSBMLSId(sid);");
    }
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "SyntaxChecker_isValidSBMLSId" "', argument " "1"" of type '" "std::string""'"); 
      }
      arg1 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (bool)SyntaxChecker::isValidSBMLSId(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SyntaxChecker_isValidXMLID) {
  {
    std::string arg1 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SyntaxChecker_isValidXMLID(id);");
    }
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "SyntaxChecker_isValidXMLID" "', argument " "1"" of type '" "std::string""'"); 
      }
      arg1 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (bool)SyntaxChecker::isValidXMLID(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SyntaxChecker_isValidUnitSId) {
  {
    std::string arg1 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SyntaxChecker_isValidUnitSId(units);");
    }
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "SyntaxChecker_isValidUnitSId" "', argument " "1"" of type '" "std::string""'"); 
      }
      arg1 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (bool)SyntaxChecker::isValidUnitSId(arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SyntaxChecker_hasExpectedXHTMLSyntax__SWIG_0) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    SBMLNamespaces *arg2 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SyntaxChecker_hasExpectedXHTMLSyntax(xhtml,sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SyntaxChecker_hasExpectedXHTMLSyntax" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SyntaxChecker_hasExpectedXHTMLSyntax" "', argument " "2"" of type '" "SBMLNamespaces *""'"); 
    }
    arg2 = reinterpret_cast< SBMLNamespaces * >(argp2);
    result = (bool)SyntaxChecker::hasExpectedXHTMLSyntax((XMLNode const *)arg1,arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SyntaxChecker_hasExpectedXHTMLSyntax__SWIG_1) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SyntaxChecker_hasExpectedXHTMLSyntax(xhtml);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SyntaxChecker_hasExpectedXHTMLSyntax" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    result = (bool)SyntaxChecker::hasExpectedXHTMLSyntax((XMLNode const *)arg1);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SyntaxChecker_hasExpectedXHTMLSyntax) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SyntaxChecker_hasExpectedXHTMLSyntax__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SyntaxChecker_hasExpectedXHTMLSyntax__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'SyntaxChecker_hasExpectedXHTMLSyntax'");
  XSRETURN(0);
}


XS(_wrap_new_SyntaxChecker) {
  {
    int argvi = 0;
    SyntaxChecker *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_SyntaxChecker();");
    }
    result = (SyntaxChecker *)new SyntaxChecker();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SyntaxChecker, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SyntaxChecker) {
  {
    SyntaxChecker *arg1 = (SyntaxChecker *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SyntaxChecker(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SyntaxChecker, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SyntaxChecker" "', argument " "1"" of type '" "SyntaxChecker *""'"); 
    }
    arg1 = reinterpret_cast< SyntaxChecker * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_StoichiometryMath__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    StoichiometryMath *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_StoichiometryMath(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_StoichiometryMath" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_StoichiometryMath" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (StoichiometryMath *)new StoichiometryMath(arg1,arg2);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_StoichiometryMath, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_StoichiometryMath__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    StoichiometryMath *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_StoichiometryMath(sbmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_StoichiometryMath" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    {
      try {
        result = (StoichiometryMath *)new StoichiometryMath(arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_StoichiometryMath, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_StoichiometryMath) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_StoichiometryMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_StoichiometryMath" "', argument " "1"" of type '" "StoichiometryMath *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_StoichiometryMath__SWIG_2) {
  {
    StoichiometryMath *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    StoichiometryMath *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_StoichiometryMath(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_StoichiometryMath,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_StoichiometryMath" "', argument " "1"" of type '" "StoichiometryMath const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_StoichiometryMath" "', argument " "1"" of type '" "StoichiometryMath const &""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    {
      try {
        result = (StoichiometryMath *)new StoichiometryMath((StoichiometryMath const &)*arg1);
      }
      catch (SBMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_StoichiometryMath, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_StoichiometryMath) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_StoichiometryMath, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_StoichiometryMath__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_StoichiometryMath__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_StoichiometryMath__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_StoichiometryMath'");
  XSRETURN(0);
}


XS(_wrap_StoichiometryMath_clone) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    StoichiometryMath *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: StoichiometryMath_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StoichiometryMath_clone" "', argument " "1"" of type '" "StoichiometryMath const *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    result = (StoichiometryMath *)((StoichiometryMath const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_StoichiometryMath, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_StoichiometryMath_getMath) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: StoichiometryMath_getMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StoichiometryMath_getMath" "', argument " "1"" of type '" "StoichiometryMath const *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    result = (ASTNode *)((StoichiometryMath const *)arg1)->getMath();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_StoichiometryMath_isSetMath) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: StoichiometryMath_isSetMath(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StoichiometryMath_isSetMath" "', argument " "1"" of type '" "StoichiometryMath const *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    result = (bool)((StoichiometryMath const *)arg1)->isSetMath();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_StoichiometryMath_setMath) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: StoichiometryMath_setMath(self,math);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StoichiometryMath_setMath" "', argument " "1"" of type '" "StoichiometryMath *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "StoichiometryMath_setMath" "', argument " "2"" of type '" "ASTNode const *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->setMath((ASTNode const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_StoichiometryMath_getDerivedUnitDefinition__SWIG_0) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: StoichiometryMath_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StoichiometryMath_getDerivedUnitDefinition" "', argument " "1"" of type '" "StoichiometryMath *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    result = (UnitDefinition *)(arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_StoichiometryMath_getDerivedUnitDefinition__SWIG_1) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    UnitDefinition *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: StoichiometryMath_getDerivedUnitDefinition(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StoichiometryMath_getDerivedUnitDefinition" "', argument " "1"" of type '" "StoichiometryMath const *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    result = (UnitDefinition *)((StoichiometryMath const *)arg1)->getDerivedUnitDefinition();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_UnitDefinition, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_StoichiometryMath_getDerivedUnitDefinition) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_StoichiometryMath, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_StoichiometryMath, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_StoichiometryMath_getDerivedUnitDefinition__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_StoichiometryMath_getDerivedUnitDefinition__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'StoichiometryMath_getDerivedUnitDefinition'");
  XSRETURN(0);
}


XS(_wrap_StoichiometryMath_containsUndeclaredUnits__SWIG_0) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: StoichiometryMath_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StoichiometryMath_containsUndeclaredUnits" "', argument " "1"" of type '" "StoichiometryMath *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    result = (bool)(arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_StoichiometryMath_containsUndeclaredUnits__SWIG_1) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: StoichiometryMath_containsUndeclaredUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StoichiometryMath_containsUndeclaredUnits" "', argument " "1"" of type '" "StoichiometryMath const *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    result = (bool)((StoichiometryMath const *)arg1)->containsUndeclaredUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_StoichiometryMath_containsUndeclaredUnits) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_StoichiometryMath, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_StoichiometryMath, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_StoichiometryMath_containsUndeclaredUnits__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_StoichiometryMath_containsUndeclaredUnits__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'StoichiometryMath_containsUndeclaredUnits'");
  XSRETURN(0);
}


XS(_wrap_StoichiometryMath_getTypeCode) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLTypeCode_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: StoichiometryMath_getTypeCode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StoichiometryMath_getTypeCode" "', argument " "1"" of type '" "StoichiometryMath const *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    result = (SBMLTypeCode_t)((StoichiometryMath const *)arg1)->getTypeCode();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_StoichiometryMath_getElementName) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: StoichiometryMath_getElementName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StoichiometryMath_getElementName" "', argument " "1"" of type '" "StoichiometryMath const *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    result = (std::string *) &((StoichiometryMath const *)arg1)->getElementName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_StoichiometryMath_hasRequiredElements) {
  {
    StoichiometryMath *arg1 = (StoichiometryMath *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: StoichiometryMath_hasRequiredElements(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_StoichiometryMath, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StoichiometryMath_hasRequiredElements" "', argument " "1"" of type '" "StoichiometryMath const *""'"); 
    }
    arg1 = reinterpret_cast< StoichiometryMath * >(argp1);
    result = (bool)((StoichiometryMath const *)arg1)->hasRequiredElements();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLNamespaces__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SBMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_SBMLNamespaces(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLNamespaces" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_SBMLNamespaces" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SBMLNamespaces *)new SBMLNamespaces(arg1,arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLNamespaces, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLNamespaces__SWIG_1) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    SBMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SBMLNamespaces(level);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLNamespaces" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (SBMLNamespaces *)new SBMLNamespaces(arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLNamespaces, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLNamespaces__SWIG_2) {
  {
    int argvi = 0;
    SBMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_SBMLNamespaces();");
    }
    result = (SBMLNamespaces *)new SBMLNamespaces();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLNamespaces, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SBMLNamespaces) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SBMLNamespaces(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SBMLNamespaces" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLNamespaces__SWIG_3) {
  {
    SBMLNamespaces *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SBMLNamespaces(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_SBMLNamespaces,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_SBMLNamespaces" "', argument " "1"" of type '" "SBMLNamespaces const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_SBMLNamespaces" "', argument " "1"" of type '" "SBMLNamespaces const &""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    result = (SBMLNamespaces *)new SBMLNamespaces((SBMLNamespaces const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLNamespaces, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLNamespaces) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLNamespaces__SWIG_2); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLNamespaces__SWIG_3); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLNamespaces__SWIG_1); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLNamespaces__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_SBMLNamespaces'");
  XSRETURN(0);
}


XS(_wrap_SBMLNamespaces_clone) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLNamespaces_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespaces_clone" "', argument " "1"" of type '" "SBMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    result = (SBMLNamespaces *)((SBMLNamespaces const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLNamespaces, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespaces_getSBMLNamespaceURI) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLNamespaces_getSBMLNamespaceURI(level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "SBMLNamespaces_getSBMLNamespaceURI" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBMLNamespaces_getSBMLNamespaceURI" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = SBMLNamespaces::getSBMLNamespaceURI(arg1,arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespaces_getSupportedNamespaces) {
  {
    int argvi = 0;
    List *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: SBMLNamespaces_getSupportedNamespaces();");
    }
    result = (List *)SBMLNamespaces::getSupportedNamespaces();
    {
      ListWrapper<SBMLNamespaces> *listw = (result != 0) ? new ListWrapper<SBMLNamespaces>(result) : 0;
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(listw), 
        
        SWIGTYPE_p_ListWrapperT_SBMLNamespaces_t, 
        
        
        
        SWIG_OWNER | 0);
      argvi++;
    }
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespaces_getLevel__SWIG_0) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLNamespaces_getLevel(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespaces_getLevel" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    result = (unsigned int)(arg1)->getLevel();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespaces_getLevel__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLNamespaces_getLevel(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespaces_getLevel" "', argument " "1"" of type '" "SBMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    result = (unsigned int)((SBMLNamespaces const *)arg1)->getLevel();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespaces_getLevel) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLNamespaces_getLevel__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLNamespaces_getLevel__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'SBMLNamespaces_getLevel'");
  XSRETURN(0);
}


XS(_wrap_SBMLNamespaces_getVersion__SWIG_0) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLNamespaces_getVersion(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespaces_getVersion" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    result = (unsigned int)(arg1)->getVersion();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespaces_getVersion__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLNamespaces_getVersion(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespaces_getVersion" "', argument " "1"" of type '" "SBMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    result = (unsigned int)((SBMLNamespaces const *)arg1)->getVersion();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespaces_getVersion) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLNamespaces_getVersion__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLNamespaces_getVersion__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'SBMLNamespaces_getVersion'");
  XSRETURN(0);
}


XS(_wrap_SBMLNamespaces_getNamespaces__SWIG_0) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLNamespaces_getNamespaces(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespaces_getNamespaces" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    result = (XMLNamespaces *)(arg1)->getNamespaces();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNamespaces, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespaces_getNamespaces__SWIG_1) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: SBMLNamespaces_getNamespaces(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespaces_getNamespaces" "', argument " "1"" of type '" "SBMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    result = (XMLNamespaces *)((SBMLNamespaces const *)arg1)->getNamespaces();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNamespaces, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLNamespaces_getNamespaces) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLNamespaces_getNamespaces__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_SBMLNamespaces_getNamespaces__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'SBMLNamespaces_getNamespaces'");
  XSRETURN(0);
}


XS(_wrap_SBMLNamespaces_addNamespaces) {
  {
    SBMLNamespaces *arg1 = (SBMLNamespaces *) 0 ;
    XMLNamespaces *arg2 = (XMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLNamespaces_addNamespaces(self,xmlns);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLNamespaces_addNamespaces" "', argument " "1"" of type '" "SBMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< SBMLNamespaces * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SBMLNamespaces_addNamespaces" "', argument " "2"" of type '" "XMLNamespaces *""'"); 
    }
    arg2 = reinterpret_cast< XMLNamespaces * >(argp2);
    (arg1)->addNamespaces(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLTransforms) {
  {
    int argvi = 0;
    SBMLTransforms *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_SBMLTransforms();");
    }
    result = (SBMLTransforms *)new SBMLTransforms();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLTransforms, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SBMLTransforms) {
  {
    SBMLTransforms *arg1 = (SBMLTransforms *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SBMLTransforms(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLTransforms, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SBMLTransforms" "', argument " "1"" of type '" "SBMLTransforms *""'"); 
    }
    arg1 = reinterpret_cast< SBMLTransforms * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_readMathMLFromString) {
  {
    char *arg1 = (char *) 0 ;
    int res1 ;
    char *buf1 = 0 ;
    int alloc1 = 0 ;
    int argvi = 0;
    ASTNode_t *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: readMathMLFromString(xml);");
    }
    res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1);
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "readMathMLFromString" "', argument " "1"" of type '" "char const *""'");
    }
    arg1 = reinterpret_cast< char * >(buf1);
    result = (ASTNode_t *)readMathMLFromString((char const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    XSRETURN(argvi);
  fail:
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    SWIG_croak_null();
  }
}


XS(_wrap_writeMathMLToString) {
  {
    ASTNode_t *arg1 = (ASTNode_t *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    char *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: writeMathMLToString(node);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "writeMathMLToString" "', argument " "1"" of type '" "ASTNode_t const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode_t * >(argp1);
    result = (char *)writeMathMLToString((ASTNode const *)arg1);
    ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
    
    free(result);
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ASTNode__SWIG_0) {
  {
    ASTNodeType_t arg1 ;
    int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_ASTNode(type);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_ASTNode" "', argument " "1"" of type '" "ASTNodeType_t""'");
    } 
    arg1 = static_cast< ASTNodeType_t >(val1);
    result = (ASTNode *)new ASTNode(arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ASTNode__SWIG_1) {
  {
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ASTNode();");
    }
    result = (ASTNode *)new ASTNode();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_ASTNode__SWIG_2) {
  {
    ASTNode *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_ASTNode(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_ASTNode,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_ASTNode" "', argument " "1"" of type '" "ASTNode const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_ASTNode" "', argument " "1"" of type '" "ASTNode const &""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (ASTNode *)new ASTNode((ASTNode const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ASTNode) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ASTNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ASTNode__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ASTNode__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ASTNode__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_ASTNode'");
  XSRETURN(0);
}


XS(_wrap_delete_ASTNode) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ASTNode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ASTNode" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_freeName) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_freeName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_freeName" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (int)(arg1)->freeName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_canonicalize) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_canonicalize(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_canonicalize" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)(arg1)->canonicalize();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_addChild) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_addChild(self,child);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_addChild" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ASTNode_addChild" "', argument " "2"" of type '" "ASTNode *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->addChild(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_prependChild) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_prependChild(self,child);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_prependChild" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ASTNode_prependChild" "', argument " "2"" of type '" "ASTNode *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->prependChild(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_removeChild) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_removeChild(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_removeChild" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNode_removeChild" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->removeChild(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_replaceChild) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    unsigned int arg2 ;
    ASTNode *arg3 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    void *argp3 = 0 ;
    int res3 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: ASTNode_replaceChild(self,n,newChild);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_replaceChild" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNode_replaceChild" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    res3 = SWIG_ConvertPtr(ST(2), &argp3,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "ASTNode_replaceChild" "', argument " "3"" of type '" "ASTNode *""'"); 
    }
    arg3 = reinterpret_cast< ASTNode * >(argp3);
    result = (int)(arg1)->replaceChild(arg2,arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_insertChild) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    unsigned int arg2 ;
    ASTNode *arg3 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    void *argp3 = 0 ;
    int res3 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: ASTNode_insertChild(self,n,newChild);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_insertChild" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNode_insertChild" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    res3 = SWIG_ConvertPtr(ST(2), &argp3,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "ASTNode_insertChild" "', argument " "3"" of type '" "ASTNode *""'"); 
    }
    arg3 = reinterpret_cast< ASTNode * >(argp3);
    result = (int)(arg1)->insertChild(arg2,arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_deepCopy) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_deepCopy(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_deepCopy" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (ASTNode *)((ASTNode const *)arg1)->deepCopy();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getChild) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_getChild(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getChild" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNode_getChild" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (ASTNode *)((ASTNode const *)arg1)->getChild(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getLeftChild) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getLeftChild(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getLeftChild" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (ASTNode *)((ASTNode const *)arg1)->getLeftChild();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getRightChild) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getRightChild(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getRightChild" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (ASTNode *)((ASTNode const *)arg1)->getRightChild();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getNumChildren) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getNumChildren(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getNumChildren" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (unsigned int)((ASTNode const *)arg1)->getNumChildren();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_addSemanticsAnnotation) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    XMLNode *arg2 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_addSemanticsAnnotation(self,sAnnotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_addSemanticsAnnotation" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ASTNode_addSemanticsAnnotation" "', argument " "2"" of type '" "XMLNode *""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (int)(arg1)->addSemanticsAnnotation(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getNumSemanticsAnnotations) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getNumSemanticsAnnotations(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getNumSemanticsAnnotations" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (unsigned int)((ASTNode const *)arg1)->getNumSemanticsAnnotations();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getSemanticsAnnotation) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_getSemanticsAnnotation(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getSemanticsAnnotation" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNode_getSemanticsAnnotation" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (XMLNode *)((ASTNode const *)arg1)->getSemanticsAnnotation(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getCharacter) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    char result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getCharacter(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getCharacter" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (char)((ASTNode const *)arg1)->getCharacter();
    ST(argvi) = SWIG_From_char  SWIG_PERL_CALL_ARGS_1(static_cast< char >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getInteger) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    long result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getInteger(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getInteger" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (long)((ASTNode const *)arg1)->getInteger();
    ST(argvi) = SWIG_From_long  SWIG_PERL_CALL_ARGS_1(static_cast< long >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getName) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    char *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getName" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (char *)((ASTNode const *)arg1)->getName();
    ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getNumerator) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    long result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getNumerator(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getNumerator" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (long)((ASTNode const *)arg1)->getNumerator();
    ST(argvi) = SWIG_From_long  SWIG_PERL_CALL_ARGS_1(static_cast< long >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getDenominator) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    long result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getDenominator(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getDenominator" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (long)((ASTNode const *)arg1)->getDenominator();
    ST(argvi) = SWIG_From_long  SWIG_PERL_CALL_ARGS_1(static_cast< long >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getReal) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getReal(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getReal" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (double)((ASTNode const *)arg1)->getReal();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getMantissa) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    double result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getMantissa(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getMantissa" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (double)((ASTNode const *)arg1)->getMantissa();
    ST(argvi) = SWIG_From_double  SWIG_PERL_CALL_ARGS_1(static_cast< double >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getExponent) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    long result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getExponent(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getExponent" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (long)((ASTNode const *)arg1)->getExponent();
    ST(argvi) = SWIG_From_long  SWIG_PERL_CALL_ARGS_1(static_cast< long >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getPrecedence) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getPrecedence(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getPrecedence" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (int)((ASTNode const *)arg1)->getPrecedence();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getType) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ASTNodeType_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getType" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (ASTNodeType_t)((ASTNode const *)arg1)->getType();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getUnits) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getUnits" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = ((ASTNode const *)arg1)->getUnits();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isBoolean) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isBoolean(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isBoolean" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isBoolean();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isConstant) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isConstant(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isConstant" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isConstant();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isFunction) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isFunction(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isFunction" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isFunction();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isInfinity) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isInfinity(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isInfinity" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isInfinity();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isInteger) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isInteger(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isInteger" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isInteger();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isLambda) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isLambda(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isLambda" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isLambda();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isLog10) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isLog10(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isLog10" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isLog10();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isLogical) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isLogical(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isLogical" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isLogical();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isName) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isName" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isNaN) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isNaN(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isNaN" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isNaN();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isNegInfinity) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isNegInfinity(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isNegInfinity" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isNegInfinity();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isNumber) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isNumber(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isNumber" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isNumber();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isOperator) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isOperator(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isOperator" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isOperator();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isPiecewise) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isPiecewise(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isPiecewise" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isPiecewise();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isRational) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isRational(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isRational" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isRational();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isReal) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isReal(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isReal" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isReal();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isRelational) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isRelational(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isRelational" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isRelational();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isSqrt) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isSqrt(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isSqrt" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isSqrt();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isUMinus) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isUMinus(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isUMinus" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isUMinus();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isUnknown) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isUnknown(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isUnknown" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isUnknown();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isSetUnits) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isSetUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isSetUnits" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isSetUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_hasUnits) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_hasUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_hasUnits" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->hasUnits();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_setCharacter) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    char arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    char val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_setCharacter(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_setCharacter" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    ecode2 = SWIG_AsVal_char SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNode_setCharacter" "', argument " "2"" of type '" "char""'");
    } 
    arg2 = static_cast< char >(val2);
    result = (int)(arg1)->setCharacter(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_setName) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    char *arg2 = (char *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 ;
    char *buf2 = 0 ;
    int alloc2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_setName(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_setName" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ASTNode_setName" "', argument " "2"" of type '" "char const *""'");
    }
    arg2 = reinterpret_cast< char * >(buf2);
    result = (int)(arg1)->setName((char const *)arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
    XSRETURN(argvi);
  fail:
    
    if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_setValue__SWIG_0) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    long arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    long val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_setValue(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_setValue" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    ecode2 = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNode_setValue" "', argument " "2"" of type '" "long""'");
    } 
    arg2 = static_cast< long >(val2);
    result = (int)(arg1)->setValue(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_setValue__SWIG_1) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    long arg2 ;
    long arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    long val2 ;
    int ecode2 = 0 ;
    long val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: ASTNode_setValue(self,numerator,denominator);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_setValue" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    ecode2 = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNode_setValue" "', argument " "2"" of type '" "long""'");
    } 
    arg2 = static_cast< long >(val2);
    ecode3 = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "ASTNode_setValue" "', argument " "3"" of type '" "long""'");
    } 
    arg3 = static_cast< long >(val3);
    result = (int)(arg1)->setValue(arg2,arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_setValue__SWIG_2) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    double arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_setValue(self,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_setValue" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNode_setValue" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    result = (int)(arg1)->setValue(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_setValue__SWIG_3) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    double arg2 ;
    long arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    double val2 ;
    int ecode2 = 0 ;
    long val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: ASTNode_setValue(self,mantissa,exponent);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_setValue" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    ecode2 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNode_setValue" "', argument " "2"" of type '" "double""'");
    } 
    arg2 = static_cast< double >(val2);
    ecode3 = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "ASTNode_setValue" "', argument " "3"" of type '" "long""'");
    } 
    arg3 = static_cast< long >(val3);
    result = (int)(arg1)->setValue(arg2,arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_setValue) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ASTNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ASTNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ASTNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ASTNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ASTNode_setValue__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ASTNode_setValue__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ASTNode_setValue__SWIG_1); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ASTNode_setValue__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'ASTNode_setValue'");
  XSRETURN(0);
}


XS(_wrap_ASTNode_setType) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    ASTNodeType_t arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_setType(self,type);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_setType" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ASTNode_setType" "', argument " "2"" of type '" "ASTNodeType_t""'");
    } 
    arg2 = static_cast< ASTNodeType_t >(val2);
    result = (int)(arg1)->setType(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_setUnits) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    std::string arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_setUnits(self,units);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_setUnits" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "ASTNode_setUnits" "', argument " "2"" of type '" "std::string""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (int)(arg1)->setUnits(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_swapChildren) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    ASTNode *arg2 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ASTNode_swapChildren(self,that);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_swapChildren" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ASTNode_swapChildren" "', argument " "2"" of type '" "ASTNode *""'"); 
    }
    arg2 = reinterpret_cast< ASTNode * >(argp2);
    result = (int)(arg1)->swapChildren(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_unsetUnits) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_unsetUnits(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_unsetUnits" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (int)(arg1)->unsetUnits();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getDefinitionURL) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLAttributes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getDefinitionURL(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getDefinitionURL" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (XMLAttributes *)((ASTNode const *)arg1)->getDefinitionURL();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLAttributes, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_replaceArgument) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    std::string arg2 ;
    ASTNode *arg3 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp3 = 0 ;
    int res3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: ASTNode_replaceArgument(self,bvar,arg);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_replaceArgument" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "ASTNode_replaceArgument" "', argument " "2"" of type '" "std::string const""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    res3 = SWIG_ConvertPtr(ST(2), &argp3,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "ASTNode_replaceArgument" "', argument " "3"" of type '" "ASTNode *""'"); 
    }
    arg3 = reinterpret_cast< ASTNode * >(argp3);
    (arg1)->replaceArgument(arg2,arg3);
    ST(argvi) = sv_newmortal();
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getParentSBMLObject) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    SBase *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getParentSBMLObject(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getParentSBMLObject" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (SBase *)((ASTNode const *)arg1)->getParentSBMLObject();
    {
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), GetDowncastSwigType(result),
        0 | SWIG_SHADOW);
      argvi++;
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_reduceToBinary) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_reduceToBinary(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_reduceToBinary" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    (arg1)->reduceToBinary();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isWellFormedASTNode) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isWellFormedASTNode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isWellFormedASTNode" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isWellFormedASTNode();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_hasCorrectNumberArguments) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_hasCorrectNumberArguments(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_hasCorrectNumberArguments" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->hasCorrectNumberArguments();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_isBvar) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_isBvar(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_isBvar" "', argument " "1"" of type '" "ASTNode const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (bool)((ASTNode const *)arg1)->isBvar();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_setBvar) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_setBvar(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_setBvar" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    (arg1)->setBvar();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ASTNode_getListOfNodes) {
  {
    ASTNode *arg1 = (ASTNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ListWrapper< ASTNode > *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ASTNode_getListOfNodes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ASTNode_getListOfNodes" "', argument " "1"" of type '" "ASTNode *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode * >(argp1);
    result = (ListWrapper< ASTNode > *)ASTNode_getListOfNodes(arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ListWrapperT_ASTNode_t, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_parseFormula) {
  {
    char *arg1 = (char *) 0 ;
    int res1 ;
    char *buf1 = 0 ;
    int alloc1 = 0 ;
    int argvi = 0;
    ASTNode_t *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: parseFormula(formula);");
    }
    res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1);
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "parseFormula" "', argument " "1"" of type '" "char const *""'");
    }
    arg1 = reinterpret_cast< char * >(buf1);
    result = (ASTNode_t *)SBML_parseFormula((char const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ASTNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    XSRETURN(argvi);
  fail:
    if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
    SWIG_croak_null();
  }
}


XS(_wrap_formulaToString) {
  {
    ASTNode_t *arg1 = (ASTNode_t *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    char *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: formulaToString(tree);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ASTNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "formulaToString" "', argument " "1"" of type '" "ASTNode_t const *""'"); 
    }
    arg1 = reinterpret_cast< ASTNode_t * >(argp1);
    result = (char *)SBML_formulaToString((ASTNode const *)arg1);
    ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ;
    
    free(result);
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLConstructorException__SWIG_0) {
  {
    std::string arg1 ;
    int argvi = 0;
    XMLConstructorException *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLConstructorException(message);");
    }
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_XMLConstructorException" "', argument " "1"" of type '" "std::string""'"); 
      }
      arg1 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (XMLConstructorException *)new XMLConstructorException(arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLConstructorException, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLConstructorException__SWIG_1) {
  {
    int argvi = 0;
    XMLConstructorException *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_XMLConstructorException();");
    }
    result = (XMLConstructorException *)new XMLConstructorException();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLConstructorException, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLConstructorException) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLConstructorException__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLConstructorException__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_XMLConstructorException'");
  XSRETURN(0);
}


XS(_wrap_delete_XMLConstructorException) {
  {
    XMLConstructorException *arg1 = (XMLConstructorException *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_XMLConstructorException(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLConstructorException, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_XMLConstructorException" "', argument " "1"" of type '" "XMLConstructorException *""'"); 
    }
    arg1 = reinterpret_cast< XMLConstructorException * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLAttributes__SWIG_0) {
  {
    int argvi = 0;
    XMLAttributes *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_XMLAttributes();");
    }
    {
      try {
        result = (XMLAttributes *)new XMLAttributes();
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLAttributes, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_XMLAttributes) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_XMLAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_XMLAttributes" "', argument " "1"" of type '" "XMLAttributes *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLAttributes__SWIG_1) {
  {
    XMLAttributes *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLAttributes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLAttributes(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLAttributes" "', argument " "1"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLAttributes" "', argument " "1"" of type '" "XMLAttributes const &""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      try {
        result = (XMLAttributes *)new XMLAttributes((XMLAttributes const &)*arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLAttributes, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLAttributes) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLAttributes__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLAttributes__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'new_XMLAttributes'");
  XSRETURN(0);
}


XS(_wrap_XMLAttributes_clone) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLAttributes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLAttributes_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_clone" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    result = (XMLAttributes *)((XMLAttributes const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLAttributes, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_add__SWIG_0) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    std::string *arg4 = 0 ;
    std::string *arg5 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int res4 = SWIG_OLDOBJ ;
    int res5 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 5) || (items > 5)) {
      SWIG_croak("Usage: XMLAttributes_add(self,name,value,namespaceURI,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_add" "', argument " "1"" of type '" "XMLAttributes *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_add" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_add" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLAttributes_add" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_add" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res4 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), &ptr);
      if (!SWIG_IsOK(res4)) {
        SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "XMLAttributes_add" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_add" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      arg4 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res5 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(4), &ptr);
      if (!SWIG_IsOK(res5)) {
        SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "XMLAttributes_add" "', argument " "5"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_add" "', argument " "5"" of type '" "std::string const &""'"); 
      }
      arg5 = ptr;
    }
    result = (int)(arg1)->add((std::string const &)*arg2,(std::string const &)*arg3,(std::string const &)*arg4,(std::string const &)*arg5);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    if (SWIG_IsNewObj(res4)) delete arg4;
    if (SWIG_IsNewObj(res5)) delete arg5;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    if (SWIG_IsNewObj(res4)) delete arg4;
    if (SWIG_IsNewObj(res5)) delete arg5;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_add__SWIG_1) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    std::string *arg4 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int res4 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 4) || (items > 4)) {
      SWIG_croak("Usage: XMLAttributes_add(self,name,value,namespaceURI);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_add" "', argument " "1"" of type '" "XMLAttributes *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_add" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_add" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLAttributes_add" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_add" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res4 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), &ptr);
      if (!SWIG_IsOK(res4)) {
        SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "XMLAttributes_add" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_add" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      arg4 = ptr;
    }
    result = (int)(arg1)->add((std::string const &)*arg2,(std::string const &)*arg3,(std::string const &)*arg4);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    if (SWIG_IsNewObj(res4)) delete arg4;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    if (SWIG_IsNewObj(res4)) delete arg4;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_add__SWIG_2) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLAttributes_add(self,name,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_add" "', argument " "1"" of type '" "XMLAttributes *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_add" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_add" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLAttributes_add" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_add" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (int)(arg1)->add((std::string const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_add__SWIG_3) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    XMLTriple *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLAttributes_add(self,triple,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_add" "', argument " "1"" of type '" "XMLAttributes *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_add" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_add" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLAttributes_add" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_add" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (int)(arg1)->add((XMLTriple const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_add) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 4) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 5) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(4), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_add__SWIG_3); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_add__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_add__SWIG_1); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_add__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLAttributes_add'");
  XSRETURN(0);
}


XS(_wrap_XMLAttributes_removeResource) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_removeResource(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_removeResource" "', argument " "1"" of type '" "XMLAttributes *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLAttributes_removeResource" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (int)(arg1)->removeResource(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_remove__SWIG_0) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_remove(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_remove" "', argument " "1"" of type '" "XMLAttributes *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLAttributes_remove" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (int)(arg1)->remove(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_remove__SWIG_1) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLAttributes_remove(self,name,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_remove" "', argument " "1"" of type '" "XMLAttributes *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLAttributes_remove" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_remove" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (int)(arg1)->remove((std::string const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_remove__SWIG_2) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_remove(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_remove" "', argument " "1"" of type '" "XMLAttributes *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_remove__SWIG_3) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_remove(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_remove" "', argument " "1"" of type '" "XMLAttributes *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_remove" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_remove" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    result = (int)(arg1)->remove((XMLTriple const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_remove__SWIG_3); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_remove__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_remove__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLAttributes_remove'");
  XSRETURN(0);
}


XS(_wrap_XMLAttributes_clear) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLAttributes_clear(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_clear" "', argument " "1"" of type '" "XMLAttributes *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    result = (int)(arg1)->clear();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getIndex__SWIG_0) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_getIndex(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getIndex" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_getIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_getIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)((XMLAttributes const *)arg1)->getIndex((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getIndex__SWIG_1) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLAttributes_getIndex(self,name,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getIndex" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_getIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_getIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLAttributes_getIndex" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_getIndex" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (int)((XMLAttributes const *)arg1)->getIndex((std::string const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getIndex__SWIG_2) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_getIndex(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getIndex" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_getIndex" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_getIndex" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    result = (int)((XMLAttributes const *)arg1)->getIndex((XMLTriple const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getIndex) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_getIndex__SWIG_2); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_getIndex__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_getIndex__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLAttributes_getIndex'");
  XSRETURN(0);
}


XS(_wrap_XMLAttributes_getLength) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLAttributes_getLength(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getLength" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    result = (int)((XMLAttributes const *)arg1)->getLength();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getName) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_getName(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getName" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLAttributes_getName" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLAttributes const *)arg1)->getName(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getPrefix) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_getPrefix(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getPrefix" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLAttributes_getPrefix" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLAttributes const *)arg1)->getPrefix(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getPrefixedName) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_getPrefixedName(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getPrefixedName" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLAttributes_getPrefixedName" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLAttributes const *)arg1)->getPrefixedName(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getURI) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_getURI(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getURI" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLAttributes_getURI" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLAttributes const *)arg1)->getURI(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getValue__SWIG_0) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_getValue(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getValue" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLAttributes_getValue" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLAttributes const *)arg1)->getValue(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getValue__SWIG_1) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    std::string arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_getValue(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getValue" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLAttributes_getValue" "', argument " "2"" of type '" "std::string const""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = ((XMLAttributes const *)arg1)->getValue(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getValue__SWIG_2) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    std::string arg2 ;
    std::string arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLAttributes_getValue(self,name,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getValue" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLAttributes_getValue" "', argument " "2"" of type '" "std::string const""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLAttributes_getValue" "', argument " "3"" of type '" "std::string const""'"); 
      }
      arg3 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = ((XMLAttributes const *)arg1)->getValue(arg2,arg3);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getValue__SWIG_3) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_getValue(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_getValue" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_getValue" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_getValue" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    result = ((XMLAttributes const *)arg1)->getValue((XMLTriple const &)*arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_getValue) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_getValue__SWIG_3); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_getValue__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_getValue__SWIG_1); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_getValue__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLAttributes_getValue'");
  XSRETURN(0);
}


XS(_wrap_XMLAttributes_hasAttribute__SWIG_0) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_hasAttribute(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_hasAttribute" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLAttributes_hasAttribute" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (bool)((XMLAttributes const *)arg1)->hasAttribute(arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_hasAttribute__SWIG_1) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    std::string arg2 ;
    std::string arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLAttributes_hasAttribute(self,name,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_hasAttribute" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLAttributes_hasAttribute" "', argument " "2"" of type '" "std::string const""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLAttributes_hasAttribute" "', argument " "3"" of type '" "std::string const""'"); 
      }
      arg3 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (bool)((XMLAttributes const *)arg1)->hasAttribute(arg2,arg3);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_hasAttribute__SWIG_2) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    std::string arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_hasAttribute(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_hasAttribute" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLAttributes_hasAttribute" "', argument " "2"" of type '" "std::string const""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (bool)((XMLAttributes const *)arg1)->hasAttribute(arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_hasAttribute__SWIG_3) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLAttributes_hasAttribute(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_hasAttribute" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLAttributes_hasAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLAttributes_hasAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    result = (bool)((XMLAttributes const *)arg1)->hasAttribute((XMLTriple const &)*arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLAttributes_hasAttribute) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_hasAttribute__SWIG_3); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_hasAttribute__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_hasAttribute__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLAttributes_hasAttribute__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLAttributes_hasAttribute'");
  XSRETURN(0);
}


XS(_wrap_XMLAttributes_isEmpty) {
  {
    XMLAttributes *arg1 = (XMLAttributes *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLAttributes_isEmpty(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLAttributes, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLAttributes_isEmpty" "', argument " "1"" of type '" "XMLAttributes const *""'"); 
    }
    arg1 = reinterpret_cast< XMLAttributes * >(argp1);
    result = (bool)((XMLAttributes const *)arg1)->isEmpty();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNamespaces__SWIG_0) {
  {
    int argvi = 0;
    XMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_XMLNamespaces();");
    }
    {
      try {
        result = (XMLNamespaces *)new XMLNamespaces();
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNamespaces, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_XMLNamespaces) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_XMLNamespaces(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_XMLNamespaces" "', argument " "1"" of type '" "XMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNamespaces__SWIG_1) {
  {
    XMLNamespaces *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLNamespaces(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLNamespaces,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNamespaces" "', argument " "1"" of type '" "XMLNamespaces const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNamespaces" "', argument " "1"" of type '" "XMLNamespaces const &""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    {
      try {
        result = (XMLNamespaces *)new XMLNamespaces((XMLNamespaces const &)*arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNamespaces, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNamespaces) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNamespaces__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNamespaces__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'new_XMLNamespaces'");
  XSRETURN(0);
}


XS(_wrap_XMLNamespaces_clone) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLNamespaces_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_clone" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    result = (XMLNamespaces *)((XMLNamespaces const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNamespaces, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_add__SWIG_0) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLNamespaces_add(self,uri,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_add" "', argument " "1"" of type '" "XMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNamespaces_add" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNamespaces_add" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLNamespaces_add" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNamespaces_add" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (int)(arg1)->add((std::string const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_add__SWIG_1) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNamespaces_add(self,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_add" "', argument " "1"" of type '" "XMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNamespaces_add" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNamespaces_add" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->add((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_add) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNamespaces_add__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNamespaces_add__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLNamespaces_add'");
  XSRETURN(0);
}


XS(_wrap_XMLNamespaces_remove__SWIG_0) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNamespaces_remove(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_remove" "', argument " "1"" of type '" "XMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLNamespaces_remove" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (int)(arg1)->remove(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_remove__SWIG_1) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNamespaces_remove(self,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_remove" "', argument " "1"" of type '" "XMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNamespaces_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNamespaces_remove" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->remove((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_remove) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNamespaces_remove__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNamespaces_remove__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLNamespaces_remove'");
  XSRETURN(0);
}


XS(_wrap_XMLNamespaces_clear) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLNamespaces_clear(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_clear" "', argument " "1"" of type '" "XMLNamespaces *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    result = (int)(arg1)->clear();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_getIndex) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    std::string arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNamespaces_getIndex(self,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_getIndex" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLNamespaces_getIndex" "', argument " "2"" of type '" "std::string const""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (int)((XMLNamespaces const *)arg1)->getIndex(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_getIndexByPrefix) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    std::string arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNamespaces_getIndexByPrefix(self,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_getIndexByPrefix" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLNamespaces_getIndexByPrefix" "', argument " "2"" of type '" "std::string const""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (int)((XMLNamespaces const *)arg1)->getIndexByPrefix(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_getLength) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLNamespaces_getLength(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_getLength" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    result = (int)((XMLNamespaces const *)arg1)->getLength();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_getPrefix__SWIG_0) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNamespaces_getPrefix(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_getPrefix" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLNamespaces_getPrefix" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLNamespaces const *)arg1)->getPrefix(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_getPrefix__SWIG_1) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNamespaces_getPrefix(self,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_getPrefix" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNamespaces_getPrefix" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNamespaces_getPrefix" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = ((XMLNamespaces const *)arg1)->getPrefix((std::string const &)*arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_getPrefix) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNamespaces_getPrefix__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNamespaces_getPrefix__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLNamespaces_getPrefix'");
  XSRETURN(0);
}


XS(_wrap_XMLNamespaces_getURI__SWIG_0) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNamespaces_getURI(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_getURI" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLNamespaces_getURI" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLNamespaces const *)arg1)->getURI(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_getURI__SWIG_1) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNamespaces_getURI(self,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_getURI" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNamespaces_getURI" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNamespaces_getURI" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = ((XMLNamespaces const *)arg1)->getURI((std::string const &)*arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_getURI__SWIG_2) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLNamespaces_getURI(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_getURI" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    result = ((XMLNamespaces const *)arg1)->getURI();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_getURI) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNamespaces_getURI__SWIG_2); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNamespaces_getURI__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNamespaces_getURI__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLNamespaces_getURI'");
  XSRETURN(0);
}


XS(_wrap_XMLNamespaces_isEmpty) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLNamespaces_isEmpty(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_isEmpty" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    result = (bool)((XMLNamespaces const *)arg1)->isEmpty();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_hasURI) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNamespaces_hasURI(self,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_hasURI" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNamespaces_hasURI" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNamespaces_hasURI" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (bool)((XMLNamespaces const *)arg1)->hasURI((std::string const &)*arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_hasPrefix) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNamespaces_hasPrefix(self,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_hasPrefix" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNamespaces_hasPrefix" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNamespaces_hasPrefix" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (bool)((XMLNamespaces const *)arg1)->hasPrefix((std::string const &)*arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNamespaces_hasNS) {
  {
    XMLNamespaces *arg1 = (XMLNamespaces *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLNamespaces_hasNS(self,uri,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNamespaces_hasNS" "', argument " "1"" of type '" "XMLNamespaces const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNamespaces * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNamespaces_hasNS" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNamespaces_hasNS" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLNamespaces_hasNS" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNamespaces_hasNS" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (bool)((XMLNamespaces const *)arg1)->hasNS((std::string const &)*arg2,(std::string const &)*arg3);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_0) {
  {
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_XMLToken();");
    }
    {
      try {
        result = (XMLToken *)new XMLToken();
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_1) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    XMLNamespaces *arg3 = 0 ;
    unsigned int arg4 ;
    unsigned int arg5 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    void *argp3 ;
    int res3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 5) || (items > 5)) {
      SWIG_croak("Usage: new_XMLToken(triple,attributes,namespaces,line,column);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    res3 = SWIG_ConvertPtr(ST(2), &argp3, SWIGTYPE_p_XMLNamespaces,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "new_XMLToken" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    arg3 = reinterpret_cast< XMLNamespaces * >(argp3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_XMLToken" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_XMLToken" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    {
      try {
        result = (XMLToken *)new XMLToken((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2,(XMLNamespaces const &)*arg3,arg4,arg5);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_2) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    XMLNamespaces *arg3 = 0 ;
    unsigned int arg4 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    void *argp3 ;
    int res3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 4) || (items > 4)) {
      SWIG_croak("Usage: new_XMLToken(triple,attributes,namespaces,line);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    res3 = SWIG_ConvertPtr(ST(2), &argp3, SWIGTYPE_p_XMLNamespaces,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "new_XMLToken" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    arg3 = reinterpret_cast< XMLNamespaces * >(argp3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_XMLToken" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    {
      try {
        result = (XMLToken *)new XMLToken((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2,(XMLNamespaces const &)*arg3,arg4);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_3) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    XMLNamespaces *arg3 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    void *argp3 ;
    int res3 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_XMLToken(triple,attributes,namespaces);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    res3 = SWIG_ConvertPtr(ST(2), &argp3, SWIGTYPE_p_XMLNamespaces,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "new_XMLToken" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    arg3 = reinterpret_cast< XMLNamespaces * >(argp3);
    {
      try {
        result = (XMLToken *)new XMLToken((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2,(XMLNamespaces const &)*arg3);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_4) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    unsigned int arg3 ;
    unsigned int arg4 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 4) || (items > 4)) {
      SWIG_croak("Usage: new_XMLToken(triple,attributes,line,column);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLToken" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_XMLToken" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    {
      try {
        result = (XMLToken *)new XMLToken((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2,arg3,arg4);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_5) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    unsigned int arg3 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_XMLToken(triple,attributes,line);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLToken" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      try {
        result = (XMLToken *)new XMLToken((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2,arg3);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_6) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_XMLToken(triple,attributes);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    {
      try {
        result = (XMLToken *)new XMLToken((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_7) {
  {
    XMLTriple *arg1 = 0 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    void *argp1 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_XMLToken(triple,line,column);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_XMLToken" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLToken" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      try {
        result = (XMLToken *)new XMLToken((XMLTriple const &)*arg1,arg2,arg3);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_8) {
  {
    XMLTriple *arg1 = 0 ;
    unsigned int arg2 ;
    void *argp1 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_XMLToken(triple,line);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_XMLToken" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (XMLToken *)new XMLToken((XMLTriple const &)*arg1,arg2);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_9) {
  {
    XMLTriple *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLToken(triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    {
      try {
        result = (XMLToken *)new XMLToken((XMLTriple const &)*arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_10) {
  {
    std::string *arg1 = 0 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    int res1 = SWIG_OLDOBJ ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_XMLToken(chars,line,column);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_XMLToken" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLToken" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      try {
        result = (XMLToken *)new XMLToken((std::string const &)*arg1,arg2,arg3);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_11) {
  {
    std::string *arg1 = 0 ;
    unsigned int arg2 ;
    int res1 = SWIG_OLDOBJ ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_XMLToken(chars,line);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_XMLToken" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (XMLToken *)new XMLToken((std::string const &)*arg1,arg2);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_12) {
  {
    std::string *arg1 = 0 ;
    int res1 = SWIG_OLDOBJ ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLToken(chars);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    {
      try {
        result = (XMLToken *)new XMLToken((std::string const &)*arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    SWIG_croak_null();
  }
}


XS(_wrap_delete_XMLToken) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_XMLToken(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_XMLToken" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken__SWIG_13) {
  {
    XMLToken *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLToken(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLToken,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLToken const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLToken" "', argument " "1"" of type '" "XMLToken const &""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      try {
        result = (XMLToken *)new XMLToken((XMLToken const &)*arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLToken) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 5;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_5:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 6;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_6:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 7;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_7:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(2), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 8;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_8:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 9;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_9:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 10;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_10:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 11;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_11:
    
    if (items == 4) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(2), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 12;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_12:
    
    if (items == 4) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_13;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_13;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_13;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_13;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 13;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_13:
    
    if (items == 5) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_14;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_14;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(2), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_14;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_14;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_14;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 14;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_14:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_9); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_13); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_12); return;
    case 5:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_6); return;
    case 6:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_8); return;
    case 7:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_11); return;
    case 8:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_3); return;
    case 9:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_5); return;
    case 10:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_7); return;
    case 11:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_10); return;
    case 12:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_2); return;
    case 13:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_4); return;
    case 14:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLToken__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'new_XMLToken'");
  XSRETURN(0);
}


XS(_wrap_XMLToken_clone) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLToken *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_clone" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (XMLToken *)((XMLToken const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLToken, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttributes) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLAttributes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_getAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttributes" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (XMLAttributes *) &((XMLToken const *)arg1)->getAttributes();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLAttributes, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_setAttributes) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    XMLAttributes *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_setAttributes(self,attributes);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_setAttributes" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_setAttributes" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_setAttributes" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    result = (int)(arg1)->setAttributes((XMLAttributes const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_addAttr__SWIG_0) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    std::string *arg4 = 0 ;
    std::string *arg5 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int res4 = SWIG_OLDOBJ ;
    int res5 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 5) || (items > 5)) {
      SWIG_croak("Usage: XMLToken_addAttr(self,name,value,namespaceURI,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_addAttr" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_addAttr" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addAttr" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLToken_addAttr" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addAttr" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res4 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), &ptr);
      if (!SWIG_IsOK(res4)) {
        SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "XMLToken_addAttr" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addAttr" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      arg4 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res5 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(4), &ptr);
      if (!SWIG_IsOK(res5)) {
        SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "XMLToken_addAttr" "', argument " "5"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addAttr" "', argument " "5"" of type '" "std::string const &""'"); 
      }
      arg5 = ptr;
    }
    result = (int)(arg1)->addAttr((std::string const &)*arg2,(std::string const &)*arg3,(std::string const &)*arg4,(std::string const &)*arg5);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    if (SWIG_IsNewObj(res4)) delete arg4;
    if (SWIG_IsNewObj(res5)) delete arg5;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    if (SWIG_IsNewObj(res4)) delete arg4;
    if (SWIG_IsNewObj(res5)) delete arg5;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_addAttr__SWIG_1) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    std::string *arg4 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int res4 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 4) || (items > 4)) {
      SWIG_croak("Usage: XMLToken_addAttr(self,name,value,namespaceURI);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_addAttr" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_addAttr" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addAttr" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLToken_addAttr" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addAttr" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res4 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), &ptr);
      if (!SWIG_IsOK(res4)) {
        SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "XMLToken_addAttr" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addAttr" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      arg4 = ptr;
    }
    result = (int)(arg1)->addAttr((std::string const &)*arg2,(std::string const &)*arg3,(std::string const &)*arg4);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    if (SWIG_IsNewObj(res4)) delete arg4;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    if (SWIG_IsNewObj(res4)) delete arg4;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_addAttr__SWIG_2) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLToken_addAttr(self,name,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_addAttr" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_addAttr" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addAttr" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLToken_addAttr" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addAttr" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (int)(arg1)->addAttr((std::string const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_addAttr__SWIG_3) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    XMLTriple *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLToken_addAttr(self,triple,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_addAttr" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_addAttr" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addAttr" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLToken_addAttr" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addAttr" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (int)(arg1)->addAttr((XMLTriple const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_addAttr) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 4) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 5) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(4), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_addAttr__SWIG_3); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_addAttr__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_addAttr__SWIG_1); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_addAttr__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLToken_addAttr'");
  XSRETURN(0);
}


XS(_wrap_XMLToken_removeAttr__SWIG_0) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_removeAttr(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_removeAttr" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLToken_removeAttr" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (int)(arg1)->removeAttr(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_removeAttr__SWIG_1) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLToken_removeAttr(self,name,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_removeAttr" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_removeAttr" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_removeAttr" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLToken_removeAttr" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_removeAttr" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (int)(arg1)->removeAttr((std::string const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_removeAttr__SWIG_2) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_removeAttr(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_removeAttr" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_removeAttr" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_removeAttr" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->removeAttr((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_removeAttr__SWIG_3) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_removeAttr(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_removeAttr" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_removeAttr" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_removeAttr" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    result = (int)(arg1)->removeAttr((XMLTriple const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_removeAttr) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_removeAttr__SWIG_3); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_removeAttr__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_removeAttr__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_removeAttr__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLToken_removeAttr'");
  XSRETURN(0);
}


XS(_wrap_XMLToken_clearAttributes) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_clearAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_clearAttributes" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (int)(arg1)->clearAttributes();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrIndex__SWIG_0) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLToken_getAttrIndex(self,name,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttrIndex" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_getAttrIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_getAttrIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLToken_getAttrIndex" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_getAttrIndex" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (int)((XMLToken const *)arg1)->getAttrIndex((std::string const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrIndex__SWIG_1) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getAttrIndex(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttrIndex" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_getAttrIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_getAttrIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)((XMLToken const *)arg1)->getAttrIndex((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrIndex__SWIG_2) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getAttrIndex(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttrIndex" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_getAttrIndex" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_getAttrIndex" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    result = (int)((XMLToken const *)arg1)->getAttrIndex((XMLTriple const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrIndex) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getAttrIndex__SWIG_2); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getAttrIndex__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getAttrIndex__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLToken_getAttrIndex'");
  XSRETURN(0);
}


XS(_wrap_XMLToken_getAttributesLength) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_getAttributesLength(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttributesLength" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (int)((XMLToken const *)arg1)->getAttributesLength();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrName) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getAttrName(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttrName" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLToken_getAttrName" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLToken const *)arg1)->getAttrName(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrPrefix) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getAttrPrefix(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttrPrefix" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLToken_getAttrPrefix" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLToken const *)arg1)->getAttrPrefix(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrPrefixedName) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getAttrPrefixedName(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttrPrefixedName" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLToken_getAttrPrefixedName" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLToken const *)arg1)->getAttrPrefixedName(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrURI) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getAttrURI(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttrURI" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLToken_getAttrURI" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLToken const *)arg1)->getAttrURI(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrValue__SWIG_0) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getAttrValue(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttrValue" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLToken_getAttrValue" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLToken const *)arg1)->getAttrValue(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrValue__SWIG_1) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string arg2 ;
    std::string arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLToken_getAttrValue(self,name,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttrValue" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLToken_getAttrValue" "', argument " "2"" of type '" "std::string const""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLToken_getAttrValue" "', argument " "3"" of type '" "std::string const""'"); 
      }
      arg3 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = ((XMLToken const *)arg1)->getAttrValue(arg2,arg3);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrValue__SWIG_2) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getAttrValue(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttrValue" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLToken_getAttrValue" "', argument " "2"" of type '" "std::string const""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = ((XMLToken const *)arg1)->getAttrValue(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrValue__SWIG_3) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getAttrValue(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getAttrValue" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_getAttrValue" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_getAttrValue" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    result = ((XMLToken const *)arg1)->getAttrValue((XMLTriple const &)*arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getAttrValue) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getAttrValue__SWIG_3); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getAttrValue__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getAttrValue__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getAttrValue__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLToken_getAttrValue'");
  XSRETURN(0);
}


XS(_wrap_XMLToken_hasAttr__SWIG_0) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_hasAttr(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_hasAttr" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLToken_hasAttr" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (bool)((XMLToken const *)arg1)->hasAttr(arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_hasAttr__SWIG_1) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string arg2 ;
    std::string arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLToken_hasAttr(self,name,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_hasAttr" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLToken_hasAttr" "', argument " "2"" of type '" "std::string const""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLToken_hasAttr" "', argument " "3"" of type '" "std::string const""'"); 
      }
      arg3 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (bool)((XMLToken const *)arg1)->hasAttr(arg2,arg3);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_hasAttr__SWIG_2) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_hasAttr(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_hasAttr" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "XMLToken_hasAttr" "', argument " "2"" of type '" "std::string const""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (bool)((XMLToken const *)arg1)->hasAttr(arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_hasAttr__SWIG_3) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_hasAttr(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_hasAttr" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_hasAttr" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_hasAttr" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    result = (bool)((XMLToken const *)arg1)->hasAttr((XMLTriple const &)*arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_hasAttr) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_hasAttr__SWIG_3); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_hasAttr__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_hasAttr__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_hasAttr__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLToken_hasAttr'");
  XSRETURN(0);
}


XS(_wrap_XMLToken_isAttributesEmpty) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_isAttributesEmpty(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_isAttributesEmpty" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (bool)((XMLToken const *)arg1)->isAttributesEmpty();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getNamespaces) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNamespaces *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_getNamespaces(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getNamespaces" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (XMLNamespaces *) &((XMLToken const *)arg1)->getNamespaces();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNamespaces, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_setNamespaces) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    XMLNamespaces *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_setNamespaces(self,namespaces);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_setNamespaces" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLNamespaces,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_setNamespaces" "', argument " "2"" of type '" "XMLNamespaces const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_setNamespaces" "', argument " "2"" of type '" "XMLNamespaces const &""'"); 
    }
    arg2 = reinterpret_cast< XMLNamespaces * >(argp2);
    result = (int)(arg1)->setNamespaces((XMLNamespaces const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_addNamespace__SWIG_0) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLToken_addNamespace(self,uri,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_addNamespace" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_addNamespace" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addNamespace" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLToken_addNamespace" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addNamespace" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (int)(arg1)->addNamespace((std::string const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_addNamespace__SWIG_1) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_addNamespace(self,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_addNamespace" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_addNamespace" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_addNamespace" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->addNamespace((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_addNamespace) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_addNamespace__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_addNamespace__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLToken_addNamespace'");
  XSRETURN(0);
}


XS(_wrap_XMLToken_removeNamespace__SWIG_0) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_removeNamespace(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_removeNamespace" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLToken_removeNamespace" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = (int)(arg1)->removeNamespace(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_removeNamespace__SWIG_1) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_removeNamespace(self,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_removeNamespace" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_removeNamespace" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_removeNamespace" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->removeNamespace((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_removeNamespace) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_removeNamespace__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_removeNamespace__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLToken_removeNamespace'");
  XSRETURN(0);
}


XS(_wrap_XMLToken_clearNamespaces) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_clearNamespaces(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_clearNamespaces" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (int)(arg1)->clearNamespaces();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getNamespaceIndex) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getNamespaceIndex(self,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getNamespaceIndex" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_getNamespaceIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_getNamespaceIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)((XMLToken const *)arg1)->getNamespaceIndex((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getNamespaceIndexByPrefix) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getNamespaceIndexByPrefix(self,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getNamespaceIndexByPrefix" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_getNamespaceIndexByPrefix" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_getNamespaceIndexByPrefix" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)((XMLToken const *)arg1)->getNamespaceIndexByPrefix((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getNamespacesLength) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_getNamespacesLength(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getNamespacesLength" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (int)((XMLToken const *)arg1)->getNamespacesLength();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getNamespacePrefix__SWIG_0) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getNamespacePrefix(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getNamespacePrefix" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLToken_getNamespacePrefix" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLToken const *)arg1)->getNamespacePrefix(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getNamespacePrefix__SWIG_1) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getNamespacePrefix(self,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getNamespacePrefix" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_getNamespacePrefix" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_getNamespacePrefix" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = ((XMLToken const *)arg1)->getNamespacePrefix((std::string const &)*arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getNamespacePrefix) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getNamespacePrefix__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getNamespacePrefix__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLToken_getNamespacePrefix'");
  XSRETURN(0);
}


XS(_wrap_XMLToken_getNamespaceURI__SWIG_0) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getNamespaceURI(self,index);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getNamespaceURI" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLToken_getNamespaceURI" "', argument " "2"" of type '" "int""'");
    } 
    arg2 = static_cast< int >(val2);
    result = ((XMLToken const *)arg1)->getNamespaceURI(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getNamespaceURI__SWIG_1) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_getNamespaceURI(self,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getNamespaceURI" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_getNamespaceURI" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_getNamespaceURI" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = ((XMLToken const *)arg1)->getNamespaceURI((std::string const &)*arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getNamespaceURI__SWIG_2) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_getNamespaceURI(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getNamespaceURI" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = ((XMLToken const *)arg1)->getNamespaceURI();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getNamespaceURI) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getNamespaceURI__SWIG_2); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getNamespaceURI__SWIG_0); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLToken_getNamespaceURI__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLToken_getNamespaceURI'");
  XSRETURN(0);
}


XS(_wrap_XMLToken_isNamespacesEmpty) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_isNamespacesEmpty(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_isNamespacesEmpty" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (bool)((XMLToken const *)arg1)->isNamespacesEmpty();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_hasNamespaceURI) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_hasNamespaceURI(self,uri);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_hasNamespaceURI" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_hasNamespaceURI" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_hasNamespaceURI" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (bool)((XMLToken const *)arg1)->hasNamespaceURI((std::string const &)*arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_hasNamespacePrefix) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_hasNamespacePrefix(self,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_hasNamespacePrefix" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_hasNamespacePrefix" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_hasNamespacePrefix" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (bool)((XMLToken const *)arg1)->hasNamespacePrefix((std::string const &)*arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_hasNamespaceNS) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLToken_hasNamespaceNS(self,uri,prefix);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_hasNamespaceNS" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_hasNamespaceNS" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_hasNamespaceNS" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLToken_hasNamespaceNS" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_hasNamespaceNS" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (bool)((XMLToken const *)arg1)->hasNamespaceNS((std::string const &)*arg2,(std::string const &)*arg3);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_setTriple) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_setTriple(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_setTriple" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_setTriple" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_setTriple" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    result = (int)(arg1)->setTriple((XMLTriple const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getName) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getName" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (std::string *) &((XMLToken const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getPrefix) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_getPrefix(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getPrefix" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (std::string *) &((XMLToken const *)arg1)->getPrefix();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getURI) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_getURI(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getURI" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (std::string *) &((XMLToken const *)arg1)->getURI();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getCharacters) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_getCharacters(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getCharacters" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (std::string *) &((XMLToken const *)arg1)->getCharacters();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_append) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_append(self,chars);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_append" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_append" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_append" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->append((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getColumn) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_getColumn(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getColumn" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (unsigned int)((XMLToken const *)arg1)->getColumn();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_getLine) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_getLine(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_getLine" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (unsigned int)((XMLToken const *)arg1)->getLine();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_isElement) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_isElement(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_isElement" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (bool)((XMLToken const *)arg1)->isElement();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_isEnd) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_isEnd(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_isEnd" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (bool)((XMLToken const *)arg1)->isEnd();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_isEndFor) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    XMLToken *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLToken_isEndFor(self,element);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_isEndFor" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLToken,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLToken_isEndFor" "', argument " "2"" of type '" "XMLToken const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLToken_isEndFor" "', argument " "2"" of type '" "XMLToken const &""'"); 
    }
    arg2 = reinterpret_cast< XMLToken * >(argp2);
    result = (bool)((XMLToken const *)arg1)->isEndFor((XMLToken const &)*arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_isEOF) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_isEOF(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_isEOF" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (bool)((XMLToken const *)arg1)->isEOF();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_isStart) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_isStart(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_isStart" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (bool)((XMLToken const *)arg1)->isStart();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_isText) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_isText(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_isText" "', argument " "1"" of type '" "XMLToken const *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (bool)((XMLToken const *)arg1)->isText();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_setEnd) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_setEnd(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_setEnd" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (int)(arg1)->setEnd();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_setEOF) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_setEOF(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_setEOF" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (int)(arg1)->setEOF();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_unsetEnd) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_unsetEnd(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_unsetEnd" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (int)(arg1)->unsetEnd();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLToken_toString) {
  {
    XMLToken *arg1 = (XMLToken *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLToken_toString(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLToken, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLToken_toString" "', argument " "1"" of type '" "XMLToken *""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    result = (arg1)->toString();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_0) {
  {
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_XMLNode();");
    }
    {
      try {
        result = (XMLNode *)new XMLNode();
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_1) {
  {
    XMLToken *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLNode(token);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLToken,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLToken const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLToken const &""'"); 
    }
    arg1 = reinterpret_cast< XMLToken * >(argp1);
    {
      try {
        result = (XMLNode *)new XMLNode((XMLToken const &)*arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_2) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    XMLNamespaces *arg3 = 0 ;
    unsigned int arg4 ;
    unsigned int arg5 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    void *argp3 ;
    int res3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 5) || (items > 5)) {
      SWIG_croak("Usage: new_XMLNode(triple,attributes,namespaces,line,column);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    res3 = SWIG_ConvertPtr(ST(2), &argp3, SWIGTYPE_p_XMLNamespaces,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "new_XMLNode" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    arg3 = reinterpret_cast< XMLNamespaces * >(argp3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_XMLNode" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_XMLNode" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    {
      try {
        result = (XMLNode *)new XMLNode((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2,(XMLNamespaces const &)*arg3,arg4,arg5);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_3) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    XMLNamespaces *arg3 = 0 ;
    unsigned int arg4 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    void *argp3 ;
    int res3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 4) || (items > 4)) {
      SWIG_croak("Usage: new_XMLNode(triple,attributes,namespaces,line);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    res3 = SWIG_ConvertPtr(ST(2), &argp3, SWIGTYPE_p_XMLNamespaces,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "new_XMLNode" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    arg3 = reinterpret_cast< XMLNamespaces * >(argp3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_XMLNode" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    {
      try {
        result = (XMLNode *)new XMLNode((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2,(XMLNamespaces const &)*arg3,arg4);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_4) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    XMLNamespaces *arg3 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    void *argp3 ;
    int res3 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_XMLNode(triple,attributes,namespaces);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    res3 = SWIG_ConvertPtr(ST(2), &argp3, SWIGTYPE_p_XMLNamespaces,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "new_XMLNode" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "3"" of type '" "XMLNamespaces const &""'"); 
    }
    arg3 = reinterpret_cast< XMLNamespaces * >(argp3);
    {
      try {
        result = (XMLNode *)new XMLNode((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2,(XMLNamespaces const &)*arg3);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_5) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    unsigned int arg3 ;
    unsigned int arg4 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 4) || (items > 4)) {
      SWIG_croak("Usage: new_XMLNode(triple,attributes,line,column);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLNode" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_XMLNode" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    {
      try {
        result = (XMLNode *)new XMLNode((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2,arg3,arg4);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_6) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    unsigned int arg3 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_XMLNode(triple,attributes,line);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLNode" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      try {
        result = (XMLNode *)new XMLNode((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2,arg3);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_7) {
  {
    XMLTriple *arg1 = 0 ;
    XMLAttributes *arg2 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_XMLNode(triple,attributes);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLAttributes,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "2"" of type '" "XMLAttributes const &""'"); 
    }
    arg2 = reinterpret_cast< XMLAttributes * >(argp2);
    {
      try {
        result = (XMLNode *)new XMLNode((XMLTriple const &)*arg1,(XMLAttributes const &)*arg2);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_8) {
  {
    XMLTriple *arg1 = 0 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    void *argp1 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_XMLNode(triple,line,column);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_XMLNode" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLNode" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      try {
        result = (XMLNode *)new XMLNode((XMLTriple const &)*arg1,arg2,arg3);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_9) {
  {
    XMLTriple *arg1 = 0 ;
    unsigned int arg2 ;
    void *argp1 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_XMLNode(triple,line);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_XMLNode" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (XMLNode *)new XMLNode((XMLTriple const &)*arg1,arg2);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_10) {
  {
    XMLTriple *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLNode(triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    {
      try {
        result = (XMLNode *)new XMLNode((XMLTriple const &)*arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_11) {
  {
    std::string *arg1 = 0 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    int res1 = SWIG_OLDOBJ ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_XMLNode(chars,line,column);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_XMLNode" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLNode" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      try {
        result = (XMLNode *)new XMLNode((std::string const &)*arg1,arg2,arg3);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_12) {
  {
    std::string *arg1 = 0 ;
    unsigned int arg2 ;
    int res1 = SWIG_OLDOBJ ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_XMLNode(chars,line);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_XMLNode" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    {
      try {
        result = (XMLNode *)new XMLNode((std::string const &)*arg1,arg2);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_13) {
  {
    std::string *arg1 = 0 ;
    int res1 = SWIG_OLDOBJ ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLNode(chars);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    {
      try {
        result = (XMLNode *)new XMLNode((std::string const &)*arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    SWIG_croak_null();
  }
}


XS(_wrap_delete_XMLNode) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_XMLNode(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_XMLNode" "', argument " "1"" of type '" "XMLNode *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode__SWIG_14) {
  {
    XMLNode *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLNode(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLNode,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLNode const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLNode" "', argument " "1"" of type '" "XMLNode const &""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    {
      try {
        result = (XMLNode *)new XMLNode((XMLNode const &)*arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLNode) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLToken, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 5;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_5:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 6;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_6:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 7;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_7:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 8;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_8:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(2), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 9;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_9:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 10;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_10:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 11;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_11:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 12;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_12:
    
    if (items == 4) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_13;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_13;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(2), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_13;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_13;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 13;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_13:
    
    if (items == 4) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_14;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_14;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_14;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_14;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 14;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_14:
    
    if (items == 5) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_15;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLAttributes, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_15;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(2), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_15;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_15;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_15;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 15;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_15:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_14); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_10); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_1); return;
    case 5:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_13); return;
    case 6:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_7); return;
    case 7:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_9); return;
    case 8:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_12); return;
    case 9:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_4); return;
    case 10:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_6); return;
    case 11:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_8); return;
    case 12:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_11); return;
    case 13:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_3); return;
    case 14:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_5); return;
    case 15:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLNode__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'new_XMLNode'");
  XSRETURN(0);
}


XS(_wrap_XMLNode_clone) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLNode_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_clone" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    result = (XMLNode *)((XMLNode const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_addChild) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    XMLNode *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNode_addChild(self,node);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_addChild" "', argument " "1"" of type '" "XMLNode *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLNode,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNode_addChild" "', argument " "2"" of type '" "XMLNode const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNode_addChild" "', argument " "2"" of type '" "XMLNode const &""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (int)(arg1)->addChild((XMLNode const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_insertChild) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    unsigned int arg2 ;
    XMLNode *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    void *argp3 ;
    int res3 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLNode_insertChild(self,n,node);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_insertChild" "', argument " "1"" of type '" "XMLNode *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLNode_insertChild" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    res3 = SWIG_ConvertPtr(ST(2), &argp3, SWIGTYPE_p_XMLNode,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLNode_insertChild" "', argument " "3"" of type '" "XMLNode const &""'"); 
    }
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNode_insertChild" "', argument " "3"" of type '" "XMLNode const &""'"); 
    }
    arg3 = reinterpret_cast< XMLNode * >(argp3);
    result = (XMLNode *) &(arg1)->insertChild(arg2,(XMLNode const &)*arg3);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, 0 | SWIG_SHADOW); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_removeChild) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNode_removeChild(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_removeChild" "', argument " "1"" of type '" "XMLNode *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLNode_removeChild" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (XMLNode *)(arg1)->removeChild(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_removeChildren) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLNode_removeChildren(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_removeChildren" "', argument " "1"" of type '" "XMLNode *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    result = (int)(arg1)->removeChildren();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_getChild__SWIG_0) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNode_getChild(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_getChild" "', argument " "1"" of type '" "XMLNode *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLNode_getChild" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (XMLNode *) &(arg1)->getChild(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_getChild__SWIG_1) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNode_getChild(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_getChild" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLNode_getChild" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (XMLNode *) &((XMLNode const *)arg1)->getChild(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_getChild__SWIG_2) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNode_getChild(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_getChild" "', argument " "1"" of type '" "XMLNode *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNode_getChild" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNode_getChild" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (XMLNode *) &(arg1)->getChild((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_getChild__SWIG_3) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNode_getChild(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_getChild" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNode_getChild" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNode_getChild" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (XMLNode *) &((XMLNode const *)arg1)->getChild((std::string const &)*arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, 0 | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_getChild) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNode_getChild__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNode_getChild__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNode_getChild__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNode_getChild__SWIG_3); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLNode_getChild'");
  XSRETURN(0);
}


XS(_wrap_XMLNode_getIndex) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNode_getIndex(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_getIndex" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNode_getIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNode_getIndex" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)((XMLNode const *)arg1)->getIndex((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_hasChild) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNode_hasChild(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_hasChild" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNode_hasChild" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNode_hasChild" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (bool)((XMLNode const *)arg1)->hasChild((std::string const &)*arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_equals) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    XMLNode *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNode_equals(self,other);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_equals" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLNode,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNode_equals" "', argument " "2"" of type '" "XMLNode const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNode_equals" "', argument " "2"" of type '" "XMLNode const &""'"); 
    }
    arg2 = reinterpret_cast< XMLNode * >(argp2);
    result = (bool)((XMLNode const *)arg1)->equals((XMLNode const &)*arg2);
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_getNumChildren) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLNode_getNumChildren(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_getNumChildren" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    result = (unsigned int)((XMLNode const *)arg1)->getNumChildren();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_toXMLString) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLNode_toXMLString(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_toXMLString" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    result = ((XMLNode const *)arg1)->toXMLString();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_convertXMLNodeToString) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLNode_convertXMLNodeToString(node);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_convertXMLNodeToString" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    result = XMLNode::convertXMLNodeToString((XMLNode const *)arg1);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_convertStringToXMLNode__SWIG_0) {
  {
    std::string *arg1 = 0 ;
    XMLNamespaces *arg2 = (XMLNamespaces *) 0 ;
    int res1 = SWIG_OLDOBJ ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLNode_convertStringToXMLNode(xmlstr,xmlns);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_convertStringToXMLNode" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNode_convertStringToXMLNode" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_XMLNamespaces, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLNode_convertStringToXMLNode" "', argument " "2"" of type '" "XMLNamespaces const *""'"); 
    }
    arg2 = reinterpret_cast< XMLNamespaces * >(argp2);
    result = (XMLNode *)XMLNode::convertStringToXMLNode((std::string const &)*arg1,(XMLNamespaces const *)arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_convertStringToXMLNode__SWIG_1) {
  {
    std::string *arg1 = 0 ;
    int res1 = SWIG_OLDOBJ ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLNode_convertStringToXMLNode(xmlstr);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLNode_convertStringToXMLNode" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLNode_convertStringToXMLNode" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    result = (XMLNode *)XMLNode::convertStringToXMLNode((std::string const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLNode_convertStringToXMLNode) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLNamespaces, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNode_convertStringToXMLNode__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLNode_convertStringToXMLNode__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLNode_convertStringToXMLNode'");
  XSRETURN(0);
}


XS(_wrap_new_XMLTriple__SWIG_0) {
  {
    int argvi = 0;
    XMLTriple *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_XMLTriple();");
    }
    result = (XMLTriple *)new XMLTriple();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLTriple, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLTriple__SWIG_1) {
  {
    std::string *arg1 = 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    int res1 = SWIG_OLDOBJ ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    XMLTriple *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_XMLTriple(name,uri,prefix);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLTriple" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLTriple" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLTriple" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLTriple" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "new_XMLTriple" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLTriple" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    result = (XMLTriple *)new XMLTriple((std::string const &)*arg1,(std::string const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLTriple, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLTriple__SWIG_2) {
  {
    std::string *arg1 = 0 ;
    char arg2 ;
    int res1 = SWIG_OLDOBJ ;
    char val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    XMLTriple *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_XMLTriple(triplet,sepchar);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLTriple" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLTriple" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    ecode2 = SWIG_AsVal_char SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_XMLTriple" "', argument " "2"" of type '" "char""'");
    } 
    arg2 = static_cast< char >(val2);
    result = (XMLTriple *)new XMLTriple((std::string const &)*arg1,arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLTriple, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLTriple__SWIG_3) {
  {
    std::string *arg1 = 0 ;
    int res1 = SWIG_OLDOBJ ;
    int argvi = 0;
    XMLTriple *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLTriple(triplet);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLTriple" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLTriple" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    result = (XMLTriple *)new XMLTriple((std::string const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLTriple, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLTriple__SWIG_4) {
  {
    XMLTriple *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLTriple *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLTriple(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLTriple" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLTriple" "', argument " "1"" of type '" "XMLTriple const &""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    result = (XMLTriple *)new XMLTriple((XMLTriple const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLTriple, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLTriple) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_char SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 5;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_5:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLTriple__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLTriple__SWIG_4); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLTriple__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLTriple__SWIG_2); return;
    case 5:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLTriple__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'new_XMLTriple'");
  XSRETURN(0);
}


XS(_wrap_XMLTriple_clone) {
  {
    XMLTriple *arg1 = (XMLTriple *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLTriple *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLTriple_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLTriple, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLTriple_clone" "', argument " "1"" of type '" "XMLTriple const *""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    result = (XMLTriple *)((XMLTriple const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLTriple, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLTriple_getName) {
  {
    XMLTriple *arg1 = (XMLTriple *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLTriple_getName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLTriple, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLTriple_getName" "', argument " "1"" of type '" "XMLTriple const *""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    result = (std::string *) &((XMLTriple const *)arg1)->getName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLTriple_getPrefix) {
  {
    XMLTriple *arg1 = (XMLTriple *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLTriple_getPrefix(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLTriple, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLTriple_getPrefix" "', argument " "1"" of type '" "XMLTriple const *""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    result = (std::string *) &((XMLTriple const *)arg1)->getPrefix();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLTriple_getURI) {
  {
    XMLTriple *arg1 = (XMLTriple *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLTriple_getURI(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLTriple, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLTriple_getURI" "', argument " "1"" of type '" "XMLTriple const *""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    result = (std::string *) &((XMLTriple const *)arg1)->getURI();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLTriple_getPrefixedName) {
  {
    XMLTriple *arg1 = (XMLTriple *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLTriple_getPrefixedName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLTriple, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLTriple_getPrefixedName" "', argument " "1"" of type '" "XMLTriple const *""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    result = ((XMLTriple const *)arg1)->getPrefixedName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLTriple_isEmpty) {
  {
    XMLTriple *arg1 = (XMLTriple *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLTriple_isEmpty(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLTriple, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLTriple_isEmpty" "', argument " "1"" of type '" "XMLTriple const *""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    result = (bool)((XMLTriple const *)arg1)->isEmpty();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_XMLTriple) {
  {
    XMLTriple *arg1 = (XMLTriple *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_XMLTriple(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLTriple, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_XMLTriple" "', argument " "1"" of type '" "XMLTriple *""'"); 
    }
    arg1 = reinterpret_cast< XMLTriple * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLOutputStream__SWIG_0) {
  {
    std::ostream *arg1 = 0 ;
    std::string *arg2 = 0 ;
    bool arg3 ;
    std::string *arg4 = 0 ;
    std::string *arg5 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    bool val3 ;
    int ecode3 = 0 ;
    int res4 = SWIG_OLDOBJ ;
    int res5 = SWIG_OLDOBJ ;
    int argvi = 0;
    XMLOutputStream *result = 0 ;
    dXSARGS;
    
    if ((items < 5) || (items > 5)) {
      SWIG_croak("Usage: new_XMLOutputStream(stream,encoding,writeXMLDecl,programName,programVersion);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_std__ostream,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLOutputStream" "', argument " "1"" of type '" "std::ostream &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "1"" of type '" "std::ostream &""'"); 
    }
    arg1 = reinterpret_cast< std::ostream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLOutputStream" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLOutputStream" "', argument " "3"" of type '" "bool""'");
    } 
    arg3 = static_cast< bool >(val3);
    {
      std::string *ptr = (std::string *)0;
      res4 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), &ptr);
      if (!SWIG_IsOK(res4)) {
        SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "new_XMLOutputStream" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      arg4 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res5 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(4), &ptr);
      if (!SWIG_IsOK(res5)) {
        SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "new_XMLOutputStream" "', argument " "5"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "5"" of type '" "std::string const &""'"); 
      }
      arg5 = ptr;
    }
    {
      try {
        result = (XMLOutputStream *)new XMLOutputStream(*arg1,(std::string const &)*arg2,arg3,(std::string const &)*arg4,(std::string const &)*arg5);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLOutputStream, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    if (SWIG_IsNewObj(res5)) delete arg5;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    if (SWIG_IsNewObj(res5)) delete arg5;
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLOutputStream__SWIG_1) {
  {
    std::ostream *arg1 = 0 ;
    std::string *arg2 = 0 ;
    bool arg3 ;
    std::string *arg4 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    bool val3 ;
    int ecode3 = 0 ;
    int res4 = SWIG_OLDOBJ ;
    int argvi = 0;
    XMLOutputStream *result = 0 ;
    dXSARGS;
    
    if ((items < 4) || (items > 4)) {
      SWIG_croak("Usage: new_XMLOutputStream(stream,encoding,writeXMLDecl,programName);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_std__ostream,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLOutputStream" "', argument " "1"" of type '" "std::ostream &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "1"" of type '" "std::ostream &""'"); 
    }
    arg1 = reinterpret_cast< std::ostream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLOutputStream" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLOutputStream" "', argument " "3"" of type '" "bool""'");
    } 
    arg3 = static_cast< bool >(val3);
    {
      std::string *ptr = (std::string *)0;
      res4 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), &ptr);
      if (!SWIG_IsOK(res4)) {
        SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "new_XMLOutputStream" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      arg4 = ptr;
    }
    {
      try {
        result = (XMLOutputStream *)new XMLOutputStream(*arg1,(std::string const &)*arg2,arg3,(std::string const &)*arg4);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLOutputStream, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLOutputStream__SWIG_2) {
  {
    std::ostream *arg1 = 0 ;
    std::string *arg2 = 0 ;
    bool arg3 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    bool val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    XMLOutputStream *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_XMLOutputStream(stream,encoding,writeXMLDecl);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_std__ostream,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLOutputStream" "', argument " "1"" of type '" "std::ostream &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "1"" of type '" "std::ostream &""'"); 
    }
    arg1 = reinterpret_cast< std::ostream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLOutputStream" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLOutputStream" "', argument " "3"" of type '" "bool""'");
    } 
    arg3 = static_cast< bool >(val3);
    {
      try {
        result = (XMLOutputStream *)new XMLOutputStream(*arg1,(std::string const &)*arg2,arg3);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLOutputStream, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLOutputStream__SWIG_3) {
  {
    std::ostream *arg1 = 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    XMLOutputStream *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_XMLOutputStream(stream,encoding);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_std__ostream,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLOutputStream" "', argument " "1"" of type '" "std::ostream &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "1"" of type '" "std::ostream &""'"); 
    }
    arg1 = reinterpret_cast< std::ostream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLOutputStream" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      try {
        result = (XMLOutputStream *)new XMLOutputStream(*arg1,(std::string const &)*arg2);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLOutputStream, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLOutputStream__SWIG_4) {
  {
    std::ostream *arg1 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLOutputStream *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLOutputStream(stream);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_std__ostream,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLOutputStream" "', argument " "1"" of type '" "std::ostream &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLOutputStream" "', argument " "1"" of type '" "std::ostream &""'"); 
    }
    arg1 = reinterpret_cast< std::ostream * >(argp1);
    {
      try {
        result = (XMLOutputStream *)new XMLOutputStream(*arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLOutputStream, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLOutputStream) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_std__ostream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_std__ostream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_std__ostream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 4) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_std__ostream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
    if (items == 5) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_std__ostream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(4), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 5;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_5:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLOutputStream__SWIG_4); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLOutputStream__SWIG_3); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLOutputStream__SWIG_2); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLOutputStream__SWIG_1); return;
    case 5:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLOutputStream__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_XMLOutputStream'");
  XSRETURN(0);
}


XS(_wrap_XMLOutputStream_endElement__SWIG_0) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLOutputStream_endElement(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_endElement" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_endElement" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_endElement" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    (arg1)->endElement((std::string const &)*arg2);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_endElement__SWIG_1) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLOutputStream_endElement(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_endElement" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_endElement" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_endElement" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    (arg1)->endElement((XMLTriple const &)*arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_endElement) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_endElement__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_endElement__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLOutputStream_endElement'");
  XSRETURN(0);
}


XS(_wrap_XMLOutputStream_setAutoIndent) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    bool arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    bool val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLOutputStream_setAutoIndent(self,indent);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_setAutoIndent" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    ecode2 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLOutputStream_setAutoIndent" "', argument " "2"" of type '" "bool""'");
    } 
    arg2 = static_cast< bool >(val2);
    (arg1)->setAutoIndent(arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_startElement__SWIG_0) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLOutputStream_startElement(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_startElement" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_startElement" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_startElement" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    (arg1)->startElement((std::string const &)*arg2);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_startElement__SWIG_1) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLOutputStream_startElement(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_startElement" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_startElement" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_startElement" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    (arg1)->startElement((XMLTriple const &)*arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_startElement) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_startElement__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_startElement__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLOutputStream_startElement'");
  XSRETURN(0);
}


XS(_wrap_XMLOutputStream_startEndElement__SWIG_0) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLOutputStream_startEndElement(self,name);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_startEndElement" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_startEndElement" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_startEndElement" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    (arg1)->startEndElement((std::string const &)*arg2);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_startEndElement__SWIG_1) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    XMLTriple *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLOutputStream_startEndElement(self,triple);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_startEndElement" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_startEndElement" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_startEndElement" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    (arg1)->startEndElement((XMLTriple const &)*arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_startEndElement) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_startEndElement__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_startEndElement__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLOutputStream_startEndElement'");
  XSRETURN(0);
}


XS(_wrap_XMLOutputStream_writeAttribute__SWIG_0) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLOutputStream_writeAttribute(self,name,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeAttribute" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    (arg1)->writeAttribute((std::string const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_writeAttribute__SWIG_1) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    XMLTriple *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLOutputStream_writeAttribute(self,triple,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeAttribute" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    (arg1)->writeAttribute((XMLTriple const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = sv_newmortal();
    
    
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_writeAttribute__SWIG_2) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    std::string *arg2 = 0 ;
    bool *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    bool temp3 ;
    bool val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLOutputStream_writeAttribute(self,name,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeAttribute" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "bool""'");
    } 
    temp3 = static_cast< bool >(val3);
    arg3 = &temp3;
    (arg1)->writeAttribute((std::string const &)*arg2,(bool const &)*arg3);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_writeAttribute__SWIG_3) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    XMLTriple *arg2 = 0 ;
    bool *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    bool temp3 ;
    bool val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLOutputStream_writeAttribute(self,triple,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeAttribute" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    ecode3 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "bool""'");
    } 
    temp3 = static_cast< bool >(val3);
    arg3 = &temp3;
    (arg1)->writeAttribute((XMLTriple const &)*arg2,(bool const &)*arg3);
    ST(argvi) = sv_newmortal();
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_writeAttribute__SWIG_4) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    std::string *arg2 = 0 ;
    double *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    double temp3 ;
    double val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLOutputStream_writeAttribute(self,name,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeAttribute" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "double""'");
    } 
    temp3 = static_cast< double >(val3);
    arg3 = &temp3;
    (arg1)->writeAttribute((std::string const &)*arg2,(double const &)*arg3);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_writeAttribute__SWIG_5) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    XMLTriple *arg2 = 0 ;
    double *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    double temp3 ;
    double val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLOutputStream_writeAttribute(self,triple,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeAttribute" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    ecode3 = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "double""'");
    } 
    temp3 = static_cast< double >(val3);
    arg3 = &temp3;
    (arg1)->writeAttribute((XMLTriple const &)*arg2,(double const &)*arg3);
    ST(argvi) = sv_newmortal();
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_writeAttribute__SWIG_6) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    std::string *arg2 = 0 ;
    long *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    long temp3 ;
    long val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLOutputStream_writeAttribute(self,name,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeAttribute" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "long""'");
    } 
    temp3 = static_cast< long >(val3);
    arg3 = &temp3;
    (arg1)->writeAttribute((std::string const &)*arg2,(long const &)*arg3);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_writeAttribute__SWIG_7) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    XMLTriple *arg2 = 0 ;
    long *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    long temp3 ;
    long val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLOutputStream_writeAttribute(self,triple,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeAttribute" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    ecode3 = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "long""'");
    } 
    temp3 = static_cast< long >(val3);
    arg3 = &temp3;
    (arg1)->writeAttribute((XMLTriple const &)*arg2,(long const &)*arg3);
    ST(argvi) = sv_newmortal();
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_writeAttribute__SWIG_8) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    std::string *arg2 = 0 ;
    int *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int temp3 ;
    int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLOutputStream_writeAttribute(self,name,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeAttribute" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "int""'");
    } 
    temp3 = static_cast< int >(val3);
    arg3 = &temp3;
    (arg1)->writeAttribute((std::string const &)*arg2,(int const &)*arg3);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_writeAttribute__SWIG_9) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    XMLTriple *arg2 = 0 ;
    int *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 ;
    int res2 = 0 ;
    int temp3 ;
    int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLOutputStream_writeAttribute(self,triple,value);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeAttribute" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2, SWIGTYPE_p_XMLTriple,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeAttribute" "', argument " "2"" of type '" "XMLTriple const &""'"); 
    }
    arg2 = reinterpret_cast< XMLTriple * >(argp2);
    ecode3 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "XMLOutputStream_writeAttribute" "', argument " "3"" of type '" "int""'");
    } 
    temp3 = static_cast< int >(val3);
    arg3 = &temp3;
    (arg1)->writeAttribute((XMLTriple const &)*arg2,(int const &)*arg3);
    ST(argvi) = sv_newmortal();
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_writeAttribute) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_XMLTriple, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 5;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_5:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 6;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_6:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 7;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_7:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_long SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 8;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_8:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_double SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 9;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_9:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLOutputStream, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 10;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_10:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_writeAttribute__SWIG_3); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_writeAttribute__SWIG_9); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_writeAttribute__SWIG_7); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_writeAttribute__SWIG_5); return;
    case 5:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_writeAttribute__SWIG_1); return;
    case 6:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_writeAttribute__SWIG_2); return;
    case 7:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_writeAttribute__SWIG_8); return;
    case 8:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_writeAttribute__SWIG_6); return;
    case 9:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_writeAttribute__SWIG_4); return;
    case 10:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLOutputStream_writeAttribute__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'XMLOutputStream_writeAttribute'");
  XSRETURN(0);
}


XS(_wrap_XMLOutputStream_writeXMLDecl) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLOutputStream_writeXMLDecl(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeXMLDecl" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    (arg1)->writeXMLDecl();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_writeComment) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    std::string *arg2 = 0 ;
    std::string *arg3 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int res3 = SWIG_OLDOBJ ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: XMLOutputStream_writeComment(self,programName,programVersion);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_writeComment" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "XMLOutputStream_writeComment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeComment" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      std::string *ptr = (std::string *)0;
      res3 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(2), &ptr);
      if (!SWIG_IsOK(res3)) {
        SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "XMLOutputStream_writeComment" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "XMLOutputStream_writeComment" "', argument " "3"" of type '" "std::string const &""'"); 
      }
      arg3 = ptr;
    }
    (arg1)->writeComment((std::string const &)*arg2,(std::string const &)*arg3);
    ST(argvi) = sv_newmortal();
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    if (SWIG_IsNewObj(res3)) delete arg3;
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_downIndent) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLOutputStream_downIndent(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_downIndent" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    (arg1)->downIndent();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLOutputStream_upIndent) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLOutputStream_upIndent(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLOutputStream_upIndent" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    (arg1)->upIndent();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_XMLOutputStream) {
  {
    XMLOutputStream *arg1 = (XMLOutputStream *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_XMLOutputStream(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLOutputStream, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_XMLOutputStream" "', argument " "1"" of type '" "XMLOutputStream *""'"); 
    }
    arg1 = reinterpret_cast< XMLOutputStream * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLError__SWIG_0) {
  {
    int arg1 ;
    std::string *arg2 = 0 ;
    unsigned int arg3 ;
    unsigned int arg4 ;
    unsigned int arg5 ;
    unsigned int arg6 ;
    int val1 ;
    int ecode1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    unsigned int val6 ;
    int ecode6 = 0 ;
    int argvi = 0;
    XMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 6) || (items > 6)) {
      SWIG_croak("Usage: new_XMLError(errorId,details,line,column,severity,category);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_XMLError" "', argument " "1"" of type '" "int""'");
    } 
    arg1 = static_cast< int >(val1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLError" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLError" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLError" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_XMLError" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_XMLError" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    ecode6 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), &val6);
    if (!SWIG_IsOK(ecode6)) {
      SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_XMLError" "', argument " "6"" of type '" "unsigned int""'");
    } 
    arg6 = static_cast< unsigned int >(val6);
    {
      try {
        result = (XMLError *)new XMLError(arg1,(std::string const &)*arg2,arg3,arg4,arg5,arg6);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLError__SWIG_1) {
  {
    int arg1 ;
    std::string *arg2 = 0 ;
    unsigned int arg3 ;
    unsigned int arg4 ;
    unsigned int arg5 ;
    int val1 ;
    int ecode1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    int argvi = 0;
    XMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 5) || (items > 5)) {
      SWIG_croak("Usage: new_XMLError(errorId,details,line,column,severity);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_XMLError" "', argument " "1"" of type '" "int""'");
    } 
    arg1 = static_cast< int >(val1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLError" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLError" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLError" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_XMLError" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_XMLError" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    {
      try {
        result = (XMLError *)new XMLError(arg1,(std::string const &)*arg2,arg3,arg4,arg5);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    
    
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLError__SWIG_2) {
  {
    int arg1 ;
    std::string *arg2 = 0 ;
    unsigned int arg3 ;
    unsigned int arg4 ;
    int val1 ;
    int ecode1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    int argvi = 0;
    XMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 4) || (items > 4)) {
      SWIG_croak("Usage: new_XMLError(errorId,details,line,column);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_XMLError" "', argument " "1"" of type '" "int""'");
    } 
    arg1 = static_cast< int >(val1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLError" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLError" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLError" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_XMLError" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    {
      try {
        result = (XMLError *)new XMLError(arg1,(std::string const &)*arg2,arg3,arg4);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLError__SWIG_3) {
  {
    int arg1 ;
    std::string *arg2 = 0 ;
    unsigned int arg3 ;
    int val1 ;
    int ecode1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    XMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_XMLError(errorId,details,line);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_XMLError" "', argument " "1"" of type '" "int""'");
    } 
    arg1 = static_cast< int >(val1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLError" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLError" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_XMLError" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      try {
        result = (XMLError *)new XMLError(arg1,(std::string const &)*arg2,arg3);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLError__SWIG_4) {
  {
    int arg1 ;
    std::string *arg2 = 0 ;
    int val1 ;
    int ecode1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    XMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_XMLError(errorId,details);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_XMLError" "', argument " "1"" of type '" "int""'");
    } 
    arg1 = static_cast< int >(val1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_XMLError" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLError" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    {
      try {
        result = (XMLError *)new XMLError(arg1,(std::string const &)*arg2);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLError__SWIG_5) {
  {
    int arg1 ;
    int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    XMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLError(errorId);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_XMLError" "', argument " "1"" of type '" "int""'");
    } 
    arg1 = static_cast< int >(val1);
    {
      try {
        result = (XMLError *)new XMLError(arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLError__SWIG_6) {
  {
    int argvi = 0;
    XMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_XMLError();");
    }
    {
      try {
        result = (XMLError *)new XMLError();
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLError__SWIG_7) {
  {
    XMLError *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_XMLError(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLError,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_XMLError" "', argument " "1"" of type '" "XMLError const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_XMLError" "', argument " "1"" of type '" "XMLError const &""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    {
      try {
        result = (XMLError *)new XMLError((XMLError const &)*arg1);
      }
      catch (XMLConstructorException &e){
        croak("%s", e.what());
      }
    }
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_XMLError) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLError, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 5;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_5:
    
    if (items == 4) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 6;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_6:
    
    if (items == 5) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 7;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_7:
    
    if (items == 6) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 8;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_8:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLError__SWIG_6); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLError__SWIG_7); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLError__SWIG_5); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLError__SWIG_4); return;
    case 5:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLError__SWIG_3); return;
    case 6:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLError__SWIG_2); return;
    case 7:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLError__SWIG_1); return;
    case 8:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_XMLError__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_XMLError'");
  XSRETURN(0);
}


XS(_wrap_delete_XMLError) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_XMLError(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_XMLError" "', argument " "1"" of type '" "XMLError *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_getErrorId) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_getErrorId(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_getErrorId" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (unsigned int)((XMLError const *)arg1)->getErrorId();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_getMessage) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_getMessage(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_getMessage" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (std::string *) &((XMLError const *)arg1)->getMessage();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_getShortMessage) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_getShortMessage(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_getShortMessage" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (std::string *) &((XMLError const *)arg1)->getShortMessage();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_getLine) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_getLine(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_getLine" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (unsigned int)((XMLError const *)arg1)->getLine();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_getColumn) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_getColumn(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_getColumn" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (unsigned int)((XMLError const *)arg1)->getColumn();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_getSeverity) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_getSeverity(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_getSeverity" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (unsigned int)((XMLError const *)arg1)->getSeverity();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_getSeverityAsString) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_getSeverityAsString(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_getSeverityAsString" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (std::string *) &((XMLError const *)arg1)->getSeverityAsString();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_getCategory) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_getCategory(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_getCategory" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (unsigned int)((XMLError const *)arg1)->getCategory();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_getCategoryAsString) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_getCategoryAsString(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_getCategoryAsString" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (std::string *) &((XMLError const *)arg1)->getCategoryAsString();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_isInfo) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_isInfo(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_isInfo" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (bool)((XMLError const *)arg1)->isInfo();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_isWarning) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_isWarning(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_isWarning" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (bool)((XMLError const *)arg1)->isWarning();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_isError) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_isError(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_isError" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (bool)((XMLError const *)arg1)->isError();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_isFatal) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_isFatal(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_isFatal" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (bool)((XMLError const *)arg1)->isFatal();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_isInternal) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_isInternal(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_isInternal" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (bool)((XMLError const *)arg1)->isInternal();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_isSystem) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_isSystem(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_isSystem" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (bool)((XMLError const *)arg1)->isSystem();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_isXML) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_isXML(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_isXML" "', argument " "1"" of type '" "XMLError const *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    result = (bool)((XMLError const *)arg1)->isXML();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_setLine) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLError_setLine(self,line);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_setLine" "', argument " "1"" of type '" "XMLError *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLError_setLine" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setLine(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_setColumn) {
  {
    XMLError *arg1 = (XMLError *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLError_setColumn(self,column);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLError, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLError_setColumn" "', argument " "1"" of type '" "XMLError *""'"); 
    }
    arg1 = reinterpret_cast< XMLError * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLError_setColumn" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setColumn(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLError_getStandardMessage) {
  {
    int arg1 ;
    int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLError_getStandardMessage(code);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "XMLError_getStandardMessage" "', argument " "1"" of type '" "int""'");
    } 
    arg1 = static_cast< int >(val1);
    result = XMLError::getStandardMessage(arg1);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLErrorLog_getNumErrors) {
  {
    XMLErrorLog *arg1 = (XMLErrorLog *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLErrorLog_getNumErrors(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLErrorLog, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLErrorLog_getNumErrors" "', argument " "1"" of type '" "XMLErrorLog const *""'"); 
    }
    arg1 = reinterpret_cast< XMLErrorLog * >(argp1);
    result = (unsigned int)((XMLErrorLog const *)arg1)->getNumErrors();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLErrorLog_getError) {
  {
    XMLErrorLog *arg1 = (XMLErrorLog *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    XMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: XMLErrorLog_getError(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLErrorLog, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLErrorLog_getError" "', argument " "1"" of type '" "XMLErrorLog const *""'"); 
    }
    arg1 = reinterpret_cast< XMLErrorLog * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "XMLErrorLog_getError" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (XMLError *)((XMLErrorLog const *)arg1)->getError(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLError, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_XMLErrorLog_clearLog) {
  {
    XMLErrorLog *arg1 = (XMLErrorLog *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: XMLErrorLog_clearLog(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLErrorLog, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLErrorLog_clearLog" "', argument " "1"" of type '" "XMLErrorLog *""'"); 
    }
    arg1 = reinterpret_cast< XMLErrorLog * >(argp1);
    (arg1)->clearLog();
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_XMLErrorLog) {
  {
    XMLErrorLog *arg1 = (XMLErrorLog *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_XMLErrorLog(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLErrorLog, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_XMLErrorLog" "', argument " "1"" of type '" "XMLErrorLog *""'"); 
    }
    arg1 = reinterpret_cast< XMLErrorLog * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLErrorLog_getError) {
  {
    SBMLErrorLog *arg1 = (SBMLErrorLog *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLErrorLog_getError(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLErrorLog, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLErrorLog_getError" "', argument " "1"" of type '" "SBMLErrorLog const *""'"); 
    }
    arg1 = reinterpret_cast< SBMLErrorLog * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBMLErrorLog_getError" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SBMLError *)((SBMLErrorLog const *)arg1)->getError(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_SBMLErrorLog_getNumFailsWithSeverity) {
  {
    SBMLErrorLog *arg1 = (SBMLErrorLog *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: SBMLErrorLog_getNumFailsWithSeverity(self,severity);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLErrorLog, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SBMLErrorLog_getNumFailsWithSeverity" "', argument " "1"" of type '" "SBMLErrorLog *""'"); 
    }
    arg1 = reinterpret_cast< SBMLErrorLog * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SBMLErrorLog_getNumFailsWithSeverity" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (unsigned int)(arg1)->getNumFailsWithSeverity(arg2);
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_delete_SBMLErrorLog) {
  {
    SBMLErrorLog *arg1 = (SBMLErrorLog *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SBMLErrorLog(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLErrorLog, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SBMLErrorLog" "', argument " "1"" of type '" "SBMLErrorLog *""'"); 
    }
    arg1 = reinterpret_cast< SBMLErrorLog * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLError__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    std::string *arg4 = 0 ;
    unsigned int arg5 ;
    unsigned int arg6 ;
    unsigned int arg7 ;
    unsigned int arg8 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int res4 = SWIG_OLDOBJ ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    unsigned int val6 ;
    int ecode6 = 0 ;
    unsigned int val7 ;
    int ecode7 = 0 ;
    unsigned int val8 ;
    int ecode8 = 0 ;
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 8) || (items > 8)) {
      SWIG_croak("Usage: new_SBMLError(errorId,level,version,details,line,column,severity,category);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLError" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_SBMLError" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_SBMLError" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      std::string *ptr = (std::string *)0;
      res4 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), &ptr);
      if (!SWIG_IsOK(res4)) {
        SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "new_SBMLError" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_SBMLError" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      arg4 = ptr;
    }
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_SBMLError" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    ecode6 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), &val6);
    if (!SWIG_IsOK(ecode6)) {
      SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_SBMLError" "', argument " "6"" of type '" "unsigned int""'");
    } 
    arg6 = static_cast< unsigned int >(val6);
    ecode7 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(6), &val7);
    if (!SWIG_IsOK(ecode7)) {
      SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "new_SBMLError" "', argument " "7"" of type '" "unsigned int""'");
    } 
    arg7 = static_cast< unsigned int >(val7);
    ecode8 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(7), &val8);
    if (!SWIG_IsOK(ecode8)) {
      SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_SBMLError" "', argument " "8"" of type '" "unsigned int""'");
    } 
    arg8 = static_cast< unsigned int >(val8);
    result = (SBMLError *)new SBMLError(arg1,arg2,arg3,(std::string const &)*arg4,arg5,arg6,arg7,arg8);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLError__SWIG_1) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    std::string *arg4 = 0 ;
    unsigned int arg5 ;
    unsigned int arg6 ;
    unsigned int arg7 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int res4 = SWIG_OLDOBJ ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    unsigned int val6 ;
    int ecode6 = 0 ;
    unsigned int val7 ;
    int ecode7 = 0 ;
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 7) || (items > 7)) {
      SWIG_croak("Usage: new_SBMLError(errorId,level,version,details,line,column,severity);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLError" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_SBMLError" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_SBMLError" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      std::string *ptr = (std::string *)0;
      res4 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), &ptr);
      if (!SWIG_IsOK(res4)) {
        SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "new_SBMLError" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_SBMLError" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      arg4 = ptr;
    }
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_SBMLError" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    ecode6 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), &val6);
    if (!SWIG_IsOK(ecode6)) {
      SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_SBMLError" "', argument " "6"" of type '" "unsigned int""'");
    } 
    arg6 = static_cast< unsigned int >(val6);
    ecode7 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(6), &val7);
    if (!SWIG_IsOK(ecode7)) {
      SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "new_SBMLError" "', argument " "7"" of type '" "unsigned int""'");
    } 
    arg7 = static_cast< unsigned int >(val7);
    result = (SBMLError *)new SBMLError(arg1,arg2,arg3,(std::string const &)*arg4,arg5,arg6,arg7);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLError__SWIG_2) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    std::string *arg4 = 0 ;
    unsigned int arg5 ;
    unsigned int arg6 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int res4 = SWIG_OLDOBJ ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    unsigned int val6 ;
    int ecode6 = 0 ;
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 6) || (items > 6)) {
      SWIG_croak("Usage: new_SBMLError(errorId,level,version,details,line,column);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLError" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_SBMLError" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_SBMLError" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      std::string *ptr = (std::string *)0;
      res4 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), &ptr);
      if (!SWIG_IsOK(res4)) {
        SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "new_SBMLError" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_SBMLError" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      arg4 = ptr;
    }
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_SBMLError" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    ecode6 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), &val6);
    if (!SWIG_IsOK(ecode6)) {
      SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_SBMLError" "', argument " "6"" of type '" "unsigned int""'");
    } 
    arg6 = static_cast< unsigned int >(val6);
    result = (SBMLError *)new SBMLError(arg1,arg2,arg3,(std::string const &)*arg4,arg5,arg6);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLError__SWIG_3) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    std::string *arg4 = 0 ;
    unsigned int arg5 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int res4 = SWIG_OLDOBJ ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 5) || (items > 5)) {
      SWIG_croak("Usage: new_SBMLError(errorId,level,version,details,line);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLError" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_SBMLError" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_SBMLError" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      std::string *ptr = (std::string *)0;
      res4 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), &ptr);
      if (!SWIG_IsOK(res4)) {
        SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "new_SBMLError" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_SBMLError" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      arg4 = ptr;
    }
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_SBMLError" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    result = (SBMLError *)new SBMLError(arg1,arg2,arg3,(std::string const &)*arg4,arg5);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    
    XSRETURN(argvi);
  fail:
    
    
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLError__SWIG_4) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    std::string *arg4 = 0 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int res4 = SWIG_OLDOBJ ;
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 4) || (items > 4)) {
      SWIG_croak("Usage: new_SBMLError(errorId,level,version,details);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLError" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_SBMLError" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_SBMLError" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    {
      std::string *ptr = (std::string *)0;
      res4 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), &ptr);
      if (!SWIG_IsOK(res4)) {
        SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "new_SBMLError" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_SBMLError" "', argument " "4"" of type '" "std::string const &""'"); 
      }
      arg4 = ptr;
    }
    result = (SBMLError *)new SBMLError(arg1,arg2,arg3,(std::string const &)*arg4);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    XSRETURN(argvi);
  fail:
    
    
    
    if (SWIG_IsNewObj(res4)) delete arg4;
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLError__SWIG_5) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_SBMLError(errorId,level,version);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLError" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_SBMLError" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_SBMLError" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    result = (SBMLError *)new SBMLError(arg1,arg2,arg3);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLError__SWIG_6) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_SBMLError(errorId,level);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLError" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_SBMLError" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (SBMLError *)new SBMLError(arg1,arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLError__SWIG_7) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SBMLError(errorId);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_SBMLError" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (SBMLError *)new SBMLError(arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLError__SWIG_8) {
  {
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_SBMLError();");
    }
    result = (SBMLError *)new SBMLError();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLError__SWIG_9) {
  {
    SBMLError *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    SBMLError *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_SBMLError(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_SBMLError,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_SBMLError" "', argument " "1"" of type '" "SBMLError const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_SBMLError" "', argument " "1"" of type '" "SBMLError const &""'"); 
    }
    arg1 = reinterpret_cast< SBMLError * >(argp1);
    result = (SBMLError *)new SBMLError((SBMLError const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_SBMLError, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_SBMLError) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_SBMLError, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 5;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_5:
    
    if (items == 4) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 6;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_6:
    
    if (items == 5) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 7;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_7:
    
    if (items == 6) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 8;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_8:
    
    if (items == 7) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(6), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 9;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_9:
    
    if (items == 8) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(3), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(6), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(7), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 10;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_10:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLError__SWIG_8); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLError__SWIG_9); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLError__SWIG_7); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLError__SWIG_6); return;
    case 5:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLError__SWIG_5); return;
    case 6:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLError__SWIG_4); return;
    case 7:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLError__SWIG_3); return;
    case 8:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLError__SWIG_2); return;
    case 9:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLError__SWIG_1); return;
    case 10:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_SBMLError__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_SBMLError'");
  XSRETURN(0);
}


XS(_wrap_delete_SBMLError) {
  {
    SBMLError *arg1 = (SBMLError *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_SBMLError(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBMLError, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SBMLError" "', argument " "1"" of type '" "SBMLError *""'"); 
    }
    arg1 = reinterpret_cast< SBMLError * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_CVTerm__SWIG_0) {
  {
    QualifierType_t arg1 ;
    int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    CVTerm *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_CVTerm(type);");
    }
    ecode1 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_CVTerm" "', argument " "1"" of type '" "QualifierType_t""'");
    } 
    arg1 = static_cast< QualifierType_t >(val1);
    result = (CVTerm *)new CVTerm(arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CVTerm, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_CVTerm__SWIG_1) {
  {
    int argvi = 0;
    CVTerm *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_CVTerm();");
    }
    result = (CVTerm *)new CVTerm();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CVTerm, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_CVTerm__SWIG_2) {
  {
    XMLNode arg1 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    CVTerm *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_CVTerm(node);");
    }
    {
      res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLNode,  0 );
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_CVTerm" "', argument " "1"" of type '" "XMLNode const""'"); 
      }  
      if (!argp1) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_CVTerm" "', argument " "1"" of type '" "XMLNode const""'");
      } else {
        arg1 = *(reinterpret_cast< XMLNode * >(argp1));
      }
    }
    result = (CVTerm *)new CVTerm(arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CVTerm, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_CVTerm) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_CVTerm(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_CVTerm" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_CVTerm__SWIG_3) {
  {
    CVTerm *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    CVTerm *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_CVTerm(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_CVTerm,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_CVTerm" "', argument " "1"" of type '" "CVTerm const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_CVTerm" "', argument " "1"" of type '" "CVTerm const &""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    result = (CVTerm *)new CVTerm((CVTerm const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CVTerm, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_CVTerm) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_CVTerm, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_CVTerm__SWIG_1); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_CVTerm__SWIG_2); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_CVTerm__SWIG_3); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_CVTerm__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_CVTerm'");
  XSRETURN(0);
}


XS(_wrap_CVTerm_clone) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    CVTerm *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CVTerm_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_clone" "', argument " "1"" of type '" "CVTerm const *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    result = (CVTerm *)((CVTerm const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_CVTerm, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_getQualifierType) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    QualifierType_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CVTerm_getQualifierType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_getQualifierType" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    result = (QualifierType_t)(arg1)->getQualifierType();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_getModelQualifierType) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ModelQualifierType_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CVTerm_getModelQualifierType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_getModelQualifierType" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    result = (ModelQualifierType_t)(arg1)->getModelQualifierType();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_getBiologicalQualifierType) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    BiolQualifierType_t result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CVTerm_getBiologicalQualifierType(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_getBiologicalQualifierType" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    result = (BiolQualifierType_t)(arg1)->getBiologicalQualifierType();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_getResources__SWIG_0) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLAttributes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CVTerm_getResources(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_getResources" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    result = (XMLAttributes *)(arg1)->getResources();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLAttributes, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_getResources__SWIG_1) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLAttributes *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CVTerm_getResources(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_getResources" "', argument " "1"" of type '" "CVTerm const *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    result = (XMLAttributes *)((CVTerm const *)arg1)->getResources();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLAttributes, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_getResources) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_CVTerm, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_CVTerm, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_CVTerm_getResources__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_CVTerm_getResources__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'CVTerm_getResources'");
  XSRETURN(0);
}


XS(_wrap_CVTerm_getNumResources) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CVTerm_getNumResources(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_getNumResources" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    result = (unsigned int)(arg1)->getNumResources();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_getResourceURI) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    std::string result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CVTerm_getResourceURI(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_getResourceURI" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "CVTerm_getResourceURI" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (arg1)->getResourceURI(arg2);
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_setQualifierType) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    QualifierType_t arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CVTerm_setQualifierType(self,type);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_setQualifierType" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "CVTerm_setQualifierType" "', argument " "2"" of type '" "QualifierType_t""'");
    } 
    arg2 = static_cast< QualifierType_t >(val2);
    result = (int)(arg1)->setQualifierType(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_setModelQualifierType) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    ModelQualifierType_t arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CVTerm_setModelQualifierType(self,type);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_setModelQualifierType" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "CVTerm_setModelQualifierType" "', argument " "2"" of type '" "ModelQualifierType_t""'");
    } 
    arg2 = static_cast< ModelQualifierType_t >(val2);
    result = (int)(arg1)->setModelQualifierType(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_setBiologicalQualifierType) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    BiolQualifierType_t arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CVTerm_setBiologicalQualifierType(self,type);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_setBiologicalQualifierType" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "CVTerm_setBiologicalQualifierType" "', argument " "2"" of type '" "BiolQualifierType_t""'");
    } 
    arg2 = static_cast< BiolQualifierType_t >(val2);
    result = (int)(arg1)->setBiologicalQualifierType(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_addResource) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CVTerm_addResource(self,resource);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_addResource" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "CVTerm_addResource" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "CVTerm_addResource" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->addResource((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_removeResource) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    std::string arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: CVTerm_removeResource(self,resource);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_removeResource" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res) || !ptr) {
        SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "CVTerm_removeResource" "', argument " "2"" of type '" "std::string""'"); 
      }
      arg2 = *ptr;
      if (SWIG_IsNewObj(res)) delete ptr;
    }
    result = (int)(arg1)->removeResource(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_CVTerm_hasRequiredAttributes) {
  {
    CVTerm *arg1 = (CVTerm *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: CVTerm_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_CVTerm, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "CVTerm_hasRequiredAttributes" "', argument " "1"" of type '" "CVTerm *""'"); 
    }
    arg1 = reinterpret_cast< CVTerm * >(argp1);
    result = (bool)(arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_0) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    unsigned int arg4 ;
    unsigned int arg5 ;
    unsigned int arg6 ;
    unsigned int arg7 ;
    unsigned int arg8 ;
    unsigned int arg9 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    unsigned int val6 ;
    int ecode6 = 0 ;
    unsigned int val7 ;
    int ecode7 = 0 ;
    unsigned int val8 ;
    int ecode8 = 0 ;
    unsigned int val9 ;
    int ecode9 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 9) || (items > 9)) {
      SWIG_croak("Usage: new_Date(year,month,day,hour,minute,second,sign,hoursOffset,minutesOffset);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Date" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Date" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_Date" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_Date" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_Date" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    ecode6 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), &val6);
    if (!SWIG_IsOK(ecode6)) {
      SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_Date" "', argument " "6"" of type '" "unsigned int""'");
    } 
    arg6 = static_cast< unsigned int >(val6);
    ecode7 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(6), &val7);
    if (!SWIG_IsOK(ecode7)) {
      SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "new_Date" "', argument " "7"" of type '" "unsigned int""'");
    } 
    arg7 = static_cast< unsigned int >(val7);
    ecode8 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(7), &val8);
    if (!SWIG_IsOK(ecode8)) {
      SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_Date" "', argument " "8"" of type '" "unsigned int""'");
    } 
    arg8 = static_cast< unsigned int >(val8);
    ecode9 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(8), &val9);
    if (!SWIG_IsOK(ecode9)) {
      SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "new_Date" "', argument " "9"" of type '" "unsigned int""'");
    } 
    arg9 = static_cast< unsigned int >(val9);
    result = (Date *)new Date(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_1) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    unsigned int arg4 ;
    unsigned int arg5 ;
    unsigned int arg6 ;
    unsigned int arg7 ;
    unsigned int arg8 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    unsigned int val6 ;
    int ecode6 = 0 ;
    unsigned int val7 ;
    int ecode7 = 0 ;
    unsigned int val8 ;
    int ecode8 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 8) || (items > 8)) {
      SWIG_croak("Usage: new_Date(year,month,day,hour,minute,second,sign,hoursOffset);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Date" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Date" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_Date" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_Date" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_Date" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    ecode6 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), &val6);
    if (!SWIG_IsOK(ecode6)) {
      SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_Date" "', argument " "6"" of type '" "unsigned int""'");
    } 
    arg6 = static_cast< unsigned int >(val6);
    ecode7 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(6), &val7);
    if (!SWIG_IsOK(ecode7)) {
      SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "new_Date" "', argument " "7"" of type '" "unsigned int""'");
    } 
    arg7 = static_cast< unsigned int >(val7);
    ecode8 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(7), &val8);
    if (!SWIG_IsOK(ecode8)) {
      SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_Date" "', argument " "8"" of type '" "unsigned int""'");
    } 
    arg8 = static_cast< unsigned int >(val8);
    result = (Date *)new Date(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_2) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    unsigned int arg4 ;
    unsigned int arg5 ;
    unsigned int arg6 ;
    unsigned int arg7 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    unsigned int val6 ;
    int ecode6 = 0 ;
    unsigned int val7 ;
    int ecode7 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 7) || (items > 7)) {
      SWIG_croak("Usage: new_Date(year,month,day,hour,minute,second,sign);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Date" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Date" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_Date" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_Date" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_Date" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    ecode6 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), &val6);
    if (!SWIG_IsOK(ecode6)) {
      SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_Date" "', argument " "6"" of type '" "unsigned int""'");
    } 
    arg6 = static_cast< unsigned int >(val6);
    ecode7 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(6), &val7);
    if (!SWIG_IsOK(ecode7)) {
      SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "new_Date" "', argument " "7"" of type '" "unsigned int""'");
    } 
    arg7 = static_cast< unsigned int >(val7);
    result = (Date *)new Date(arg1,arg2,arg3,arg4,arg5,arg6,arg7);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_3) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    unsigned int arg4 ;
    unsigned int arg5 ;
    unsigned int arg6 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    unsigned int val6 ;
    int ecode6 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 6) || (items > 6)) {
      SWIG_croak("Usage: new_Date(year,month,day,hour,minute,second);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Date" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Date" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_Date" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_Date" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_Date" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    ecode6 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), &val6);
    if (!SWIG_IsOK(ecode6)) {
      SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_Date" "', argument " "6"" of type '" "unsigned int""'");
    } 
    arg6 = static_cast< unsigned int >(val6);
    result = (Date *)new Date(arg1,arg2,arg3,arg4,arg5,arg6);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_4) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    unsigned int arg4 ;
    unsigned int arg5 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    unsigned int val5 ;
    int ecode5 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 5) || (items > 5)) {
      SWIG_croak("Usage: new_Date(year,month,day,hour,minute);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Date" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Date" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_Date" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_Date" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    ecode5 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), &val5);
    if (!SWIG_IsOK(ecode5)) {
      SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_Date" "', argument " "5"" of type '" "unsigned int""'");
    } 
    arg5 = static_cast< unsigned int >(val5);
    result = (Date *)new Date(arg1,arg2,arg3,arg4,arg5);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_5) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    unsigned int arg4 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    unsigned int val4 ;
    int ecode4 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 4) || (items > 4)) {
      SWIG_croak("Usage: new_Date(year,month,day,hour);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Date" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Date" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_Date" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    ecode4 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), &val4);
    if (!SWIG_IsOK(ecode4)) {
      SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_Date" "', argument " "4"" of type '" "unsigned int""'");
    } 
    arg4 = static_cast< unsigned int >(val4);
    result = (Date *)new Date(arg1,arg2,arg3,arg4);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_6) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int arg3 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    unsigned int val3 ;
    int ecode3 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 3) || (items > 3)) {
      SWIG_croak("Usage: new_Date(year,month,day);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Date" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Date" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    ecode3 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
    if (!SWIG_IsOK(ecode3)) {
      SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_Date" "', argument " "3"" of type '" "unsigned int""'");
    } 
    arg3 = static_cast< unsigned int >(val3);
    result = (Date *)new Date(arg1,arg2,arg3);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    
    XSRETURN(argvi);
  fail:
    
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_7) {
  {
    unsigned int arg1 ;
    unsigned int arg2 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: new_Date(year,month);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Date" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_Date" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Date *)new Date(arg1,arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_8) {
  {
    unsigned int arg1 ;
    unsigned int val1 ;
    int ecode1 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Date(year);");
    }
    ecode1 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
    if (!SWIG_IsOK(ecode1)) {
      SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_Date" "', argument " "1"" of type '" "unsigned int""'");
    } 
    arg1 = static_cast< unsigned int >(val1);
    result = (Date *)new Date(arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_9) {
  {
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_Date();");
    }
    result = (Date *)new Date();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_10) {
  {
    std::string *arg1 = 0 ;
    int res1 = SWIG_OLDOBJ ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Date(date);");
    }
    {
      std::string *ptr = (std::string *)0;
      res1 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), &ptr);
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Date" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Date" "', argument " "1"" of type '" "std::string const &""'"); 
      }
      arg1 = ptr;
    }
    result = (Date *)new Date((std::string const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    if (SWIG_IsNewObj(res1)) delete arg1;
    XSRETURN(argvi);
  fail:
    if (SWIG_IsNewObj(res1)) delete arg1;
    SWIG_croak_null();
  }
}


XS(_wrap_delete_Date) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_Date(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_Date" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date__SWIG_11) {
  {
    Date *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_Date(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_Date,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_Date" "', argument " "1"" of type '" "Date const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_Date" "', argument " "1"" of type '" "Date const &""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (Date *)new Date((Date const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_Date) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_Date, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        int res = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(0), (std::string**)(0));
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_4;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 4;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_4:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_5;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 5;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_5:
    
    if (items == 3) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_6;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 6;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_6:
    
    if (items == 4) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_7;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 7;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_7:
    
    if (items == 5) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_8;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 8;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_8:
    
    if (items == 6) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_9;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 9;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_9:
    
    if (items == 7) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(6), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_10;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 10;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_10:
    
    if (items == 8) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(6), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(7), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_11;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 11;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_11:
    
    if (items == 9) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(3), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(4), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(5), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(6), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(7), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(8), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_12;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 12;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_12:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_9); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_11); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_8); return;
    case 4:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_10); return;
    case 5:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_7); return;
    case 6:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_6); return;
    case 7:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_5); return;
    case 8:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_4); return;
    case 9:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_3); return;
    case 10:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_2); return;
    case 11:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_1); return;
    case 12:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_Date__SWIG_0); return;
    }
  }
  
  croak("No matching function for overloaded 'new_Date'");
  XSRETURN(0);
}


XS(_wrap_Date_clone) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_clone" "', argument " "1"" of type '" "Date const *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (Date *)((Date const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_getYear) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_getYear(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_getYear" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (unsigned int)(arg1)->getYear();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_getMonth) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_getMonth(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_getMonth" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (unsigned int)(arg1)->getMonth();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_getDay) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_getDay(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_getDay" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (unsigned int)(arg1)->getDay();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_getHour) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_getHour(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_getHour" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (unsigned int)(arg1)->getHour();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_getMinute) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_getMinute(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_getMinute" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (unsigned int)(arg1)->getMinute();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_getSecond) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_getSecond(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_getSecond" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (unsigned int)(arg1)->getSecond();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_getSignOffset) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_getSignOffset(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_getSignOffset" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (unsigned int)(arg1)->getSignOffset();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_getHoursOffset) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_getHoursOffset(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_getHoursOffset" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (unsigned int)(arg1)->getHoursOffset();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_getMinutesOffset) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_getMinutesOffset(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_getMinutesOffset" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (unsigned int)(arg1)->getMinutesOffset();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_getDateAsString) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_getDateAsString(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_getDateAsString" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (std::string *) &(arg1)->getDateAsString();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_setYear) {
  {
    Date *arg1 = (Date *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Date_setYear(self,year);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_setYear" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Date_setYear" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setYear(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_setMonth) {
  {
    Date *arg1 = (Date *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Date_setMonth(self,month);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_setMonth" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Date_setMonth" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setMonth(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_setDay) {
  {
    Date *arg1 = (Date *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Date_setDay(self,day);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_setDay" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Date_setDay" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setDay(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_setHour) {
  {
    Date *arg1 = (Date *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Date_setHour(self,hour);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_setHour" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Date_setHour" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setHour(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_setMinute) {
  {
    Date *arg1 = (Date *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Date_setMinute(self,minute);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_setMinute" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Date_setMinute" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setMinute(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_setSecond) {
  {
    Date *arg1 = (Date *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Date_setSecond(self,second);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_setSecond" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Date_setSecond" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setSecond(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_setSignOffset) {
  {
    Date *arg1 = (Date *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Date_setSignOffset(self,sign);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_setSignOffset" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Date_setSignOffset" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setSignOffset(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_setHoursOffset) {
  {
    Date *arg1 = (Date *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Date_setHoursOffset(self,hoursOffset);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_setHoursOffset" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Date_setHoursOffset" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setHoursOffset(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_setMinutesOffset) {
  {
    Date *arg1 = (Date *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Date_setMinutesOffset(self,minutesOffset);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_setMinutesOffset" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "Date_setMinutesOffset" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (int)(arg1)->setMinutesOffset(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_Date_setDateAsString) {
  {
    Date *arg1 = (Date *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: Date_setDateAsString(self,date);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_setDateAsString" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "Date_setDateAsString" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "Date_setDateAsString" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setDateAsString((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_Date_representsValidDate) {
  {
    Date *arg1 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: Date_representsValidDate(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Date_representsValidDate" "', argument " "1"" of type '" "Date *""'"); 
    }
    arg1 = reinterpret_cast< Date * >(argp1);
    result = (bool)(arg1)->representsValidDate();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ModelCreator__SWIG_0) {
  {
    int argvi = 0;
    ModelCreator *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ModelCreator();");
    }
    result = (ModelCreator *)new ModelCreator();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelCreator, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_new_ModelCreator__SWIG_1) {
  {
    XMLNode arg1 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    ModelCreator *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_ModelCreator(creator);");
    }
    {
      res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_XMLNode,  0 );
      if (!SWIG_IsOK(res1)) {
        SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_ModelCreator" "', argument " "1"" of type '" "XMLNode const""'"); 
      }  
      if (!argp1) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_ModelCreator" "', argument " "1"" of type '" "XMLNode const""'");
      } else {
        arg1 = *(reinterpret_cast< XMLNode * >(argp1));
      }
    }
    result = (ModelCreator *)new ModelCreator(arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelCreator, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ModelCreator) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ModelCreator(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ModelCreator" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ModelCreator__SWIG_2) {
  {
    ModelCreator *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    ModelCreator *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_ModelCreator(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_ModelCreator,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_ModelCreator" "', argument " "1"" of type '" "ModelCreator const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_ModelCreator" "', argument " "1"" of type '" "ModelCreator const &""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (ModelCreator *)new ModelCreator((ModelCreator const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelCreator, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ModelCreator) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ModelCreator, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_3;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 3;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_3:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ModelCreator__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ModelCreator__SWIG_1); return;
    case 3:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ModelCreator__SWIG_2); return;
    }
  }
  
  croak("No matching function for overloaded 'new_ModelCreator'");
  XSRETURN(0);
}


XS(_wrap_ModelCreator_clone) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ModelCreator *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_clone" "', argument " "1"" of type '" "ModelCreator const *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (ModelCreator *)((ModelCreator const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelCreator, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_getFamilyName) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_getFamilyName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_getFamilyName" "', argument " "1"" of type '" "ModelCreator const *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (std::string *) &((ModelCreator const *)arg1)->getFamilyName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_getGivenName) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_getGivenName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_getGivenName" "', argument " "1"" of type '" "ModelCreator const *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (std::string *) &((ModelCreator const *)arg1)->getGivenName();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_getEmail) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_getEmail(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_getEmail" "', argument " "1"" of type '" "ModelCreator const *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (std::string *) &((ModelCreator const *)arg1)->getEmail();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_getOrganization) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_getOrganization(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_getOrganization" "', argument " "1"" of type '" "ModelCreator const *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (std::string *) &((ModelCreator const *)arg1)->getOrganization();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_getOrganisation) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    std::string *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_getOrganisation(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_getOrganisation" "', argument " "1"" of type '" "ModelCreator const *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (std::string *) &((ModelCreator const *)arg1)->getOrganisation();
    ST(argvi) = SWIG_From_std_string  SWIG_PERL_CALL_ARGS_1(static_cast< std::string >(*result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_isSetFamilyName) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_isSetFamilyName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_isSetFamilyName" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (bool)(arg1)->isSetFamilyName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_isSetGivenName) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_isSetGivenName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_isSetGivenName" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (bool)(arg1)->isSetGivenName();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_isSetEmail) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_isSetEmail(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_isSetEmail" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (bool)(arg1)->isSetEmail();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_isSetOrganization) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_isSetOrganization(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_isSetOrganization" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (bool)(arg1)->isSetOrganization();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_isSetOrganisation) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_isSetOrganisation(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_isSetOrganisation" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (bool)(arg1)->isSetOrganisation();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_setFamilyName) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelCreator_setFamilyName(self,familyName);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_setFamilyName" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ModelCreator_setFamilyName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ModelCreator_setFamilyName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setFamilyName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_setGivenName) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelCreator_setGivenName(self,givenName);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_setGivenName" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ModelCreator_setGivenName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ModelCreator_setGivenName" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setGivenName((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_setEmail) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelCreator_setEmail(self,email);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_setEmail" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ModelCreator_setEmail" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ModelCreator_setEmail" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setEmail((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_setOrganization) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelCreator_setOrganization(self,organization);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_setOrganization" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ModelCreator_setOrganization" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ModelCreator_setOrganization" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setOrganization((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_setOrganisation) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    std::string *arg2 = 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int res2 = SWIG_OLDOBJ ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelCreator_setOrganisation(self,organization);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_setOrganisation" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    {
      std::string *ptr = (std::string *)0;
      res2 = SWIG_AsPtr_std_string SWIG_PERL_CALL_ARGS_2(ST(1), &ptr);
      if (!SWIG_IsOK(res2)) {
        SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ModelCreator_setOrganisation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      if (!ptr) {
        SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ModelCreator_setOrganisation" "', argument " "2"" of type '" "std::string const &""'"); 
      }
      arg2 = ptr;
    }
    result = (int)(arg1)->setOrganisation((std::string const &)*arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    XSRETURN(argvi);
  fail:
    
    if (SWIG_IsNewObj(res2)) delete arg2;
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_unsetFamilyName) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_unsetFamilyName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_unsetFamilyName" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (int)(arg1)->unsetFamilyName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_unsetGivenName) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_unsetGivenName(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_unsetGivenName" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (int)(arg1)->unsetGivenName();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_unsetEmail) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_unsetEmail(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_unsetEmail" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (int)(arg1)->unsetEmail();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_unsetOrganization) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_unsetOrganization(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_unsetOrganization" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (int)(arg1)->unsetOrganization();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_unsetOrganisation) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_unsetOrganisation(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_unsetOrganisation" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (int)(arg1)->unsetOrganisation();
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelCreator_hasRequiredAttributes) {
  {
    ModelCreator *arg1 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelCreator_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelCreator_hasRequiredAttributes" "', argument " "1"" of type '" "ModelCreator *""'"); 
    }
    arg1 = reinterpret_cast< ModelCreator * >(argp1);
    result = (bool)(arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ModelHistory__SWIG_0) {
  {
    int argvi = 0;
    ModelHistory *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_ModelHistory();");
    }
    result = (ModelHistory *)new ModelHistory();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelHistory, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_ModelHistory) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_ModelHistory(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_ModelHistory" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ModelHistory__SWIG_1) {
  {
    ModelHistory *arg1 = 0 ;
    void *argp1 ;
    int res1 = 0 ;
    int argvi = 0;
    ModelHistory *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: new_ModelHistory(orig);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1, SWIGTYPE_p_ModelHistory,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_ModelHistory" "', argument " "1"" of type '" "ModelHistory const &""'"); 
    }
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_ModelHistory" "', argument " "1"" of type '" "ModelHistory const &""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    result = (ModelHistory *)new ModelHistory((ModelHistory const &)*arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelHistory, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_new_ModelHistory) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 0) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ModelHistory, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ModelHistory__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_new_ModelHistory__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'new_ModelHistory'");
  XSRETURN(0);
}


XS(_wrap_ModelHistory_clone) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ModelHistory *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelHistory_clone(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_clone" "', argument " "1"" of type '" "ModelHistory const *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    result = (ModelHistory *)((ModelHistory const *)arg1)->clone();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelHistory, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_getCreatedDate) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelHistory_getCreatedDate(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_getCreatedDate" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    result = (Date *)(arg1)->getCreatedDate();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_getModifiedDate__SWIG_0) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelHistory_getModifiedDate(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_getModifiedDate" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    result = (Date *)(arg1)->getModifiedDate();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_isSetCreatedDate) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelHistory_isSetCreatedDate(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_isSetCreatedDate" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    result = (bool)(arg1)->isSetCreatedDate();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_isSetModifiedDate) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelHistory_isSetModifiedDate(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_isSetModifiedDate" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    result = (bool)(arg1)->isSetModifiedDate();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_setCreatedDate) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    Date *arg2 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelHistory_setCreatedDate(self,date);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_setCreatedDate" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ModelHistory_setCreatedDate" "', argument " "2"" of type '" "Date *""'"); 
    }
    arg2 = reinterpret_cast< Date * >(argp2);
    result = (int)(arg1)->setCreatedDate(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_setModifiedDate) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    Date *arg2 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelHistory_setModifiedDate(self,date);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_setModifiedDate" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ModelHistory_setModifiedDate" "', argument " "2"" of type '" "Date *""'"); 
    }
    arg2 = reinterpret_cast< Date * >(argp2);
    result = (int)(arg1)->setModifiedDate(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_addModifiedDate) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    Date *arg2 = (Date *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelHistory_addModifiedDate(self,date);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_addModifiedDate" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_Date, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ModelHistory_addModifiedDate" "', argument " "2"" of type '" "Date *""'"); 
    }
    arg2 = reinterpret_cast< Date * >(argp2);
    result = (int)(arg1)->addModifiedDate(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_getListModifiedDates) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    List *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelHistory_getListModifiedDates(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_getListModifiedDates" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    result = (List *)(arg1)->getListModifiedDates();
    {
      ListWrapper<Date> *listw = (result != 0) ? new ListWrapper<Date>(result) : 0;
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(listw), 
        
        SWIGTYPE_p_ListWrapperT_Date_t, 
        
        
        
        SWIG_OWNER | 0);
      argvi++;
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_getModifiedDate__SWIG_1) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    Date *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelHistory_getModifiedDate(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_getModifiedDate" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ModelHistory_getModifiedDate" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (Date *)(arg1)->getModifiedDate(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Date, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_getModifiedDate) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ModelHistory, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_ModelHistory, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        {
          int res = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), NULL);
          _v = SWIG_CheckState(res);
        }
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ModelHistory_getModifiedDate__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_ModelHistory_getModifiedDate__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'ModelHistory_getModifiedDate'");
  XSRETURN(0);
}


XS(_wrap_ModelHistory_getNumModifiedDates) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelHistory_getNumModifiedDates(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_getNumModifiedDates" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    result = (unsigned int)(arg1)->getNumModifiedDates();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_addCreator) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    ModelCreator *arg2 = (ModelCreator *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    int result;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelHistory_addCreator(self,mc);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_addCreator" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ModelCreator, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "ModelHistory_addCreator" "', argument " "2"" of type '" "ModelCreator *""'"); 
    }
    arg2 = reinterpret_cast< ModelCreator * >(argp2);
    result = (int)(arg1)->addCreator(arg2);
    ST(argvi) = SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_getListCreators) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    List *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelHistory_getListCreators(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_getListCreators" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    result = (List *)(arg1)->getListCreators();
    {
      ListWrapper<ModelCreator> *listw = (result != 0) ? new ListWrapper<ModelCreator>(result) : 0;
      ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(listw), 
        
        SWIGTYPE_p_ListWrapperT_ModelCreator_t, 
        
        
        
        SWIG_OWNER | 0);
      argvi++;
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_getCreator) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    unsigned int arg2 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    unsigned int val2 ;
    int ecode2 = 0 ;
    int argvi = 0;
    ModelCreator *result = 0 ;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: ModelHistory_getCreator(self,n);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_getCreator" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
    if (!SWIG_IsOK(ecode2)) {
      SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ModelHistory_getCreator" "', argument " "2"" of type '" "unsigned int""'");
    } 
    arg2 = static_cast< unsigned int >(val2);
    result = (ModelCreator *)(arg1)->getCreator(arg2);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelCreator, 0 | SWIG_SHADOW); argvi++ ;
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_getNumCreators) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    unsigned int result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelHistory_getNumCreators(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_getNumCreators" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    result = (unsigned int)(arg1)->getNumCreators();
    ST(argvi) = SWIG_From_unsigned_SS_int  SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_ModelHistory_hasRequiredAttributes) {
  {
    ModelHistory *arg1 = (ModelHistory *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    bool result;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: ModelHistory_hasRequiredAttributes(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_ModelHistory, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "ModelHistory_hasRequiredAttributes" "', argument " "1"" of type '" "ModelHistory *""'"); 
    }
    arg1 = reinterpret_cast< ModelHistory * >(argp1);
    result = (bool)(arg1)->hasRequiredAttributes();
    {
      ST(argvi) = sv_newmortal();
      sv_setiv(ST(argvi++), (IV) result);
    }
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_RDFAnnotationParser_parseRDFAnnotation__SWIG_0) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    ModelHistory *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: RDFAnnotationParser_parseRDFAnnotation(annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "RDFAnnotationParser_parseRDFAnnotation" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    result = (ModelHistory *)RDFAnnotationParser::parseRDFAnnotation((XMLNode const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_ModelHistory, 0 | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_RDFAnnotationParser_createAnnotation) {
  {
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: RDFAnnotationParser_createAnnotation();");
    }
    result = (XMLNode *)RDFAnnotationParser::createAnnotation();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_RDFAnnotationParser_createRDFAnnotation) {
  {
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: RDFAnnotationParser_createRDFAnnotation();");
    }
    result = (XMLNode *)RDFAnnotationParser::createRDFAnnotation();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_RDFAnnotationParser_deleteRDFAnnotation) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: RDFAnnotationParser_deleteRDFAnnotation(annotation);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "RDFAnnotationParser_deleteRDFAnnotation" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    result = (XMLNode *)RDFAnnotationParser::deleteRDFAnnotation((XMLNode const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_RDFAnnotationParser_createRDFDescription) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: RDFAnnotationParser_createRDFDescription(obj);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "RDFAnnotationParser_createRDFDescription" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (XMLNode *)RDFAnnotationParser::createRDFDescription((SBase const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_RDFAnnotationParser_createCVTerms) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: RDFAnnotationParser_createCVTerms(obj);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "RDFAnnotationParser_createCVTerms" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (XMLNode *)RDFAnnotationParser::createCVTerms((SBase const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_RDFAnnotationParser_parseCVTerms) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: RDFAnnotationParser_parseCVTerms(obj);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "RDFAnnotationParser_parseCVTerms" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (XMLNode *)RDFAnnotationParser::parseCVTerms((SBase const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_RDFAnnotationParser_parseModelHistory) {
  {
    SBase *arg1 = (SBase *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    XMLNode *result = 0 ;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: RDFAnnotationParser_parseModelHistory(obj);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_SBase, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "RDFAnnotationParser_parseModelHistory" "', argument " "1"" of type '" "SBase const *""'"); 
    }
    arg1 = reinterpret_cast< SBase * >(argp1);
    result = (XMLNode *)RDFAnnotationParser::parseModelHistory((SBase const *)arg1);
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_XMLNode, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}


XS(_wrap_RDFAnnotationParser_parseRDFAnnotation__SWIG_1) {
  {
    XMLNode *arg1 = (XMLNode *) 0 ;
    ListWrapper< CVTerm > *arg2 = (ListWrapper< CVTerm > *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    void *argp2 = 0 ;
    int res2 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 2) || (items > 2)) {
      SWIG_croak("Usage: RDFAnnotationParser_parseRDFAnnotation(annotation,CVTerms);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XMLNode, 0 |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "RDFAnnotationParser_parseRDFAnnotation" "', argument " "1"" of type '" "XMLNode const *""'"); 
    }
    arg1 = reinterpret_cast< XMLNode * >(argp1);
    res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_ListWrapperT_CVTerm_t, 0 |  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "RDFAnnotationParser_parseRDFAnnotation" "', argument " "2"" of type '" "ListWrapper< CVTerm > *""'"); 
    }
    arg2 = reinterpret_cast< ListWrapper< CVTerm > * >(argp2);
    RDFAnnotationParser_parseRDFAnnotation__SWIG_1((XMLNode const *)arg1,arg2);
    ST(argvi) = sv_newmortal();
    
    
    XSRETURN(argvi);
  fail:
    
    
    SWIG_croak_null();
  }
}


XS(_wrap_RDFAnnotationParser_parseRDFAnnotation) {
  dXSARGS;
  
  {
    unsigned long _index = 0;
    SWIG_TypeRank _rank = 0; 
    if (items == 1) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_1;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 1;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_1:
    
    if (items == 2) {
      SWIG_TypeRank _ranki = 0;
      SWIG_TypeRank _rankm = 0;
      SWIG_TypeRank _pi = 1;
      int _v = 0;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XMLNode, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(ST(1), &vptr, SWIGTYPE_p_ListWrapperT_CVTerm_t, 0);
        _v = SWIG_CheckState(res);
      }
      if (!_v) goto check_2;
      _ranki += _v*_pi;
      _rankm += _pi;
      _pi *= SWIG_MAXCASTRANK;
      if (!_index || (_ranki < _rank)) {
        _rank = _ranki; _index = 2;
        if (_rank == _rankm) goto dispatch;
      }
    }
  check_2:
    
  dispatch:
    switch(_index) {
    case 1:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_RDFAnnotationParser_parseRDFAnnotation__SWIG_0); return;
    case 2:
      ++PL_markstack_ptr; SWIG_CALLXS(_wrap_RDFAnnotationParser_parseRDFAnnotation__SWIG_1); return;
    }
  }
  
  croak("No matching function for overloaded 'RDFAnnotationParser_parseRDFAnnotation'");
  XSRETURN(0);
}


XS(_wrap_new_RDFAnnotationParser) {
  {
    int argvi = 0;
    RDFAnnotationParser *result = 0 ;
    dXSARGS;
    
    if ((items < 0) || (items > 0)) {
      SWIG_croak("Usage: new_RDFAnnotationParser();");
    }
    result = (RDFAnnotationParser *)new RDFAnnotationParser();
    ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_RDFAnnotationParser, SWIG_OWNER | SWIG_SHADOW); argvi++ ;
    XSRETURN(argvi);
  fail:
    SWIG_croak_null();
  }
}


XS(_wrap_delete_RDFAnnotationParser) {
  {
    RDFAnnotationParser *arg1 = (RDFAnnotationParser *) 0 ;
    void *argp1 = 0 ;
    int res1 = 0 ;
    int argvi = 0;
    dXSARGS;
    
    if ((items < 1) || (items > 1)) {
      SWIG_croak("Usage: delete_RDFAnnotationParser(self);");
    }
    res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_RDFAnnotationParser, SWIG_POINTER_DISOWN |  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_RDFAnnotationParser" "', argument " "1"" of type '" "RDFAnnotationParser *""'"); 
    }
    arg1 = reinterpret_cast< RDFAnnotationParser * >(argp1);
    delete arg1;
    ST(argvi) = sv_newmortal();
    
    XSRETURN(argvi);
  fail:
    
    SWIG_croak_null();
  }
}



/* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */

static void *_p_ConstraintTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Constraint *) x));
}
static void *_p_RateRuleTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (Rule *) ((RateRule *) x));
}
static void *_p_ListOfTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((ListOf *) x));
}
static void *_p_UnitTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Unit *) x));
}
static void *_p_ListOfFunctionDefinitionsTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfFunctionDefinitions *) x));
}
static void *_p_ListOfUnitDefinitionsTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfUnitDefinitions *) x));
}
static void *_p_SimpleSpeciesReferenceTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((SimpleSpeciesReference *) x));
}
static void *_p_SpeciesReferenceTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (SimpleSpeciesReference *) ((SpeciesReference *) x));
}
static void *_p_ModifierSpeciesReferenceTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (SimpleSpeciesReference *) ((ModifierSpeciesReference *) x));
}
static void *_p_InitialAssignmentTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((InitialAssignment *) x));
}
static void *_p_RuleTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Rule *) x));
}
static void *_p_ListOfLocalParametersTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *)(ListOfParameters *) ((ListOfLocalParameters *) x));
}
static void *_p_ListOfParametersTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfParameters *) x));
}
static void *_p_EventAssignmentTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((EventAssignment *) x));
}
static void *_p_AssignmentRuleTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (Rule *) ((AssignmentRule *) x));
}
static void *_p_SBMLDocumentTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((SBMLDocument *) x));
}
static void *_p_FunctionDefinitionTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((FunctionDefinition *) x));
}
static void *_p_UnitDefinitionTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((UnitDefinition *) x));
}
static void *_p_ListOfInitialAssignmentsTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfInitialAssignments *) x));
}
static void *_p_AlgebraicRuleTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (Rule *) ((AlgebraicRule *) x));
}
static void *_p_ListOfEventAssignmentsTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfEventAssignments *) x));
}
static void *_p_ListOfCompartmentTypesTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfCompartmentTypes *) x));
}
static void *_p_EventTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Event *) x));
}
static void *_p_CompartmentTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Compartment *) x));
}
static void *_p_KineticLawTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((KineticLaw *) x));
}
static void *_p_ListOfEventsTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfEvents *) x));
}
static void *_p_StoichiometryMathTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((StoichiometryMath *) x));
}
static void *_p_ModelTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Model *) x));
}
static void *_p_ListOfSpeciesTypesTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfSpeciesTypes *) x));
}
static void *_p_ListOfRulesTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfRules *) x));
}
static void *_p_ListOfSpeciesReferencesTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfSpeciesReferences *) x));
}
static void *_p_ListOfConstraintsTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfConstraints *) x));
}
static void *_p_DelayTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Delay *) x));
}
static void *_p_PriorityTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Priority *) x));
}
static void *_p_CompartmentTypeTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((CompartmentType *) x));
}
static void *_p_ListOfReactionsTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfReactions *) x));
}
static void *_p_LocalParameterTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (Parameter *) ((LocalParameter *) x));
}
static void *_p_ParameterTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Parameter *) x));
}
static void *_p_ListOfSpeciesTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfSpecies *) x));
}
static void *_p_SpeciesTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Species *) x));
}
static void *_p_TriggerTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Trigger *) x));
}
static void *_p_ListOfUnitsTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfUnits *) x));
}
static void *_p_SpeciesTypeTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((SpeciesType *) x));
}
static void *_p_ReactionTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *)  ((Reaction *) x));
}
static void *_p_ListOfCompartmentsTo_p_SBase(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SBase *) (ListOf *) ((ListOfCompartments *) x));
}
static void *_p_AlgebraicRuleTo_p_Rule(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((Rule *)  ((AlgebraicRule *) x));
}
static void *_p_AssignmentRuleTo_p_Rule(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((Rule *)  ((AssignmentRule *) x));
}
static void *_p_RateRuleTo_p_Rule(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((Rule *)  ((RateRule *) x));
}
static void *_p_XMLNodeTo_p_XMLToken(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((XMLToken *)  ((XMLNode *) x));
}
static void *_p_SpeciesReferenceTo_p_SimpleSpeciesReference(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SimpleSpeciesReference *)  ((SpeciesReference *) x));
}
static void *_p_ModifierSpeciesReferenceTo_p_SimpleSpeciesReference(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((SimpleSpeciesReference *)  ((ModifierSpeciesReference *) x));
}
static void *_p_OStringStreamTo_p_OStream(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((OStream *)  ((OStringStream *) x));
}
static void *_p_OFStreamTo_p_OStream(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((OStream *)  ((OFStream *) x));
}
static void *_p_ListOfLocalParametersTo_p_ListOfParameters(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOfParameters *)  ((ListOfLocalParameters *) x));
}
static void *_p_SBMLErrorLogTo_p_XMLErrorLog(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((XMLErrorLog *)  ((SBMLErrorLog *) x));
}
static void *_p_XMLOutputStringStreamTo_p_XMLOutputStream(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((XMLOutputStream *)  ((XMLOutputStringStream *) x));
}
static void *_p_XMLOutputFileStreamTo_p_XMLOutputStream(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((XMLOutputStream *)  ((XMLOutputFileStream *) x));
}
static void *_p_SBMLErrorTo_p_XMLError(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((XMLError *)  ((SBMLError *) x));
}
static void *_p_ListOfReactionsTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfReactions *) x));
}
static void *_p_ListOfLocalParametersTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *) (ListOfParameters *) ((ListOfLocalParameters *) x));
}
static void *_p_ListOfParametersTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfParameters *) x));
}
static void *_p_ListOfRulesTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfRules *) x));
}
static void *_p_ListOfEventsTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfEvents *) x));
}
static void *_p_ListOfCompartmentsTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfCompartments *) x));
}
static void *_p_ListOfCompartmentTypesTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfCompartmentTypes *) x));
}
static void *_p_ListOfUnitDefinitionsTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfUnitDefinitions *) x));
}
static void *_p_ListOfFunctionDefinitionsTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfFunctionDefinitions *) x));
}
static void *_p_ListOfSpeciesTypesTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfSpeciesTypes *) x));
}
static void *_p_ListOfSpeciesReferencesTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfSpeciesReferences *) x));
}
static void *_p_ListOfInitialAssignmentsTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfInitialAssignments *) x));
}
static void *_p_ListOfEventAssignmentsTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfEventAssignments *) x));
}
static void *_p_ListOfConstraintsTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfConstraints *) x));
}
static void *_p_ListOfUnitsTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfUnits *) x));
}
static void *_p_ListOfSpeciesTo_p_ListOf(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((ListOf *)  ((ListOfSpecies *) x));
}
static void *_p_LocalParameterTo_p_Parameter(void *x, int *SWIGUNUSEDPARM(newmemory)) {
    return (void *)((Parameter *)  ((LocalParameter *) x));
}
static swig_type_info _swigt__p_ASTNode = {"_p_ASTNode", "ASTNode *|ASTNode_t *", 0, 0, (void*)"LibSBML::ASTNode", 0};
static swig_type_info _swigt__p_ASTNodeType_t = {"_p_ASTNodeType_t", "enum ASTNodeType_t *|ASTNodeType_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_AlgebraicRule = {"_p_AlgebraicRule", "AlgebraicRule *", 0, 0, (void*)"LibSBML::AlgebraicRule", 0};
static swig_type_info _swigt__p_AssignmentRule = {"_p_AssignmentRule", "AssignmentRule *", 0, 0, (void*)"LibSBML::AssignmentRule", 0};
static swig_type_info _swigt__p_BiolQualifierType_t = {"_p_BiolQualifierType_t", "enum BiolQualifierType_t *|BiolQualifierType_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_CVTerm = {"_p_CVTerm", "CVTerm *|CVTerm_t *", 0, 0, (void*)"LibSBML::CVTerm", 0};
static swig_type_info _swigt__p_Compartment = {"_p_Compartment", "Compartment_t *|Compartment *", 0, 0, (void*)"LibSBML::Compartment", 0};
static swig_type_info _swigt__p_CompartmentType = {"_p_CompartmentType", "CompartmentType *|CompartmentType_t *", 0, 0, (void*)"LibSBML::CompartmentType", 0};
static swig_type_info _swigt__p_Constraint = {"_p_Constraint", "Constraint_t *|Constraint *", 0, 0, (void*)"LibSBML::Constraint", 0};
static swig_type_info _swigt__p_Date = {"_p_Date", "Date *|Date_t *", 0, 0, (void*)"LibSBML::Date", 0};
static swig_type_info _swigt__p_Delay = {"_p_Delay", "Delay *|Delay_t *", 0, 0, (void*)"LibSBML::Delay", 0};
static swig_type_info _swigt__p_Event = {"_p_Event", "Event *|Event_t *", 0, 0, (void*)"LibSBML::Event", 0};
static swig_type_info _swigt__p_EventAssignment = {"_p_EventAssignment", "EventAssignment_t *|EventAssignment *", 0, 0, (void*)"LibSBML::EventAssignment", 0};
static swig_type_info _swigt__p_FunctionDefinition = {"_p_FunctionDefinition", "FunctionDefinition_t *|FunctionDefinition *", 0, 0, (void*)"LibSBML::FunctionDefinition", 0};
static swig_type_info _swigt__p_InitialAssignment = {"_p_InitialAssignment", "InitialAssignment_t *|InitialAssignment *", 0, 0, (void*)"LibSBML::InitialAssignment", 0};
static swig_type_info _swigt__p_KineticLaw = {"_p_KineticLaw", "KineticLaw *|KineticLaw_t *", 0, 0, (void*)"LibSBML::KineticLaw", 0};
static swig_type_info _swigt__p_List = {"_p_List", "List *|List_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_ListOf = {"_p_ListOf", "ListOf *|ListOf_t *", 0, 0, (void*)"LibSBML::ListOf", 0};
static swig_type_info _swigt__p_ListOfCompartmentTypes = {"_p_ListOfCompartmentTypes", "ListOfCompartmentTypes *", 0, 0, (void*)"LibSBML::ListOfCompartmentTypes", 0};
static swig_type_info _swigt__p_ListOfCompartments = {"_p_ListOfCompartments", "ListOfCompartments *", 0, 0, (void*)"LibSBML::ListOfCompartments", 0};
static swig_type_info _swigt__p_ListOfConstraints = {"_p_ListOfConstraints", "ListOfConstraints *", 0, 0, (void*)"LibSBML::ListOfConstraints", 0};
static swig_type_info _swigt__p_ListOfEventAssignments = {"_p_ListOfEventAssignments", "ListOfEventAssignments *", 0, 0, (void*)"LibSBML::ListOfEventAssignments", 0};
static swig_type_info _swigt__p_ListOfEvents = {"_p_ListOfEvents", "ListOfEvents *", 0, 0, (void*)"LibSBML::ListOfEvents", 0};
static swig_type_info _swigt__p_ListOfFunctionDefinitions = {"_p_ListOfFunctionDefinitions", "ListOfFunctionDefinitions *", 0, 0, (void*)"LibSBML::ListOfFunctionDefinitions", 0};
static swig_type_info _swigt__p_ListOfInitialAssignments = {"_p_ListOfInitialAssignments", "ListOfInitialAssignments *", 0, 0, (void*)"LibSBML::ListOfInitialAssignments", 0};
static swig_type_info _swigt__p_ListOfLocalParameters = {"_p_ListOfLocalParameters", "ListOfLocalParameters *", 0, 0, (void*)"LibSBML::ListOfLocalParameters", 0};
static swig_type_info _swigt__p_ListOfParameters = {"_p_ListOfParameters", "ListOfParameters *", 0, 0, (void*)"LibSBML::ListOfParameters", 0};
static swig_type_info _swigt__p_ListOfReactions = {"_p_ListOfReactions", "ListOfReactions *", 0, 0, (void*)"LibSBML::ListOfReactions", 0};
static swig_type_info _swigt__p_ListOfRules = {"_p_ListOfRules", "ListOfRules *", 0, 0, (void*)"LibSBML::ListOfRules", 0};
static swig_type_info _swigt__p_ListOfSpecies = {"_p_ListOfSpecies", "ListOfSpecies *", 0, 0, (void*)"LibSBML::ListOfSpecies", 0};
static swig_type_info _swigt__p_ListOfSpeciesReferences = {"_p_ListOfSpeciesReferences", "ListOfSpeciesReferences *", 0, 0, (void*)"LibSBML::ListOfSpeciesReferences", 0};
static swig_type_info _swigt__p_ListOfSpeciesTypes = {"_p_ListOfSpeciesTypes", "ListOfSpeciesTypes *", 0, 0, (void*)"LibSBML::ListOfSpeciesTypes", 0};
static swig_type_info _swigt__p_ListOfUnitDefinitions = {"_p_ListOfUnitDefinitions", "ListOfUnitDefinitions *", 0, 0, (void*)"LibSBML::ListOfUnitDefinitions", 0};
static swig_type_info _swigt__p_ListOfUnits = {"_p_ListOfUnits", "ListOfUnits *", 0, 0, (void*)"LibSBML::ListOfUnits", 0};
static swig_type_info _swigt__p_ListWrapperT_ASTNode_t = {"_p_ListWrapperT_ASTNode_t", "ListWrapper< ASTNode > *", 0, 0, (void*)"LibSBML::ASTNodeList", 0};
static swig_type_info _swigt__p_ListWrapperT_CVTerm_t = {"_p_ListWrapperT_CVTerm_t", "ListWrapper< CVTerm > *", 0, 0, (void*)"LibSBML::CVTermList", 0};
static swig_type_info _swigt__p_ListWrapperT_Date_t = {"_p_ListWrapperT_Date_t", "ListWrapper< Date > *", 0, 0, (void*)"LibSBML::DateList", 0};
static swig_type_info _swigt__p_ListWrapperT_ModelCreator_t = {"_p_ListWrapperT_ModelCreator_t", "ListWrapper< ModelCreator > *", 0, 0, (void*)"LibSBML::ModelCreatorList", 0};
static swig_type_info _swigt__p_ListWrapperT_SBMLNamespaces_t = {"_p_ListWrapperT_SBMLNamespaces_t", "ListWrapper< SBMLNamespaces > *", 0, 0, (void*)"LibSBML::SBMLNamespacesList", 0};
static swig_type_info _swigt__p_LocalParameter = {"_p_LocalParameter", "LocalParameter *|LocalParameter_t *", 0, 0, (void*)"LibSBML::LocalParameter", 0};
static swig_type_info _swigt__p_Model = {"_p_Model", "Model *|Model_t *", 0, 0, (void*)"LibSBML::Model", 0};
static swig_type_info _swigt__p_ModelCreator = {"_p_ModelCreator", "ModelCreator *|ModelCreator_t *", 0, 0, (void*)"LibSBML::ModelCreator", 0};
static swig_type_info _swigt__p_ModelHistory = {"_p_ModelHistory", "ModelHistory *|ModelHistory_t *", 0, 0, (void*)"LibSBML::ModelHistory", 0};
static swig_type_info _swigt__p_ModelQualifierType_t = {"_p_ModelQualifierType_t", "enum ModelQualifierType_t *|ModelQualifierType_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_ModifierSpeciesReference = {"_p_ModifierSpeciesReference", "ModifierSpeciesReference *", 0, 0, (void*)"LibSBML::ModifierSpeciesReference", 0};
static swig_type_info _swigt__p_OFStream = {"_p_OFStream", "OFStream *", 0, 0, (void*)"LibSBML::OFStream", 0};
static swig_type_info _swigt__p_OStream = {"_p_OStream", "OStream *", 0, 0, (void*)"LibSBML::OStream", 0};
static swig_type_info _swigt__p_OStringStream = {"_p_OStringStream", "OStringStream *", 0, 0, (void*)"LibSBML::OStringStream", 0};
static swig_type_info _swigt__p_OperationReturnValues_t = {"_p_OperationReturnValues_t", "enum OperationReturnValues_t *|OperationReturnValues_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_Parameter = {"_p_Parameter", "Parameter *|Parameter_t *", 0, 0, (void*)"LibSBML::Parameter", 0};
static swig_type_info _swigt__p_ParentMap__iterator = {"_p_ParentMap__iterator", "ParentIter *|ParentMap::iterator *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_Priority = {"_p_Priority", "Priority *|Priority_t *", 0, 0, (void*)"LibSBML::Priority", 0};
static swig_type_info _swigt__p_QualifierType_t = {"_p_QualifierType_t", "enum QualifierType_t *|QualifierType_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_RDFAnnotationParser = {"_p_RDFAnnotationParser", "RDFAnnotationParser *", 0, 0, (void*)"LibSBML::RDFAnnotationParser", 0};
static swig_type_info _swigt__p_RateRule = {"_p_RateRule", "RateRule *", 0, 0, (void*)"LibSBML::RateRule", 0};
static swig_type_info _swigt__p_Reaction = {"_p_Reaction", "Reaction_t *|Reaction *", 0, 0, (void*)"LibSBML::Reaction", 0};
static swig_type_info _swigt__p_Rule = {"_p_Rule", "Rule_t *|Rule *", 0, 0, (void*)"LibSBML::Rule", 0};
static swig_type_info _swigt__p_RuleType_t = {"_p_RuleType_t", "enum RuleType_t *|RuleType_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_SBMLConstructorException = {"_p_SBMLConstructorException", "SBMLConstructorException *", 0, 0, (void*)"LibSBML::SBMLConstructorException", 0};
static swig_type_info _swigt__p_SBMLDocument = {"_p_SBMLDocument", "SBMLDocument_t *|SBMLDocument *", 0, 0, (void*)"LibSBML::SBMLDocument", 0};
static swig_type_info _swigt__p_SBMLError = {"_p_SBMLError", "SBMLError *|SBMLError_t *", 0, 0, (void*)"LibSBML::SBMLError", 0};
static swig_type_info _swigt__p_SBMLErrorCategory_t = {"_p_SBMLErrorCategory_t", "enum SBMLErrorCategory_t *|SBMLErrorCategory_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_SBMLErrorCode_t = {"_p_SBMLErrorCode_t", "enum SBMLErrorCode_t *|SBMLErrorCode_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_SBMLErrorLog = {"_p_SBMLErrorLog", "SBMLErrorLog *", 0, 0, (void*)"LibSBML::SBMLErrorLog", 0};
static swig_type_info _swigt__p_SBMLErrorSeverity_t = {"_p_SBMLErrorSeverity_t", "enum SBMLErrorSeverity_t *|SBMLErrorSeverity_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_SBMLNamespaces = {"_p_SBMLNamespaces", "SBMLNamespaces_t *|SBMLNamespaces *", 0, 0, (void*)"LibSBML::SBMLNamespaces", 0};
static swig_type_info _swigt__p_SBMLReader = {"_p_SBMLReader", "SBMLReader *|SBMLReader_t *", 0, 0, (void*)"LibSBML::SBMLReader", 0};
static swig_type_info _swigt__p_SBMLTransforms = {"_p_SBMLTransforms", "SBMLTransforms *", 0, 0, (void*)"LibSBML::SBMLTransforms", 0};
static swig_type_info _swigt__p_SBMLTypeCode_t = {"_p_SBMLTypeCode_t", "enum SBMLTypeCode_t *|SBMLTypeCode_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_SBMLWriter = {"_p_SBMLWriter", "SBMLWriter *|SBMLWriter_t *", 0, 0, (void*)"LibSBML::SBMLWriter", 0};
static swig_type_info _swigt__p_SBO = {"_p_SBO", "SBO *", 0, 0, (void*)"LibSBML::SBO", 0};
static swig_type_info _swigt__p_SBase = {"_p_SBase", "SBase_t *|SBase *", 0, 0, (void*)"LibSBML::SBase", 0};
static swig_type_info _swigt__p_SimpleSpeciesReference = {"_p_SimpleSpeciesReference", "SimpleSpeciesReference *|SpeciesReference_t *", 0, 0, (void*)"LibSBML::SimpleSpeciesReference", 0};
static swig_type_info _swigt__p_Species = {"_p_Species", "Species_t *|Species *", 0, 0, (void*)"LibSBML::Species", 0};
static swig_type_info _swigt__p_SpeciesReference = {"_p_SpeciesReference", "SpeciesReference *", 0, 0, (void*)"LibSBML::SpeciesReference", 0};
static swig_type_info _swigt__p_SpeciesType = {"_p_SpeciesType", "SpeciesType *|SpeciesType_t *", 0, 0, (void*)"LibSBML::SpeciesType", 0};
static swig_type_info _swigt__p_StoichiometryMath = {"_p_StoichiometryMath", "StoichiometryMath_t *|StoichiometryMath *", 0, 0, (void*)"LibSBML::StoichiometryMath", 0};
static swig_type_info _swigt__p_SyntaxChecker = {"_p_SyntaxChecker", "SyntaxChecker *", 0, 0, (void*)"LibSBML::SyntaxChecker", 0};
static swig_type_info _swigt__p_Trigger = {"_p_Trigger", "Trigger *|Trigger_t *", 0, 0, (void*)"LibSBML::Trigger", 0};
static swig_type_info _swigt__p_Unit = {"_p_Unit", "Unit_t *|Unit *", 0, 0, (void*)"LibSBML::Unit", 0};
static swig_type_info _swigt__p_UnitDefinition = {"_p_UnitDefinition", "UnitDefinition_t *|UnitDefinition *", 0, 0, (void*)"LibSBML::UnitDefinition", 0};
static swig_type_info _swigt__p_UnitKind_t = {"_p_UnitKind_t", "enum UnitKind_t *|UnitKind_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_XMLAttributes = {"_p_XMLAttributes", "XMLAttributes *|XMLAttributes_t *", 0, 0, (void*)"LibSBML::XMLAttributes", 0};
static swig_type_info _swigt__p_XMLConstructorException = {"_p_XMLConstructorException", "XMLConstructorException *", 0, 0, (void*)"LibSBML::XMLConstructorException", 0};
static swig_type_info _swigt__p_XMLError = {"_p_XMLError", "XMLError *|XMLError_t *", 0, 0, (void*)"LibSBML::XMLError", 0};
static swig_type_info _swigt__p_XMLErrorCategory_t = {"_p_XMLErrorCategory_t", "enum XMLErrorCategory_t *|XMLErrorCategory_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_XMLErrorCode_t = {"_p_XMLErrorCode_t", "enum XMLErrorCode_t *|XMLErrorCode_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_XMLErrorLog = {"_p_XMLErrorLog", "XMLErrorLog *|XMLErrorLog_t *", 0, 0, (void*)"LibSBML::XMLErrorLog", 0};
static swig_type_info _swigt__p_XMLErrorSeverity_t = {"_p_XMLErrorSeverity_t", "enum XMLErrorSeverity_t *|XMLErrorSeverity_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_XMLInputStream = {"_p_XMLInputStream", "XMLInputStream *|XMLInputStream_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_XMLNamespaces = {"_p_XMLNamespaces", "XMLNamespaces_t *|XMLNamespaces *", 0, 0, (void*)"LibSBML::XMLNamespaces", 0};
static swig_type_info _swigt__p_XMLNode = {"_p_XMLNode", "XMLNode *|XMLNode_t *", 0, 0, (void*)"LibSBML::XMLNode", 0};
static swig_type_info _swigt__p_XMLOutputStream = {"_p_XMLOutputStream", "XMLOutputStream *|XMLOutputStream_t *", 0, 0, (void*)"LibSBML::XMLOutputStream", 0};
static swig_type_info _swigt__p_XMLOutputStringStream = {"_p_XMLOutputStringStream", 0, 0, 0, 0, 0};
static swig_type_info _swigt__p_XMLOutputFileStream = {"_p_XMLOutputFileStream", 0, 0, 0, 0, 0};
static swig_type_info _swigt__p_XMLToken = {"_p_XMLToken", "XMLToken_t *|XMLToken *", 0, 0, (void*)"LibSBML::XMLToken", 0};
static swig_type_info _swigt__p_XMLTriple = {"_p_XMLTriple", "XMLTriple *|XMLTriple_t *", 0, 0, (void*)"LibSBML::XMLTriple", 0};
static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__multimapT_int_int_t = {"_p_std__multimapT_int_int_t", "ParentMap *|std::multimap< int,int > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__ostream = {"_p_std__ostream", "std::ostream *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__pairT_ParentMap__iterator_ParentMap__iterator_t = {"_p_std__pairT_ParentMap__iterator_ParentMap__iterator_t", "ParentRange *|std::pair< ParentMap::iterator,ParentMap::iterator > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__pairT_std__string_bool_t = {"_p_std__pairT_std__string_bool_t", "PackageReqd *|std::pair< std::string,bool > *", 0, 0, (void*)0, 0};

static swig_type_info *swig_type_initial[] = {
  &_swigt__p_ASTNode,
  &_swigt__p_ASTNodeType_t,
  &_swigt__p_AlgebraicRule,
  &_swigt__p_AssignmentRule,
  &_swigt__p_BiolQualifierType_t,
  &_swigt__p_CVTerm,
  &_swigt__p_Compartment,
  &_swigt__p_CompartmentType,
  &_swigt__p_Constraint,
  &_swigt__p_Date,
  &_swigt__p_Delay,
  &_swigt__p_Event,
  &_swigt__p_EventAssignment,
  &_swigt__p_FunctionDefinition,
  &_swigt__p_InitialAssignment,
  &_swigt__p_KineticLaw,
  &_swigt__p_List,
  &_swigt__p_ListOf,
  &_swigt__p_ListOfCompartmentTypes,
  &_swigt__p_ListOfCompartments,
  &_swigt__p_ListOfConstraints,
  &_swigt__p_ListOfEventAssignments,
  &_swigt__p_ListOfEvents,
  &_swigt__p_ListOfFunctionDefinitions,
  &_swigt__p_ListOfInitialAssignments,
  &_swigt__p_ListOfLocalParameters,
  &_swigt__p_ListOfParameters,
  &_swigt__p_ListOfReactions,
  &_swigt__p_ListOfRules,
  &_swigt__p_ListOfSpecies,
  &_swigt__p_ListOfSpeciesReferences,
  &_swigt__p_ListOfSpeciesTypes,
  &_swigt__p_ListOfUnitDefinitions,
  &_swigt__p_ListOfUnits,
  &_swigt__p_ListWrapperT_ASTNode_t,
  &_swigt__p_ListWrapperT_CVTerm_t,
  &_swigt__p_ListWrapperT_Date_t,
  &_swigt__p_ListWrapperT_ModelCreator_t,
  &_swigt__p_ListWrapperT_SBMLNamespaces_t,
  &_swigt__p_LocalParameter,
  &_swigt__p_Model,
  &_swigt__p_ModelCreator,
  &_swigt__p_ModelHistory,
  &_swigt__p_ModelQualifierType_t,
  &_swigt__p_ModifierSpeciesReference,
  &_swigt__p_OFStream,
  &_swigt__p_OStream,
  &_swigt__p_OStringStream,
  &_swigt__p_OperationReturnValues_t,
  &_swigt__p_Parameter,
  &_swigt__p_ParentMap__iterator,
  &_swigt__p_Priority,
  &_swigt__p_QualifierType_t,
  &_swigt__p_RDFAnnotationParser,
  &_swigt__p_RateRule,
  &_swigt__p_Reaction,
  &_swigt__p_Rule,
  &_swigt__p_RuleType_t,
  &_swigt__p_SBMLConstructorException,
  &_swigt__p_SBMLDocument,
  &_swigt__p_SBMLError,
  &_swigt__p_SBMLErrorCategory_t,
  &_swigt__p_SBMLErrorCode_t,
  &_swigt__p_SBMLErrorLog,
  &_swigt__p_SBMLErrorSeverity_t,
  &_swigt__p_SBMLNamespaces,
  &_swigt__p_SBMLReader,
  &_swigt__p_SBMLTransforms,
  &_swigt__p_SBMLTypeCode_t,
  &_swigt__p_SBMLWriter,
  &_swigt__p_SBO,
  &_swigt__p_SBase,
  &_swigt__p_SimpleSpeciesReference,
  &_swigt__p_Species,
  &_swigt__p_SpeciesReference,
  &_swigt__p_SpeciesType,
  &_swigt__p_StoichiometryMath,
  &_swigt__p_SyntaxChecker,
  &_swigt__p_Trigger,
  &_swigt__p_Unit,
  &_swigt__p_UnitDefinition,
  &_swigt__p_UnitKind_t,
  &_swigt__p_XMLAttributes,
  &_swigt__p_XMLConstructorException,
  &_swigt__p_XMLError,
  &_swigt__p_XMLErrorCategory_t,
  &_swigt__p_XMLErrorCode_t,
  &_swigt__p_XMLErrorLog,
  &_swigt__p_XMLErrorSeverity_t,
  &_swigt__p_XMLInputStream,
  &_swigt__p_XMLNamespaces,
  &_swigt__p_XMLNode,
  &_swigt__p_XMLOutputFileStream,
  &_swigt__p_XMLOutputStream,
  &_swigt__p_XMLOutputStringStream,
  &_swigt__p_XMLToken,
  &_swigt__p_XMLTriple,
  &_swigt__p_char,
  &_swigt__p_std__multimapT_int_int_t,
  &_swigt__p_std__ostream,
  &_swigt__p_std__pairT_ParentMap__iterator_ParentMap__iterator_t,
  &_swigt__p_std__pairT_std__string_bool_t,
};

static swig_cast_info _swigc__p_ASTNode[] = {  {&_swigt__p_ASTNode, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ASTNodeType_t[] = {  {&_swigt__p_ASTNodeType_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_AlgebraicRule[] = {  {&_swigt__p_AlgebraicRule, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_AssignmentRule[] = {  {&_swigt__p_AssignmentRule, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_BiolQualifierType_t[] = {  {&_swigt__p_BiolQualifierType_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_CVTerm[] = {  {&_swigt__p_CVTerm, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Compartment[] = {  {&_swigt__p_Compartment, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_CompartmentType[] = {  {&_swigt__p_CompartmentType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Constraint[] = {  {&_swigt__p_Constraint, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Date[] = {  {&_swigt__p_Date, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Delay[] = {  {&_swigt__p_Delay, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Event[] = {  {&_swigt__p_Event, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_EventAssignment[] = {  {&_swigt__p_EventAssignment, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_FunctionDefinition[] = {  {&_swigt__p_FunctionDefinition, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_InitialAssignment[] = {  {&_swigt__p_InitialAssignment, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_KineticLaw[] = {  {&_swigt__p_KineticLaw, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_List[] = {  {&_swigt__p_List, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOf[] = {  {&_swigt__p_ListOfReactions, _p_ListOfReactionsTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfLocalParameters, _p_ListOfLocalParametersTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfParameters, _p_ListOfParametersTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfEvents, _p_ListOfEventsTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfRules, _p_ListOfRulesTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfCompartments, _p_ListOfCompartmentsTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfCompartmentTypes, _p_ListOfCompartmentTypesTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfUnitDefinitions, _p_ListOfUnitDefinitionsTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfFunctionDefinitions, _p_ListOfFunctionDefinitionsTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfSpeciesTypes, _p_ListOfSpeciesTypesTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfSpeciesReferences, _p_ListOfSpeciesReferencesTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfInitialAssignments, _p_ListOfInitialAssignmentsTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfEventAssignments, _p_ListOfEventAssignmentsTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfConstraints, _p_ListOfConstraintsTo_p_ListOf, 0, 0},  {&_swigt__p_ListOfUnits, _p_ListOfUnitsTo_p_ListOf, 0, 0},  {&_swigt__p_ListOf, 0, 0, 0},  {&_swigt__p_ListOfSpecies, _p_ListOfSpeciesTo_p_ListOf, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfCompartmentTypes[] = {  {&_swigt__p_ListOfCompartmentTypes, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfCompartments[] = {  {&_swigt__p_ListOfCompartments, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfConstraints[] = {  {&_swigt__p_ListOfConstraints, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfEventAssignments[] = {  {&_swigt__p_ListOfEventAssignments, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfEvents[] = {  {&_swigt__p_ListOfEvents, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfFunctionDefinitions[] = {  {&_swigt__p_ListOfFunctionDefinitions, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfInitialAssignments[] = {  {&_swigt__p_ListOfInitialAssignments, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfLocalParameters[] = {  {&_swigt__p_ListOfLocalParameters, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfParameters[] = {  {&_swigt__p_ListOfParameters, 0, 0, 0},  {&_swigt__p_ListOfLocalParameters, _p_ListOfLocalParametersTo_p_ListOfParameters, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfReactions[] = {  {&_swigt__p_ListOfReactions, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfRules[] = {  {&_swigt__p_ListOfRules, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfSpecies[] = {  {&_swigt__p_ListOfSpecies, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfSpeciesReferences[] = {  {&_swigt__p_ListOfSpeciesReferences, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfSpeciesTypes[] = {  {&_swigt__p_ListOfSpeciesTypes, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfUnitDefinitions[] = {  {&_swigt__p_ListOfUnitDefinitions, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListOfUnits[] = {  {&_swigt__p_ListOfUnits, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListWrapperT_ASTNode_t[] = {  {&_swigt__p_ListWrapperT_ASTNode_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListWrapperT_CVTerm_t[] = {  {&_swigt__p_ListWrapperT_CVTerm_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListWrapperT_Date_t[] = {  {&_swigt__p_ListWrapperT_Date_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListWrapperT_ModelCreator_t[] = {  {&_swigt__p_ListWrapperT_ModelCreator_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ListWrapperT_SBMLNamespaces_t[] = {  {&_swigt__p_ListWrapperT_SBMLNamespaces_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_LocalParameter[] = {  {&_swigt__p_LocalParameter, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Model[] = {  {&_swigt__p_Model, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ModelCreator[] = {  {&_swigt__p_ModelCreator, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ModelHistory[] = {  {&_swigt__p_ModelHistory, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ModelQualifierType_t[] = {  {&_swigt__p_ModelQualifierType_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ModifierSpeciesReference[] = {  {&_swigt__p_ModifierSpeciesReference, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OFStream[] = {  {&_swigt__p_OFStream, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OStream[] = {  {&_swigt__p_OStream, 0, 0, 0},  {&_swigt__p_OStringStream, _p_OStringStreamTo_p_OStream, 0, 0},  {&_swigt__p_OFStream, _p_OFStreamTo_p_OStream, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OStringStream[] = {  {&_swigt__p_OStringStream, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OperationReturnValues_t[] = {  {&_swigt__p_OperationReturnValues_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Parameter[] = {  {&_swigt__p_Parameter, 0, 0, 0},  {&_swigt__p_LocalParameter, _p_LocalParameterTo_p_Parameter, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_ParentMap__iterator[] = {  {&_swigt__p_ParentMap__iterator, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Priority[] = {  {&_swigt__p_Priority, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QualifierType_t[] = {  {&_swigt__p_QualifierType_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_RDFAnnotationParser[] = {  {&_swigt__p_RDFAnnotationParser, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_RateRule[] = {  {&_swigt__p_RateRule, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Reaction[] = {  {&_swigt__p_Reaction, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Rule[] = {  {&_swigt__p_Rule, 0, 0, 0},  {&_swigt__p_AlgebraicRule, _p_AlgebraicRuleTo_p_Rule, 0, 0},  {&_swigt__p_AssignmentRule, _p_AssignmentRuleTo_p_Rule, 0, 0},  {&_swigt__p_RateRule, _p_RateRuleTo_p_Rule, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_RuleType_t[] = {  {&_swigt__p_RuleType_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLConstructorException[] = {  {&_swigt__p_SBMLConstructorException, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLDocument[] = {  {&_swigt__p_SBMLDocument, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLError[] = {  {&_swigt__p_SBMLError, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLErrorCategory_t[] = {  {&_swigt__p_SBMLErrorCategory_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLErrorCode_t[] = {  {&_swigt__p_SBMLErrorCode_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLErrorLog[] = {  {&_swigt__p_SBMLErrorLog, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLErrorSeverity_t[] = {  {&_swigt__p_SBMLErrorSeverity_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLNamespaces[] = {  {&_swigt__p_SBMLNamespaces, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLReader[] = {  {&_swigt__p_SBMLReader, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLTransforms[] = {  {&_swigt__p_SBMLTransforms, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLTypeCode_t[] = {  {&_swigt__p_SBMLTypeCode_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBMLWriter[] = {  {&_swigt__p_SBMLWriter, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBO[] = {  {&_swigt__p_SBO, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SBase[] = {  {&_swigt__p_Constraint, _p_ConstraintTo_p_SBase, 0, 0},  {&_swigt__p_RateRule, _p_RateRuleTo_p_SBase, 0, 0},  {&_swigt__p_ListOfFunctionDefinitions, _p_ListOfFunctionDefinitionsTo_p_SBase, 0, 0},  {&_swigt__p_ListOfUnitDefinitions, _p_ListOfUnitDefinitionsTo_p_SBase, 0, 0},  {&_swigt__p_SimpleSpeciesReference, _p_SimpleSpeciesReferenceTo_p_SBase, 0, 0},  {&_swigt__p_SpeciesReference, _p_SpeciesReferenceTo_p_SBase, 0, 0},  {&_swigt__p_ModifierSpeciesReference, _p_ModifierSpeciesReferenceTo_p_SBase, 0, 0},  {&_swigt__p_Event, _p_EventTo_p_SBase, 0, 0},  {&_swigt__p_EventAssignment, _p_EventAssignmentTo_p_SBase, 0, 0},  {&_swigt__p_InitialAssignment, _p_InitialAssignmentTo_p_SBase, 0, 0},  {&_swigt__p_ListOfLocalParameters, _p_ListOfLocalParametersTo_p_SBase, 0, 0},  {&_swigt__p_ListOfParameters, _p_ListOfParametersTo_p_SBase, 0, 0},  {&_swigt__p_AssignmentRule, _p_AssignmentRuleTo_p_SBase, 0, 0},  {&_swigt__p_SBMLDocument, _p_SBMLDocumentTo_p_SBase, 0, 0},  {&_swigt__p_FunctionDefinition, _p_FunctionDefinitionTo_p_SBase, 0, 0},  {&_swigt__p_UnitDefinition, _p_UnitDefinitionTo_p_SBase, 0, 0},  {&_swigt__p_Model, _p_ModelTo_p_SBase, 0, 0},  {&_swigt__p_ListOfInitialAssignments, _p_ListOfInitialAssignmentsTo_p_SBase, 0, 0},  {&_swigt__p_ListOfEventAssignments, _p_ListOfEventAssignmentsTo_p_SBase, 0, 0},  {&_swigt__p_AlgebraicRule, _p_AlgebraicRuleTo_p_SBase, 0, 0},  {&_swigt__p_Delay, _p_DelayTo_p_SBase, 0, 0},  {&_swigt__p_ListOf, _p_ListOfTo_p_SBase, 0, 0},  {&_swigt__p_ListOfCompartmentTypes, _p_ListOfCompartmentTypesTo_p_SBase, 0, 0},  {&_swigt__p_Compartment, _p_CompartmentTo_p_SBase, 0, 0},  {&_swigt__p_KineticLaw, _p_KineticLawTo_p_SBase, 0, 0},  {&_swigt__p_ListOfEvents, _p_ListOfEventsTo_p_SBase, 0, 0},  {&_swigt__p_StoichiometryMath, _p_StoichiometryMathTo_p_SBase, 0, 0},  {&_swigt__p_Unit, _p_UnitTo_p_SBase, 0, 0},  {&_swigt__p_SBase, 0, 0, 0},  {&_swigt__p_ListOfSpeciesReferences, _p_ListOfSpeciesReferencesTo_p_SBase, 0, 0},  {&_swigt__p_ListOfSpeciesTypes, _p_ListOfSpeciesTypesTo_p_SBase, 0, 0},  {&_swigt__p_ListOfRules, _p_ListOfRulesTo_p_SBase, 0, 0},  {&_swigt__p_Rule, _p_RuleTo_p_SBase, 0, 0},  {&_swigt__p_ListOfConstraints, _p_ListOfConstraintsTo_p_SBase, 0, 0},  {&_swigt__p_Priority, _p_PriorityTo_p_SBase, 0, 0},  {&_swigt__p_ListOfReactions, _p_ListOfReactionsTo_p_SBase, 0, 0},  {&_swigt__p_CompartmentType, _p_CompartmentTypeTo_p_SBase, 0, 0},  {&_swigt__p_LocalParameter, _p_LocalParameterTo_p_SBase, 0, 0},  {&_swigt__p_Parameter, _p_ParameterTo_p_SBase, 0, 0},  {&_swigt__p_ListOfSpecies, _p_ListOfSpeciesTo_p_SBase, 0, 0},  {&_swigt__p_Species, _p_SpeciesTo_p_SBase, 0, 0},  {&_swigt__p_Trigger, _p_TriggerTo_p_SBase, 0, 0},  {&_swigt__p_ListOfUnits, _p_ListOfUnitsTo_p_SBase, 0, 0},  {&_swigt__p_SpeciesType, _p_SpeciesTypeTo_p_SBase, 0, 0},  {&_swigt__p_ListOfCompartments, _p_ListOfCompartmentsTo_p_SBase, 0, 0},  {&_swigt__p_Reaction, _p_ReactionTo_p_SBase, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SimpleSpeciesReference[] = {  {&_swigt__p_SimpleSpeciesReference, 0, 0, 0},  {&_swigt__p_SpeciesReference, _p_SpeciesReferenceTo_p_SimpleSpeciesReference, 0, 0},  {&_swigt__p_ModifierSpeciesReference, _p_ModifierSpeciesReferenceTo_p_SimpleSpeciesReference, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Species[] = {  {&_swigt__p_Species, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SpeciesReference[] = {  {&_swigt__p_SpeciesReference, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SpeciesType[] = {  {&_swigt__p_SpeciesType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_StoichiometryMath[] = {  {&_swigt__p_StoichiometryMath, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SyntaxChecker[] = {  {&_swigt__p_SyntaxChecker, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Trigger[] = {  {&_swigt__p_Trigger, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Unit[] = {  {&_swigt__p_Unit, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_UnitDefinition[] = {  {&_swigt__p_UnitDefinition, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_UnitKind_t[] = {  {&_swigt__p_UnitKind_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLAttributes[] = {  {&_swigt__p_XMLAttributes, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLConstructorException[] = {  {&_swigt__p_XMLConstructorException, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLError[] = {  {&_swigt__p_XMLError, 0, 0, 0},  {&_swigt__p_SBMLError, _p_SBMLErrorTo_p_XMLError, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLErrorCategory_t[] = {  {&_swigt__p_XMLErrorCategory_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLErrorCode_t[] = {  {&_swigt__p_XMLErrorCode_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLErrorLog[] = {  {&_swigt__p_XMLErrorLog, 0, 0, 0},  {&_swigt__p_SBMLErrorLog, _p_SBMLErrorLogTo_p_XMLErrorLog, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLErrorSeverity_t[] = {  {&_swigt__p_XMLErrorSeverity_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLInputStream[] = {  {&_swigt__p_XMLInputStream, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLNamespaces[] = {  {&_swigt__p_XMLNamespaces, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLNode[] = {  {&_swigt__p_XMLNode, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLOutputStringStream[] = {{&_swigt__p_XMLOutputStringStream, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLOutputFileStream[] = {{&_swigt__p_XMLOutputFileStream, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLOutputStream[] = {  {&_swigt__p_XMLOutputStringStream, _p_XMLOutputStringStreamTo_p_XMLOutputStream, 0, 0},  {&_swigt__p_XMLOutputFileStream, _p_XMLOutputFileStreamTo_p_XMLOutputStream, 0, 0},  {&_swigt__p_XMLOutputStream, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLToken[] = {  {&_swigt__p_XMLToken, 0, 0, 0},  {&_swigt__p_XMLNode, _p_XMLNodeTo_p_XMLToken, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_XMLTriple[] = {  {&_swigt__p_XMLTriple, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_char[] = {  {&_swigt__p_char, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__multimapT_int_int_t[] = {  {&_swigt__p_std__multimapT_int_int_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__ostream[] = {  {&_swigt__p_std__ostream, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__pairT_ParentMap__iterator_ParentMap__iterator_t[] = {  {&_swigt__p_std__pairT_ParentMap__iterator_ParentMap__iterator_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__pairT_std__string_bool_t[] = {  {&_swigt__p_std__pairT_std__string_bool_t, 0, 0, 0},{0, 0, 0, 0}};

static swig_cast_info *swig_cast_initial[] = {
  _swigc__p_ASTNode,
  _swigc__p_ASTNodeType_t,
  _swigc__p_AlgebraicRule,
  _swigc__p_AssignmentRule,
  _swigc__p_BiolQualifierType_t,
  _swigc__p_CVTerm,
  _swigc__p_Compartment,
  _swigc__p_CompartmentType,
  _swigc__p_Constraint,
  _swigc__p_Date,
  _swigc__p_Delay,
  _swigc__p_Event,
  _swigc__p_EventAssignment,
  _swigc__p_FunctionDefinition,
  _swigc__p_InitialAssignment,
  _swigc__p_KineticLaw,
  _swigc__p_List,
  _swigc__p_ListOf,
  _swigc__p_ListOfCompartmentTypes,
  _swigc__p_ListOfCompartments,
  _swigc__p_ListOfConstraints,
  _swigc__p_ListOfEventAssignments,
  _swigc__p_ListOfEvents,
  _swigc__p_ListOfFunctionDefinitions,
  _swigc__p_ListOfInitialAssignments,
  _swigc__p_ListOfLocalParameters,
  _swigc__p_ListOfParameters,
  _swigc__p_ListOfReactions,
  _swigc__p_ListOfRules,
  _swigc__p_ListOfSpecies,
  _swigc__p_ListOfSpeciesReferences,
  _swigc__p_ListOfSpeciesTypes,
  _swigc__p_ListOfUnitDefinitions,
  _swigc__p_ListOfUnits,
  _swigc__p_ListWrapperT_ASTNode_t,
  _swigc__p_ListWrapperT_CVTerm_t,
  _swigc__p_ListWrapperT_Date_t,
  _swigc__p_ListWrapperT_ModelCreator_t,
  _swigc__p_ListWrapperT_SBMLNamespaces_t,
  _swigc__p_LocalParameter,
  _swigc__p_Model,
  _swigc__p_ModelCreator,
  _swigc__p_ModelHistory,
  _swigc__p_ModelQualifierType_t,
  _swigc__p_ModifierSpeciesReference,
  _swigc__p_OFStream,
  _swigc__p_OStream,
  _swigc__p_OStringStream,
  _swigc__p_OperationReturnValues_t,
  _swigc__p_Parameter,
  _swigc__p_ParentMap__iterator,
  _swigc__p_Priority,
  _swigc__p_QualifierType_t,
  _swigc__p_RDFAnnotationParser,
  _swigc__p_RateRule,
  _swigc__p_Reaction,
  _swigc__p_Rule,
  _swigc__p_RuleType_t,
  _swigc__p_SBMLConstructorException,
  _swigc__p_SBMLDocument,
  _swigc__p_SBMLError,
  _swigc__p_SBMLErrorCategory_t,
  _swigc__p_SBMLErrorCode_t,
  _swigc__p_SBMLErrorLog,
  _swigc__p_SBMLErrorSeverity_t,
  _swigc__p_SBMLNamespaces,
  _swigc__p_SBMLReader,
  _swigc__p_SBMLTransforms,
  _swigc__p_SBMLTypeCode_t,
  _swigc__p_SBMLWriter,
  _swigc__p_SBO,
  _swigc__p_SBase,
  _swigc__p_SimpleSpeciesReference,
  _swigc__p_Species,
  _swigc__p_SpeciesReference,
  _swigc__p_SpeciesType,
  _swigc__p_StoichiometryMath,
  _swigc__p_SyntaxChecker,
  _swigc__p_Trigger,
  _swigc__p_Unit,
  _swigc__p_UnitDefinition,
  _swigc__p_UnitKind_t,
  _swigc__p_XMLAttributes,
  _swigc__p_XMLConstructorException,
  _swigc__p_XMLError,
  _swigc__p_XMLErrorCategory_t,
  _swigc__p_XMLErrorCode_t,
  _swigc__p_XMLErrorLog,
  _swigc__p_XMLErrorSeverity_t,
  _swigc__p_XMLInputStream,
  _swigc__p_XMLNamespaces,
  _swigc__p_XMLNode,
  _swigc__p_XMLOutputFileStream,
  _swigc__p_XMLOutputStream,
  _swigc__p_XMLOutputStringStream,
  _swigc__p_XMLToken,
  _swigc__p_XMLTriple,
  _swigc__p_char,
  _swigc__p_std__multimapT_int_int_t,
  _swigc__p_std__ostream,
  _swigc__p_std__pairT_ParentMap__iterator_ParentMap__iterator_t,
  _swigc__p_std__pairT_std__string_bool_t,
};


/* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */

static swig_constant_info swig_constants[] = {
{0,0,0,0,0,0}
};
#ifdef __cplusplus
}
#endif
static swig_variable_info swig_variables[] = {
    { "LibSBMLc::COUT", MAGIC_CLASS swig_magic_readonly, MAGIC_CLASS _wrap_COUT_get,&SWIGTYPE_p_std__ostream },
    { "LibSBMLc::CERR", MAGIC_CLASS swig_magic_readonly, MAGIC_CLASS _wrap_CERR_get,&SWIGTYPE_p_std__ostream },
    { "LibSBMLc::CLOG", MAGIC_CLASS swig_magic_readonly, MAGIC_CLASS _wrap_CLOG_get,&SWIGTYPE_p_std__ostream },
{0,0,0,0}
};
static swig_command_info swig_commands[] = {
{"LibSBMLc::new_ModelCreatorList", _wrap_new_ModelCreatorList},
{"LibSBMLc::delete_ModelCreatorList", _wrap_delete_ModelCreatorList},
{"LibSBMLc::ModelCreatorList_add", _wrap_ModelCreatorList_add},
{"LibSBMLc::ModelCreatorList_get", _wrap_ModelCreatorList_get},
{"LibSBMLc::ModelCreatorList_prepend", _wrap_ModelCreatorList_prepend},
{"LibSBMLc::ModelCreatorList_remove", _wrap_ModelCreatorList_remove},
{"LibSBMLc::ModelCreatorList_getSize", _wrap_ModelCreatorList_getSize},
{"LibSBMLc::new_DateList", _wrap_new_DateList},
{"LibSBMLc::delete_DateList", _wrap_delete_DateList},
{"LibSBMLc::DateList_add", _wrap_DateList_add},
{"LibSBMLc::DateList_get", _wrap_DateList_get},
{"LibSBMLc::DateList_prepend", _wrap_DateList_prepend},
{"LibSBMLc::DateList_remove", _wrap_DateList_remove},
{"LibSBMLc::DateList_getSize", _wrap_DateList_getSize},
{"LibSBMLc::new_CVTermList", _wrap_new_CVTermList},
{"LibSBMLc::delete_CVTermList", _wrap_delete_CVTermList},
{"LibSBMLc::CVTermList_add", _wrap_CVTermList_add},
{"LibSBMLc::CVTermList_get", _wrap_CVTermList_get},
{"LibSBMLc::CVTermList_prepend", _wrap_CVTermList_prepend},
{"LibSBMLc::CVTermList_remove", _wrap_CVTermList_remove},
{"LibSBMLc::CVTermList_getSize", _wrap_CVTermList_getSize},
{"LibSBMLc::new_ASTNodeList", _wrap_new_ASTNodeList},
{"LibSBMLc::delete_ASTNodeList", _wrap_delete_ASTNodeList},
{"LibSBMLc::ASTNodeList_add", _wrap_ASTNodeList_add},
{"LibSBMLc::ASTNodeList_get", _wrap_ASTNodeList_get},
{"LibSBMLc::ASTNodeList_prepend", _wrap_ASTNodeList_prepend},
{"LibSBMLc::ASTNodeList_remove", _wrap_ASTNodeList_remove},
{"LibSBMLc::ASTNodeList_getSize", _wrap_ASTNodeList_getSize},
{"LibSBMLc::new_SBMLNamespacesList", _wrap_new_SBMLNamespacesList},
{"LibSBMLc::delete_SBMLNamespacesList", _wrap_delete_SBMLNamespacesList},
{"LibSBMLc::SBMLNamespacesList_add", _wrap_SBMLNamespacesList_add},
{"LibSBMLc::SBMLNamespacesList_get", _wrap_SBMLNamespacesList_get},
{"LibSBMLc::SBMLNamespacesList_prepend", _wrap_SBMLNamespacesList_prepend},
{"LibSBMLc::SBMLNamespacesList_remove", _wrap_SBMLNamespacesList_remove},
{"LibSBMLc::SBMLNamespacesList_getSize", _wrap_SBMLNamespacesList_getSize},
{"LibSBMLc::new_OStream", _wrap_new_OStream},
{"LibSBMLc::delete_OStream", _wrap_delete_OStream},
{"LibSBMLc::OStream_get_ostream", _wrap_OStream_get_ostream},
{"LibSBMLc::OStream_endl", _wrap_OStream_endl},
{"LibSBMLc::new_OFStream", _wrap_new_OFStream},
{"LibSBMLc::delete_OFStream", _wrap_delete_OFStream},
{"LibSBMLc::OFStream_open", _wrap_OFStream_open},
{"LibSBMLc::OFStream_close", _wrap_OFStream_close},
{"LibSBMLc::OFStream_is_open", _wrap_OFStream_is_open},
{"LibSBMLc::new_OStringStream", _wrap_new_OStringStream},
{"LibSBMLc::OStringStream_str", _wrap_OStringStream_str},
{"LibSBMLc::delete_OStringStream", _wrap_delete_OStringStream},
{"LibSBMLc::ASTNode_true", _wrap_ASTNode_true},
{"LibSBMLc::getLibSBMLVersion", _wrap_getLibSBMLVersion},
{"LibSBMLc::getLibSBMLDottedVersion", _wrap_getLibSBMLDottedVersion},
{"LibSBMLc::getLibSBMLVersionString", _wrap_getLibSBMLVersionString},
{"LibSBMLc::new_SBMLReader", _wrap_new_SBMLReader},
{"LibSBMLc::delete_SBMLReader", _wrap_delete_SBMLReader},
{"LibSBMLc::SBMLReader_readSBML", _wrap_SBMLReader_readSBML},
{"LibSBMLc::SBMLReader_readSBMLFromFile", _wrap_SBMLReader_readSBMLFromFile},
{"LibSBMLc::SBMLReader_readSBMLFromString", _wrap_SBMLReader_readSBMLFromString},
{"LibSBMLc::SBMLReader_hasZlib", _wrap_SBMLReader_hasZlib},
{"LibSBMLc::SBMLReader_hasBzip2", _wrap_SBMLReader_hasBzip2},
{"LibSBMLc::readSBML", _wrap_readSBML},
{"LibSBMLc::readSBMLFromFile", _wrap_readSBMLFromFile},
{"LibSBMLc::readSBMLFromString", _wrap_readSBMLFromString},
{"LibSBMLc::new_SBMLWriter", _wrap_new_SBMLWriter},
{"LibSBMLc::delete_SBMLWriter", _wrap_delete_SBMLWriter},
{"LibSBMLc::SBMLWriter_setProgramName", _wrap_SBMLWriter_setProgramName},
{"LibSBMLc::SBMLWriter_setProgramVersion", _wrap_SBMLWriter_setProgramVersion},
{"LibSBMLc::SBMLWriter_writeSBML", _wrap_SBMLWriter_writeSBML},
{"LibSBMLc::SBMLWriter_writeToString", _wrap_SBMLWriter_writeToString},
{"LibSBMLc::SBMLWriter_writeSBMLToFile", _wrap_SBMLWriter_writeSBMLToFile},
{"LibSBMLc::SBMLWriter_writeSBMLToString", _wrap_SBMLWriter_writeSBMLToString},
{"LibSBMLc::SBMLWriter_hasZlib", _wrap_SBMLWriter_hasZlib},
{"LibSBMLc::SBMLWriter_hasBzip2", _wrap_SBMLWriter_hasBzip2},
{"LibSBMLc::writeSBML", _wrap_writeSBML},
{"LibSBMLc::writeSBMLToString", _wrap_writeSBMLToString},
{"LibSBMLc::writeSBMLToFile", _wrap_writeSBMLToFile},
{"LibSBMLc::SBMLTypeCode_toString", _wrap_SBMLTypeCode_toString},
{"LibSBMLc::new_SBMLConstructorException", _wrap_new_SBMLConstructorException},
{"LibSBMLc::delete_SBMLConstructorException", _wrap_delete_SBMLConstructorException},
{"LibSBMLc::delete_SBase", _wrap_delete_SBase},
{"LibSBMLc::SBase_clone", _wrap_SBase_clone},
{"LibSBMLc::SBase_getMetaId", _wrap_SBase_getMetaId},
{"LibSBMLc::SBase_getId", _wrap_SBase_getId},
{"LibSBMLc::SBase_getName", _wrap_SBase_getName},
{"LibSBMLc::SBase_getNotes", _wrap_SBase_getNotes},
{"LibSBMLc::SBase_getNotesString", _wrap_SBase_getNotesString},
{"LibSBMLc::SBase_getAnnotation", _wrap_SBase_getAnnotation},
{"LibSBMLc::SBase_getAnnotationString", _wrap_SBase_getAnnotationString},
{"LibSBMLc::SBase_getNamespaces", _wrap_SBase_getNamespaces},
{"LibSBMLc::SBase_getSBMLDocument", _wrap_SBase_getSBMLDocument},
{"LibSBMLc::SBase_getParentSBMLObject", _wrap_SBase_getParentSBMLObject},
{"LibSBMLc::SBase_getAncestorOfType", _wrap_SBase_getAncestorOfType},
{"LibSBMLc::SBase_getSBOTerm", _wrap_SBase_getSBOTerm},
{"LibSBMLc::SBase_getSBOTermID", _wrap_SBase_getSBOTermID},
{"LibSBMLc::SBase_getLine", _wrap_SBase_getLine},
{"LibSBMLc::SBase_getColumn", _wrap_SBase_getColumn},
{"LibSBMLc::SBase_getModelHistory", _wrap_SBase_getModelHistory},
{"LibSBMLc::SBase_isSetMetaId", _wrap_SBase_isSetMetaId},
{"LibSBMLc::SBase_isSetId", _wrap_SBase_isSetId},
{"LibSBMLc::SBase_isSetName", _wrap_SBase_isSetName},
{"LibSBMLc::SBase_isSetNotes", _wrap_SBase_isSetNotes},
{"LibSBMLc::SBase_isSetAnnotation", _wrap_SBase_isSetAnnotation},
{"LibSBMLc::SBase_isSetSBOTerm", _wrap_SBase_isSetSBOTerm},
{"LibSBMLc::SBase_setMetaId", _wrap_SBase_setMetaId},
{"LibSBMLc::SBase_isSetModelHistory", _wrap_SBase_isSetModelHistory},
{"LibSBMLc::SBase_setId", _wrap_SBase_setId},
{"LibSBMLc::SBase_setName", _wrap_SBase_setName},
{"LibSBMLc::SBase_setAnnotation", _wrap_SBase_setAnnotation},
{"LibSBMLc::SBase_appendAnnotation", _wrap_SBase_appendAnnotation},
{"LibSBMLc::SBase_setNotes", _wrap_SBase_setNotes},
{"LibSBMLc::SBase_appendNotes", _wrap_SBase_appendNotes},
{"LibSBMLc::SBase_setModelHistory", _wrap_SBase_setModelHistory},
{"LibSBMLc::SBase_setSBOTerm", _wrap_SBase_setSBOTerm},
{"LibSBMLc::SBase_setNamespaces", _wrap_SBase_setNamespaces},
{"LibSBMLc::SBase_unsetMetaId", _wrap_SBase_unsetMetaId},
{"LibSBMLc::SBase_unsetNotes", _wrap_SBase_unsetNotes},
{"LibSBMLc::SBase_unsetAnnotation", _wrap_SBase_unsetAnnotation},
{"LibSBMLc::SBase_unsetSBOTerm", _wrap_SBase_unsetSBOTerm},
{"LibSBMLc::SBase_addCVTerm", _wrap_SBase_addCVTerm},
{"LibSBMLc::SBase_getCVTerms", _wrap_SBase_getCVTerms},
{"LibSBMLc::SBase_getNumCVTerms", _wrap_SBase_getNumCVTerms},
{"LibSBMLc::SBase_getCVTerm", _wrap_SBase_getCVTerm},
{"LibSBMLc::SBase_unsetCVTerms", _wrap_SBase_unsetCVTerms},
{"LibSBMLc::SBase_unsetModelHistory", _wrap_SBase_unsetModelHistory},
{"LibSBMLc::SBase_getResourceBiologicalQualifier", _wrap_SBase_getResourceBiologicalQualifier},
{"LibSBMLc::SBase_getResourceModelQualifier", _wrap_SBase_getResourceModelQualifier},
{"LibSBMLc::SBase_getModel", _wrap_SBase_getModel},
{"LibSBMLc::SBase_getLevel", _wrap_SBase_getLevel},
{"LibSBMLc::SBase_getVersion", _wrap_SBase_getVersion},
{"LibSBMLc::SBase_getTypeCode", _wrap_SBase_getTypeCode},
{"LibSBMLc::SBase_hasValidLevelVersionNamespaceCombination", _wrap_SBase_hasValidLevelVersionNamespaceCombination},
{"LibSBMLc::SBase_getElementName", _wrap_SBase_getElementName},
{"LibSBMLc::SBase_toSBML", _wrap_SBase_toSBML},
{"LibSBMLc::SBase_hasRequiredAttributes", _wrap_SBase_hasRequiredAttributes},
{"LibSBMLc::SBase_hasRequiredElements", _wrap_SBase_hasRequiredElements},
{"LibSBMLc::SBase_checkMathMLNamespace", _wrap_SBase_checkMathMLNamespace},
{"LibSBMLc::delete_ListOf", _wrap_delete_ListOf},
{"LibSBMLc::new_ListOf", _wrap_new_ListOf},
{"LibSBMLc::ListOf_clone", _wrap_ListOf_clone},
{"LibSBMLc::ListOf_append", _wrap_ListOf_append},
{"LibSBMLc::ListOf_appendAndOwn", _wrap_ListOf_appendAndOwn},
{"LibSBMLc::ListOf_get", _wrap_ListOf_get},
{"LibSBMLc::ListOf_clear", _wrap_ListOf_clear},
{"LibSBMLc::ListOf_remove", _wrap_ListOf_remove},
{"LibSBMLc::ListOf_size", _wrap_ListOf_size},
{"LibSBMLc::ListOf_getTypeCode", _wrap_ListOf_getTypeCode},
{"LibSBMLc::ListOf_getItemTypeCode", _wrap_ListOf_getItemTypeCode},
{"LibSBMLc::ListOf_getElementName", _wrap_ListOf_getElementName},
{"LibSBMLc::delete_Model", _wrap_delete_Model},
{"LibSBMLc::new_Model", _wrap_new_Model},
{"LibSBMLc::Model_clone", _wrap_Model_clone},
{"LibSBMLc::Model_getId", _wrap_Model_getId},
{"LibSBMLc::Model_getName", _wrap_Model_getName},
{"LibSBMLc::Model_getSubstanceUnits", _wrap_Model_getSubstanceUnits},
{"LibSBMLc::Model_getTimeUnits", _wrap_Model_getTimeUnits},
{"LibSBMLc::Model_getVolumeUnits", _wrap_Model_getVolumeUnits},
{"LibSBMLc::Model_getAreaUnits", _wrap_Model_getAreaUnits},
{"LibSBMLc::Model_getLengthUnits", _wrap_Model_getLengthUnits},
{"LibSBMLc::Model_getExtentUnits", _wrap_Model_getExtentUnits},
{"LibSBMLc::Model_getConversionFactor", _wrap_Model_getConversionFactor},
{"LibSBMLc::Model_isSetId", _wrap_Model_isSetId},
{"LibSBMLc::Model_isSetName", _wrap_Model_isSetName},
{"LibSBMLc::Model_isSetSubstanceUnits", _wrap_Model_isSetSubstanceUnits},
{"LibSBMLc::Model_isSetTimeUnits", _wrap_Model_isSetTimeUnits},
{"LibSBMLc::Model_isSetVolumeUnits", _wrap_Model_isSetVolumeUnits},
{"LibSBMLc::Model_isSetAreaUnits", _wrap_Model_isSetAreaUnits},
{"LibSBMLc::Model_isSetLengthUnits", _wrap_Model_isSetLengthUnits},
{"LibSBMLc::Model_isSetExtentUnits", _wrap_Model_isSetExtentUnits},
{"LibSBMLc::Model_isSetConversionFactor", _wrap_Model_isSetConversionFactor},
{"LibSBMLc::Model_setId", _wrap_Model_setId},
{"LibSBMLc::Model_setName", _wrap_Model_setName},
{"LibSBMLc::Model_setSubstanceUnits", _wrap_Model_setSubstanceUnits},
{"LibSBMLc::Model_setTimeUnits", _wrap_Model_setTimeUnits},
{"LibSBMLc::Model_setVolumeUnits", _wrap_Model_setVolumeUnits},
{"LibSBMLc::Model_setAreaUnits", _wrap_Model_setAreaUnits},
{"LibSBMLc::Model_setLengthUnits", _wrap_Model_setLengthUnits},
{"LibSBMLc::Model_setExtentUnits", _wrap_Model_setExtentUnits},
{"LibSBMLc::Model_setConversionFactor", _wrap_Model_setConversionFactor},
{"LibSBMLc::Model_unsetId", _wrap_Model_unsetId},
{"LibSBMLc::Model_unsetName", _wrap_Model_unsetName},
{"LibSBMLc::Model_unsetSubstanceUnits", _wrap_Model_unsetSubstanceUnits},
{"LibSBMLc::Model_unsetTimeUnits", _wrap_Model_unsetTimeUnits},
{"LibSBMLc::Model_unsetVolumeUnits", _wrap_Model_unsetVolumeUnits},
{"LibSBMLc::Model_unsetAreaUnits", _wrap_Model_unsetAreaUnits},
{"LibSBMLc::Model_unsetLengthUnits", _wrap_Model_unsetLengthUnits},
{"LibSBMLc::Model_unsetExtentUnits", _wrap_Model_unsetExtentUnits},
{"LibSBMLc::Model_unsetConversionFactor", _wrap_Model_unsetConversionFactor},
{"LibSBMLc::Model_addFunctionDefinition", _wrap_Model_addFunctionDefinition},
{"LibSBMLc::Model_addUnitDefinition", _wrap_Model_addUnitDefinition},
{"LibSBMLc::Model_addCompartmentType", _wrap_Model_addCompartmentType},
{"LibSBMLc::Model_addSpeciesType", _wrap_Model_addSpeciesType},
{"LibSBMLc::Model_addCompartment", _wrap_Model_addCompartment},
{"LibSBMLc::Model_addSpecies", _wrap_Model_addSpecies},
{"LibSBMLc::Model_addParameter", _wrap_Model_addParameter},
{"LibSBMLc::Model_addInitialAssignment", _wrap_Model_addInitialAssignment},
{"LibSBMLc::Model_addRule", _wrap_Model_addRule},
{"LibSBMLc::Model_addConstraint", _wrap_Model_addConstraint},
{"LibSBMLc::Model_addReaction", _wrap_Model_addReaction},
{"LibSBMLc::Model_addEvent", _wrap_Model_addEvent},
{"LibSBMLc::Model_createFunctionDefinition", _wrap_Model_createFunctionDefinition},
{"LibSBMLc::Model_createUnitDefinition", _wrap_Model_createUnitDefinition},
{"LibSBMLc::Model_createUnit", _wrap_Model_createUnit},
{"LibSBMLc::Model_createCompartmentType", _wrap_Model_createCompartmentType},
{"LibSBMLc::Model_createSpeciesType", _wrap_Model_createSpeciesType},
{"LibSBMLc::Model_createCompartment", _wrap_Model_createCompartment},
{"LibSBMLc::Model_createSpecies", _wrap_Model_createSpecies},
{"LibSBMLc::Model_createParameter", _wrap_Model_createParameter},
{"LibSBMLc::Model_createInitialAssignment", _wrap_Model_createInitialAssignment},
{"LibSBMLc::Model_createAlgebraicRule", _wrap_Model_createAlgebraicRule},
{"LibSBMLc::Model_createAssignmentRule", _wrap_Model_createAssignmentRule},
{"LibSBMLc::Model_createRateRule", _wrap_Model_createRateRule},
{"LibSBMLc::Model_createConstraint", _wrap_Model_createConstraint},
{"LibSBMLc::Model_createReaction", _wrap_Model_createReaction},
{"LibSBMLc::Model_createReactant", _wrap_Model_createReactant},
{"LibSBMLc::Model_createProduct", _wrap_Model_createProduct},
{"LibSBMLc::Model_createModifier", _wrap_Model_createModifier},
{"LibSBMLc::Model_createKineticLaw", _wrap_Model_createKineticLaw},
{"LibSBMLc::Model_createKineticLawParameter", _wrap_Model_createKineticLawParameter},
{"LibSBMLc::Model_createKineticLawLocalParameter", _wrap_Model_createKineticLawLocalParameter},
{"LibSBMLc::Model_createEvent", _wrap_Model_createEvent},
{"LibSBMLc::Model_createEventAssignment", _wrap_Model_createEventAssignment},
{"LibSBMLc::Model_createTrigger", _wrap_Model_createTrigger},
{"LibSBMLc::Model_createDelay", _wrap_Model_createDelay},
{"LibSBMLc::Model_setAnnotation", _wrap_Model_setAnnotation},
{"LibSBMLc::Model_appendAnnotation", _wrap_Model_appendAnnotation},
{"LibSBMLc::Model_getListOfFunctionDefinitions", _wrap_Model_getListOfFunctionDefinitions},
{"LibSBMLc::Model_getListOfUnitDefinitions", _wrap_Model_getListOfUnitDefinitions},
{"LibSBMLc::Model_getListOfCompartmentTypes", _wrap_Model_getListOfCompartmentTypes},
{"LibSBMLc::Model_getListOfSpeciesTypes", _wrap_Model_getListOfSpeciesTypes},
{"LibSBMLc::Model_getListOfCompartments", _wrap_Model_getListOfCompartments},
{"LibSBMLc::Model_getListOfSpecies", _wrap_Model_getListOfSpecies},
{"LibSBMLc::Model_getListOfParameters", _wrap_Model_getListOfParameters},
{"LibSBMLc::Model_getListOfInitialAssignments", _wrap_Model_getListOfInitialAssignments},
{"LibSBMLc::Model_getListOfRules", _wrap_Model_getListOfRules},
{"LibSBMLc::Model_getListOfConstraints", _wrap_Model_getListOfConstraints},
{"LibSBMLc::Model_getListOfReactions", _wrap_Model_getListOfReactions},
{"LibSBMLc::Model_getListOfEvents", _wrap_Model_getListOfEvents},
{"LibSBMLc::Model_getFunctionDefinition", _wrap_Model_getFunctionDefinition},
{"LibSBMLc::Model_getUnitDefinition", _wrap_Model_getUnitDefinition},
{"LibSBMLc::Model_getCompartmentType", _wrap_Model_getCompartmentType},
{"LibSBMLc::Model_getSpeciesType", _wrap_Model_getSpeciesType},
{"LibSBMLc::Model_getCompartment", _wrap_Model_getCompartment},
{"LibSBMLc::Model_getSpecies", _wrap_Model_getSpecies},
{"LibSBMLc::Model_getParameter", _wrap_Model_getParameter},
{"LibSBMLc::Model_getInitialAssignment", _wrap_Model_getInitialAssignment},
{"LibSBMLc::Model_getRule", _wrap_Model_getRule},
{"LibSBMLc::Model_getConstraint", _wrap_Model_getConstraint},
{"LibSBMLc::Model_getReaction", _wrap_Model_getReaction},
{"LibSBMLc::Model_getSpeciesReference", _wrap_Model_getSpeciesReference},
{"LibSBMLc::Model_getEvent", _wrap_Model_getEvent},
{"LibSBMLc::Model_getNumFunctionDefinitions", _wrap_Model_getNumFunctionDefinitions},
{"LibSBMLc::Model_getNumUnitDefinitions", _wrap_Model_getNumUnitDefinitions},
{"LibSBMLc::Model_getNumCompartmentTypes", _wrap_Model_getNumCompartmentTypes},
{"LibSBMLc::Model_getNumSpeciesTypes", _wrap_Model_getNumSpeciesTypes},
{"LibSBMLc::Model_getNumCompartments", _wrap_Model_getNumCompartments},
{"LibSBMLc::Model_getNumSpecies", _wrap_Model_getNumSpecies},
{"LibSBMLc::Model_getNumSpeciesWithBoundaryCondition", _wrap_Model_getNumSpeciesWithBoundaryCondition},
{"LibSBMLc::Model_getNumParameters", _wrap_Model_getNumParameters},
{"LibSBMLc::Model_getNumInitialAssignments", _wrap_Model_getNumInitialAssignments},
{"LibSBMLc::Model_getNumRules", _wrap_Model_getNumRules},
{"LibSBMLc::Model_getNumConstraints", _wrap_Model_getNumConstraints},
{"LibSBMLc::Model_getNumReactions", _wrap_Model_getNumReactions},
{"LibSBMLc::Model_getNumEvents", _wrap_Model_getNumEvents},
{"LibSBMLc::Model_convertL1ToL2", _wrap_Model_convertL1ToL2},
{"LibSBMLc::Model_convertL1ToL3", _wrap_Model_convertL1ToL3},
{"LibSBMLc::Model_convertL2ToL3", _wrap_Model_convertL2ToL3},
{"LibSBMLc::Model_convertL2ToL1", _wrap_Model_convertL2ToL1},
{"LibSBMLc::Model_convertL3ToL1", _wrap_Model_convertL3ToL1},
{"LibSBMLc::Model_convertL3ToL2", _wrap_Model_convertL3ToL2},
{"LibSBMLc::Model_addModifiers", _wrap_Model_addModifiers},
{"LibSBMLc::Model_addConstantAttribute", _wrap_Model_addConstantAttribute},
{"LibSBMLc::Model_setSpatialDimensions", _wrap_Model_setSpatialDimensions},
{"LibSBMLc::Model_addDefinitionsForDefaultUnits", _wrap_Model_addDefinitionsForDefaultUnits},
{"LibSBMLc::Model_convertParametersToLocals", _wrap_Model_convertParametersToLocals},
{"LibSBMLc::Model_setSpeciesReferenceConstantValueAndStoichiometry", _wrap_Model_setSpeciesReferenceConstantValueAndStoichiometry},
{"LibSBMLc::Model_removeParameterRuleUnits", _wrap_Model_removeParameterRuleUnits},
{"LibSBMLc::Model_convertStoichiometryMath", _wrap_Model_convertStoichiometryMath},
{"LibSBMLc::Model_assignRequiredValues", _wrap_Model_assignRequiredValues},
{"LibSBMLc::Model_dealWithModelUnits", _wrap_Model_dealWithModelUnits},
{"LibSBMLc::Model_dealWithStoichiometry", _wrap_Model_dealWithStoichiometry},
{"LibSBMLc::Model_getTypeCode", _wrap_Model_getTypeCode},
{"LibSBMLc::Model_getElementName", _wrap_Model_getElementName},
{"LibSBMLc::Model_populateListFormulaUnitsData", _wrap_Model_populateListFormulaUnitsData},
{"LibSBMLc::Model_isPopulatedListFormulaUnitsData", _wrap_Model_isPopulatedListFormulaUnitsData},
{"LibSBMLc::Model_hasRequiredElements", _wrap_Model_hasRequiredElements},
{"LibSBMLc::Model_removeFunctionDefinition", _wrap_Model_removeFunctionDefinition},
{"LibSBMLc::Model_removeUnitDefinition", _wrap_Model_removeUnitDefinition},
{"LibSBMLc::Model_removeCompartmentType", _wrap_Model_removeCompartmentType},
{"LibSBMLc::Model_removeSpeciesType", _wrap_Model_removeSpeciesType},
{"LibSBMLc::Model_removeCompartment", _wrap_Model_removeCompartment},
{"LibSBMLc::Model_removeSpecies", _wrap_Model_removeSpecies},
{"LibSBMLc::Model_removeParameter", _wrap_Model_removeParameter},
{"LibSBMLc::Model_removeInitialAssignment", _wrap_Model_removeInitialAssignment},
{"LibSBMLc::Model_removeRule", _wrap_Model_removeRule},
{"LibSBMLc::Model_removeConstraint", _wrap_Model_removeConstraint},
{"LibSBMLc::Model_removeReaction", _wrap_Model_removeReaction},
{"LibSBMLc::Model_removeEvent", _wrap_Model_removeEvent},
{"LibSBMLc::SBMLDocument_getDefaultLevel", _wrap_SBMLDocument_getDefaultLevel},
{"LibSBMLc::SBMLDocument_getDefaultVersion", _wrap_SBMLDocument_getDefaultVersion},
{"LibSBMLc::delete_SBMLDocument", _wrap_delete_SBMLDocument},
{"LibSBMLc::new_SBMLDocument", _wrap_new_SBMLDocument},
{"LibSBMLc::SBMLDocument_clone", _wrap_SBMLDocument_clone},
{"LibSBMLc::SBMLDocument_getModel", _wrap_SBMLDocument_getModel},
{"LibSBMLc::SBMLDocument_expandFunctionDefinitions", _wrap_SBMLDocument_expandFunctionDefinitions},
{"LibSBMLc::SBMLDocument_expandInitialAssignments", _wrap_SBMLDocument_expandInitialAssignments},
{"LibSBMLc::SBMLDocument_setLevelAndVersion", _wrap_SBMLDocument_setLevelAndVersion},
{"LibSBMLc::SBMLDocument_setModel", _wrap_SBMLDocument_setModel},
{"LibSBMLc::SBMLDocument_createModel", _wrap_SBMLDocument_createModel},
{"LibSBMLc::SBMLDocument_setConsistencyChecks", _wrap_SBMLDocument_setConsistencyChecks},
{"LibSBMLc::SBMLDocument_setConsistencyChecksForConversion", _wrap_SBMLDocument_setConsistencyChecksForConversion},
{"LibSBMLc::SBMLDocument_checkConsistency", _wrap_SBMLDocument_checkConsistency},
{"LibSBMLc::SBMLDocument_checkInternalConsistency", _wrap_SBMLDocument_checkInternalConsistency},
{"LibSBMLc::SBMLDocument_checkL1Compatibility", _wrap_SBMLDocument_checkL1Compatibility},
{"LibSBMLc::SBMLDocument_checkL2v1Compatibility", _wrap_SBMLDocument_checkL2v1Compatibility},
{"LibSBMLc::SBMLDocument_checkL2v2Compatibility", _wrap_SBMLDocument_checkL2v2Compatibility},
{"LibSBMLc::SBMLDocument_checkL2v3Compatibility", _wrap_SBMLDocument_checkL2v3Compatibility},
{"LibSBMLc::SBMLDocument_checkL2v4Compatibility", _wrap_SBMLDocument_checkL2v4Compatibility},
{"LibSBMLc::SBMLDocument_checkL3v1Compatibility", _wrap_SBMLDocument_checkL3v1Compatibility},
{"LibSBMLc::SBMLDocument_getError", _wrap_SBMLDocument_getError},
{"LibSBMLc::SBMLDocument_getNumErrors", _wrap_SBMLDocument_getNumErrors},
{"LibSBMLc::SBMLDocument_printErrors", _wrap_SBMLDocument_printErrors},
{"LibSBMLc::SBMLDocument_getTypeCode", _wrap_SBMLDocument_getTypeCode},
{"LibSBMLc::SBMLDocument_getElementName", _wrap_SBMLDocument_getElementName},
{"LibSBMLc::SBMLDocument_getErrorLog", _wrap_SBMLDocument_getErrorLog},
{"LibSBMLc::SBMLDocument_getNamespaces", _wrap_SBMLDocument_getNamespaces},
{"LibSBMLc::delete_FunctionDefinition", _wrap_delete_FunctionDefinition},
{"LibSBMLc::new_FunctionDefinition", _wrap_new_FunctionDefinition},
{"LibSBMLc::FunctionDefinition_clone", _wrap_FunctionDefinition_clone},
{"LibSBMLc::FunctionDefinition_getId", _wrap_FunctionDefinition_getId},
{"LibSBMLc::FunctionDefinition_getName", _wrap_FunctionDefinition_getName},
{"LibSBMLc::FunctionDefinition_getMath", _wrap_FunctionDefinition_getMath},
{"LibSBMLc::FunctionDefinition_isSetId", _wrap_FunctionDefinition_isSetId},
{"LibSBMLc::FunctionDefinition_isSetName", _wrap_FunctionDefinition_isSetName},
{"LibSBMLc::FunctionDefinition_isSetMath", _wrap_FunctionDefinition_isSetMath},
{"LibSBMLc::FunctionDefinition_setId", _wrap_FunctionDefinition_setId},
{"LibSBMLc::FunctionDefinition_setName", _wrap_FunctionDefinition_setName},
{"LibSBMLc::FunctionDefinition_setMath", _wrap_FunctionDefinition_setMath},
{"LibSBMLc::FunctionDefinition_unsetName", _wrap_FunctionDefinition_unsetName},
{"LibSBMLc::FunctionDefinition_getArgument", _wrap_FunctionDefinition_getArgument},
{"LibSBMLc::FunctionDefinition_getBody", _wrap_FunctionDefinition_getBody},
{"LibSBMLc::FunctionDefinition_getNumArguments", _wrap_FunctionDefinition_getNumArguments},
{"LibSBMLc::FunctionDefinition_getTypeCode", _wrap_FunctionDefinition_getTypeCode},
{"LibSBMLc::FunctionDefinition_getElementName", _wrap_FunctionDefinition_getElementName},
{"LibSBMLc::FunctionDefinition_hasRequiredAttributes", _wrap_FunctionDefinition_hasRequiredAttributes},
{"LibSBMLc::FunctionDefinition_hasRequiredElements", _wrap_FunctionDefinition_hasRequiredElements},
{"LibSBMLc::ListOfFunctionDefinitions_clone", _wrap_ListOfFunctionDefinitions_clone},
{"LibSBMLc::ListOfFunctionDefinitions_getTypeCode", _wrap_ListOfFunctionDefinitions_getTypeCode},
{"LibSBMLc::ListOfFunctionDefinitions_getItemTypeCode", _wrap_ListOfFunctionDefinitions_getItemTypeCode},
{"LibSBMLc::ListOfFunctionDefinitions_getElementName", _wrap_ListOfFunctionDefinitions_getElementName},
{"LibSBMLc::ListOfFunctionDefinitions_get", _wrap_ListOfFunctionDefinitions_get},
{"LibSBMLc::ListOfFunctionDefinitions_remove", _wrap_ListOfFunctionDefinitions_remove},
{"LibSBMLc::new_ListOfFunctionDefinitions", _wrap_new_ListOfFunctionDefinitions},
{"LibSBMLc::delete_ListOfFunctionDefinitions", _wrap_delete_ListOfFunctionDefinitions},
{"LibSBMLc::UnitKind_equals", _wrap_UnitKind_equals},
{"LibSBMLc::UnitKind_forName", _wrap_UnitKind_forName},
{"LibSBMLc::UnitKind_toString", _wrap_UnitKind_toString},
{"LibSBMLc::UnitKind_isValidUnitKindString", _wrap_UnitKind_isValidUnitKindString},
{"LibSBMLc::delete_Unit", _wrap_delete_Unit},
{"LibSBMLc::new_Unit", _wrap_new_Unit},
{"LibSBMLc::Unit_clone", _wrap_Unit_clone},
{"LibSBMLc::Unit_initDefaults", _wrap_Unit_initDefaults},
{"LibSBMLc::Unit_getKind", _wrap_Unit_getKind},
{"LibSBMLc::Unit_getExponent", _wrap_Unit_getExponent},
{"LibSBMLc::Unit_getExponentAsDouble", _wrap_Unit_getExponentAsDouble},
{"LibSBMLc::Unit_getScale", _wrap_Unit_getScale},
{"LibSBMLc::Unit_getMultiplier", _wrap_Unit_getMultiplier},
{"LibSBMLc::Unit_getOffset", _wrap_Unit_getOffset},
{"LibSBMLc::Unit_isAmpere", _wrap_Unit_isAmpere},
{"LibSBMLc::Unit_isAvogadro", _wrap_Unit_isAvogadro},
{"LibSBMLc::Unit_isBecquerel", _wrap_Unit_isBecquerel},
{"LibSBMLc::Unit_isCandela", _wrap_Unit_isCandela},
{"LibSBMLc::Unit_isCelsius", _wrap_Unit_isCelsius},
{"LibSBMLc::Unit_isCoulomb", _wrap_Unit_isCoulomb},
{"LibSBMLc::Unit_isDimensionless", _wrap_Unit_isDimensionless},
{"LibSBMLc::Unit_isFarad", _wrap_Unit_isFarad},
{"LibSBMLc::Unit_isGram", _wrap_Unit_isGram},
{"LibSBMLc::Unit_isGray", _wrap_Unit_isGray},
{"LibSBMLc::Unit_isHenry", _wrap_Unit_isHenry},
{"LibSBMLc::Unit_isHertz", _wrap_Unit_isHertz},
{"LibSBMLc::Unit_isItem", _wrap_Unit_isItem},
{"LibSBMLc::Unit_isJoule", _wrap_Unit_isJoule},
{"LibSBMLc::Unit_isKatal", _wrap_Unit_isKatal},
{"LibSBMLc::Unit_isKelvin", _wrap_Unit_isKelvin},
{"LibSBMLc::Unit_isKilogram", _wrap_Unit_isKilogram},
{"LibSBMLc::Unit_isLitre", _wrap_Unit_isLitre},
{"LibSBMLc::Unit_isLumen", _wrap_Unit_isLumen},
{"LibSBMLc::Unit_isLux", _wrap_Unit_isLux},
{"LibSBMLc::Unit_isMetre", _wrap_Unit_isMetre},
{"LibSBMLc::Unit_isMole", _wrap_Unit_isMole},
{"LibSBMLc::Unit_isNewton", _wrap_Unit_isNewton},
{"LibSBMLc::Unit_isOhm", _wrap_Unit_isOhm},
{"LibSBMLc::Unit_isPascal", _wrap_Unit_isPascal},
{"LibSBMLc::Unit_isRadian", _wrap_Unit_isRadian},
{"LibSBMLc::Unit_isSecond", _wrap_Unit_isSecond},
{"LibSBMLc::Unit_isSiemens", _wrap_Unit_isSiemens},
{"LibSBMLc::Unit_isSievert", _wrap_Unit_isSievert},
{"LibSBMLc::Unit_isSteradian", _wrap_Unit_isSteradian},
{"LibSBMLc::Unit_isTesla", _wrap_Unit_isTesla},
{"LibSBMLc::Unit_isVolt", _wrap_Unit_isVolt},
{"LibSBMLc::Unit_isWatt", _wrap_Unit_isWatt},
{"LibSBMLc::Unit_isWeber", _wrap_Unit_isWeber},
{"LibSBMLc::Unit_isSetKind", _wrap_Unit_isSetKind},
{"LibSBMLc::Unit_isSetExponent", _wrap_Unit_isSetExponent},
{"LibSBMLc::Unit_isSetScale", _wrap_Unit_isSetScale},
{"LibSBMLc::Unit_isSetMultiplier", _wrap_Unit_isSetMultiplier},
{"LibSBMLc::Unit_setKind", _wrap_Unit_setKind},
{"LibSBMLc::Unit_setExponent", _wrap_Unit_setExponent},
{"LibSBMLc::Unit_setScale", _wrap_Unit_setScale},
{"LibSBMLc::Unit_setMultiplier", _wrap_Unit_setMultiplier},
{"LibSBMLc::Unit_setOffset", _wrap_Unit_setOffset},
{"LibSBMLc::Unit_getTypeCode", _wrap_Unit_getTypeCode},
{"LibSBMLc::Unit_getElementName", _wrap_Unit_getElementName},
{"LibSBMLc::Unit_isBuiltIn", _wrap_Unit_isBuiltIn},
{"LibSBMLc::Unit_isUnitKind", _wrap_Unit_isUnitKind},
{"LibSBMLc::Unit_areIdentical", _wrap_Unit_areIdentical},
{"LibSBMLc::Unit_areEquivalent", _wrap_Unit_areEquivalent},
{"LibSBMLc::Unit_removeScale", _wrap_Unit_removeScale},
{"LibSBMLc::Unit_merge", _wrap_Unit_merge},
{"LibSBMLc::Unit_convertToSI", _wrap_Unit_convertToSI},
{"LibSBMLc::Unit_hasRequiredAttributes", _wrap_Unit_hasRequiredAttributes},
{"LibSBMLc::ListOfUnits_clone", _wrap_ListOfUnits_clone},
{"LibSBMLc::ListOfUnits_getTypeCode", _wrap_ListOfUnits_getTypeCode},
{"LibSBMLc::ListOfUnits_getItemTypeCode", _wrap_ListOfUnits_getItemTypeCode},
{"LibSBMLc::ListOfUnits_getElementName", _wrap_ListOfUnits_getElementName},
{"LibSBMLc::ListOfUnits_get", _wrap_ListOfUnits_get},
{"LibSBMLc::ListOfUnits_remove", _wrap_ListOfUnits_remove},
{"LibSBMLc::new_ListOfUnits", _wrap_new_ListOfUnits},
{"LibSBMLc::delete_ListOfUnits", _wrap_delete_ListOfUnits},
{"LibSBMLc::delete_UnitDefinition", _wrap_delete_UnitDefinition},
{"LibSBMLc::new_UnitDefinition", _wrap_new_UnitDefinition},
{"LibSBMLc::UnitDefinition_clone", _wrap_UnitDefinition_clone},
{"LibSBMLc::UnitDefinition_getId", _wrap_UnitDefinition_getId},
{"LibSBMLc::UnitDefinition_getName", _wrap_UnitDefinition_getName},
{"LibSBMLc::UnitDefinition_isSetId", _wrap_UnitDefinition_isSetId},
{"LibSBMLc::UnitDefinition_isSetName", _wrap_UnitDefinition_isSetName},
{"LibSBMLc::UnitDefinition_setId", _wrap_UnitDefinition_setId},
{"LibSBMLc::UnitDefinition_setName", _wrap_UnitDefinition_setName},
{"LibSBMLc::UnitDefinition_unsetName", _wrap_UnitDefinition_unsetName},
{"LibSBMLc::UnitDefinition_isVariantOfArea", _wrap_UnitDefinition_isVariantOfArea},
{"LibSBMLc::UnitDefinition_isVariantOfLength", _wrap_UnitDefinition_isVariantOfLength},
{"LibSBMLc::UnitDefinition_isVariantOfSubstance", _wrap_UnitDefinition_isVariantOfSubstance},
{"LibSBMLc::UnitDefinition_isVariantOfTime", _wrap_UnitDefinition_isVariantOfTime},
{"LibSBMLc::UnitDefinition_isVariantOfVolume", _wrap_UnitDefinition_isVariantOfVolume},
{"LibSBMLc::UnitDefinition_isVariantOfDimensionless", _wrap_UnitDefinition_isVariantOfDimensionless},
{"LibSBMLc::UnitDefinition_isVariantOfMass", _wrap_UnitDefinition_isVariantOfMass},
{"LibSBMLc::UnitDefinition_isVariantOfSubstancePerTime", _wrap_UnitDefinition_isVariantOfSubstancePerTime},
{"LibSBMLc::UnitDefinition_addUnit", _wrap_UnitDefinition_addUnit},
{"LibSBMLc::UnitDefinition_createUnit", _wrap_UnitDefinition_createUnit},
{"LibSBMLc::UnitDefinition_getListOfUnits", _wrap_UnitDefinition_getListOfUnits},
{"LibSBMLc::UnitDefinition_getUnit", _wrap_UnitDefinition_getUnit},
{"LibSBMLc::UnitDefinition_getNumUnits", _wrap_UnitDefinition_getNumUnits},
{"LibSBMLc::UnitDefinition_removeUnit", _wrap_UnitDefinition_removeUnit},
{"LibSBMLc::UnitDefinition_getTypeCode", _wrap_UnitDefinition_getTypeCode},
{"LibSBMLc::UnitDefinition_getElementName", _wrap_UnitDefinition_getElementName},
{"LibSBMLc::UnitDefinition_simplify", _wrap_UnitDefinition_simplify},
{"LibSBMLc::UnitDefinition_reorder", _wrap_UnitDefinition_reorder},
{"LibSBMLc::UnitDefinition_convertToSI", _wrap_UnitDefinition_convertToSI},
{"LibSBMLc::UnitDefinition_areIdentical", _wrap_UnitDefinition_areIdentical},
{"LibSBMLc::UnitDefinition_areEquivalent", _wrap_UnitDefinition_areEquivalent},
{"LibSBMLc::UnitDefinition_combine", _wrap_UnitDefinition_combine},
{"LibSBMLc::UnitDefinition_printUnits", _wrap_UnitDefinition_printUnits},
{"LibSBMLc::UnitDefinition_hasRequiredAttributes", _wrap_UnitDefinition_hasRequiredAttributes},
{"LibSBMLc::UnitDefinition_hasRequiredElements", _wrap_UnitDefinition_hasRequiredElements},
{"LibSBMLc::ListOfUnitDefinitions_clone", _wrap_ListOfUnitDefinitions_clone},
{"LibSBMLc::ListOfUnitDefinitions_getTypeCode", _wrap_ListOfUnitDefinitions_getTypeCode},
{"LibSBMLc::ListOfUnitDefinitions_getItemTypeCode", _wrap_ListOfUnitDefinitions_getItemTypeCode},
{"LibSBMLc::ListOfUnitDefinitions_getElementName", _wrap_ListOfUnitDefinitions_getElementName},
{"LibSBMLc::ListOfUnitDefinitions_get", _wrap_ListOfUnitDefinitions_get},
{"LibSBMLc::ListOfUnitDefinitions_remove", _wrap_ListOfUnitDefinitions_remove},
{"LibSBMLc::new_ListOfUnitDefinitions", _wrap_new_ListOfUnitDefinitions},
{"LibSBMLc::delete_ListOfUnitDefinitions", _wrap_delete_ListOfUnitDefinitions},
{"LibSBMLc::delete_CompartmentType", _wrap_delete_CompartmentType},
{"LibSBMLc::new_CompartmentType", _wrap_new_CompartmentType},
{"LibSBMLc::CompartmentType_clone", _wrap_CompartmentType_clone},
{"LibSBMLc::CompartmentType_getId", _wrap_CompartmentType_getId},
{"LibSBMLc::CompartmentType_getName", _wrap_CompartmentType_getName},
{"LibSBMLc::CompartmentType_isSetId", _wrap_CompartmentType_isSetId},
{"LibSBMLc::CompartmentType_isSetName", _wrap_CompartmentType_isSetName},
{"LibSBMLc::CompartmentType_setId", _wrap_CompartmentType_setId},
{"LibSBMLc::CompartmentType_setName", _wrap_CompartmentType_setName},
{"LibSBMLc::CompartmentType_unsetName", _wrap_CompartmentType_unsetName},
{"LibSBMLc::CompartmentType_getTypeCode", _wrap_CompartmentType_getTypeCode},
{"LibSBMLc::CompartmentType_getElementName", _wrap_CompartmentType_getElementName},
{"LibSBMLc::CompartmentType_hasRequiredAttributes", _wrap_CompartmentType_hasRequiredAttributes},
{"LibSBMLc::ListOfCompartmentTypes_clone", _wrap_ListOfCompartmentTypes_clone},
{"LibSBMLc::ListOfCompartmentTypes_getTypeCode", _wrap_ListOfCompartmentTypes_getTypeCode},
{"LibSBMLc::ListOfCompartmentTypes_getItemTypeCode", _wrap_ListOfCompartmentTypes_getItemTypeCode},
{"LibSBMLc::ListOfCompartmentTypes_getElementName", _wrap_ListOfCompartmentTypes_getElementName},
{"LibSBMLc::ListOfCompartmentTypes_get", _wrap_ListOfCompartmentTypes_get},
{"LibSBMLc::ListOfCompartmentTypes_remove", _wrap_ListOfCompartmentTypes_remove},
{"LibSBMLc::new_ListOfCompartmentTypes", _wrap_new_ListOfCompartmentTypes},
{"LibSBMLc::delete_ListOfCompartmentTypes", _wrap_delete_ListOfCompartmentTypes},
{"LibSBMLc::delete_SpeciesType", _wrap_delete_SpeciesType},
{"LibSBMLc::new_SpeciesType", _wrap_new_SpeciesType},
{"LibSBMLc::SpeciesType_clone", _wrap_SpeciesType_clone},
{"LibSBMLc::SpeciesType_getId", _wrap_SpeciesType_getId},
{"LibSBMLc::SpeciesType_getName", _wrap_SpeciesType_getName},
{"LibSBMLc::SpeciesType_isSetId", _wrap_SpeciesType_isSetId},
{"LibSBMLc::SpeciesType_isSetName", _wrap_SpeciesType_isSetName},
{"LibSBMLc::SpeciesType_setId", _wrap_SpeciesType_setId},
{"LibSBMLc::SpeciesType_setName", _wrap_SpeciesType_setName},
{"LibSBMLc::SpeciesType_unsetName", _wrap_SpeciesType_unsetName},
{"LibSBMLc::SpeciesType_getTypeCode", _wrap_SpeciesType_getTypeCode},
{"LibSBMLc::SpeciesType_getElementName", _wrap_SpeciesType_getElementName},
{"LibSBMLc::SpeciesType_hasRequiredAttributes", _wrap_SpeciesType_hasRequiredAttributes},
{"LibSBMLc::ListOfSpeciesTypes_clone", _wrap_ListOfSpeciesTypes_clone},
{"LibSBMLc::ListOfSpeciesTypes_getTypeCode", _wrap_ListOfSpeciesTypes_getTypeCode},
{"LibSBMLc::ListOfSpeciesTypes_getItemTypeCode", _wrap_ListOfSpeciesTypes_getItemTypeCode},
{"LibSBMLc::ListOfSpeciesTypes_getElementName", _wrap_ListOfSpeciesTypes_getElementName},
{"LibSBMLc::ListOfSpeciesTypes_get", _wrap_ListOfSpeciesTypes_get},
{"LibSBMLc::ListOfSpeciesTypes_remove", _wrap_ListOfSpeciesTypes_remove},
{"LibSBMLc::new_ListOfSpeciesTypes", _wrap_new_ListOfSpeciesTypes},
{"LibSBMLc::delete_ListOfSpeciesTypes", _wrap_delete_ListOfSpeciesTypes},
{"LibSBMLc::delete_Compartment", _wrap_delete_Compartment},
{"LibSBMLc::new_Compartment", _wrap_new_Compartment},
{"LibSBMLc::Compartment_clone", _wrap_Compartment_clone},
{"LibSBMLc::Compartment_initDefaults", _wrap_Compartment_initDefaults},
{"LibSBMLc::Compartment_getId", _wrap_Compartment_getId},
{"LibSBMLc::Compartment_getName", _wrap_Compartment_getName},
{"LibSBMLc::Compartment_getCompartmentType", _wrap_Compartment_getCompartmentType},
{"LibSBMLc::Compartment_getSpatialDimensions", _wrap_Compartment_getSpatialDimensions},
{"LibSBMLc::Compartment_getSpatialDimensionsAsDouble", _wrap_Compartment_getSpatialDimensionsAsDouble},
{"LibSBMLc::Compartment_getSize", _wrap_Compartment_getSize},
{"LibSBMLc::Compartment_getVolume", _wrap_Compartment_getVolume},
{"LibSBMLc::Compartment_getUnits", _wrap_Compartment_getUnits},
{"LibSBMLc::Compartment_getOutside", _wrap_Compartment_getOutside},
{"LibSBMLc::Compartment_getConstant", _wrap_Compartment_getConstant},
{"LibSBMLc::Compartment_isSetId", _wrap_Compartment_isSetId},
{"LibSBMLc::Compartment_isSetName", _wrap_Compartment_isSetName},
{"LibSBMLc::Compartment_isSetCompartmentType", _wrap_Compartment_isSetCompartmentType},
{"LibSBMLc::Compartment_isSetSize", _wrap_Compartment_isSetSize},
{"LibSBMLc::Compartment_isSetVolume", _wrap_Compartment_isSetVolume},
{"LibSBMLc::Compartment_isSetUnits", _wrap_Compartment_isSetUnits},
{"LibSBMLc::Compartment_isSetOutside", _wrap_Compartment_isSetOutside},
{"LibSBMLc::Compartment_isSetSpatialDimensions", _wrap_Compartment_isSetSpatialDimensions},
{"LibSBMLc::Compartment_isSetConstant", _wrap_Compartment_isSetConstant},
{"LibSBMLc::Compartment_setId", _wrap_Compartment_setId},
{"LibSBMLc::Compartment_setName", _wrap_Compartment_setName},
{"LibSBMLc::Compartment_setCompartmentType", _wrap_Compartment_setCompartmentType},
{"LibSBMLc::Compartment_setSpatialDimensions", _wrap_Compartment_setSpatialDimensions},
{"LibSBMLc::Compartment_setSize", _wrap_Compartment_setSize},
{"LibSBMLc::Compartment_setVolume", _wrap_Compartment_setVolume},
{"LibSBMLc::Compartment_setUnits", _wrap_Compartment_setUnits},
{"LibSBMLc::Compartment_setOutside", _wrap_Compartment_setOutside},
{"LibSBMLc::Compartment_setConstant", _wrap_Compartment_setConstant},
{"LibSBMLc::Compartment_unsetName", _wrap_Compartment_unsetName},
{"LibSBMLc::Compartment_unsetCompartmentType", _wrap_Compartment_unsetCompartmentType},
{"LibSBMLc::Compartment_unsetSize", _wrap_Compartment_unsetSize},
{"LibSBMLc::Compartment_unsetVolume", _wrap_Compartment_unsetVolume},
{"LibSBMLc::Compartment_unsetUnits", _wrap_Compartment_unsetUnits},
{"LibSBMLc::Compartment_unsetOutside", _wrap_Compartment_unsetOutside},
{"LibSBMLc::Compartment_unsetSpatialDimensions", _wrap_Compartment_unsetSpatialDimensions},
{"LibSBMLc::Compartment_getDerivedUnitDefinition", _wrap_Compartment_getDerivedUnitDefinition},
{"LibSBMLc::Compartment_getTypeCode", _wrap_Compartment_getTypeCode},
{"LibSBMLc::Compartment_getElementName", _wrap_Compartment_getElementName},
{"LibSBMLc::Compartment_hasRequiredAttributes", _wrap_Compartment_hasRequiredAttributes},
{"LibSBMLc::ListOfCompartments_clone", _wrap_ListOfCompartments_clone},
{"LibSBMLc::ListOfCompartments_getTypeCode", _wrap_ListOfCompartments_getTypeCode},
{"LibSBMLc::ListOfCompartments_getItemTypeCode", _wrap_ListOfCompartments_getItemTypeCode},
{"LibSBMLc::ListOfCompartments_getElementName", _wrap_ListOfCompartments_getElementName},
{"LibSBMLc::ListOfCompartments_get", _wrap_ListOfCompartments_get},
{"LibSBMLc::ListOfCompartments_remove", _wrap_ListOfCompartments_remove},
{"LibSBMLc::new_ListOfCompartments", _wrap_new_ListOfCompartments},
{"LibSBMLc::delete_ListOfCompartments", _wrap_delete_ListOfCompartments},
{"LibSBMLc::delete_Species", _wrap_delete_Species},
{"LibSBMLc::new_Species", _wrap_new_Species},
{"LibSBMLc::Species_clone", _wrap_Species_clone},
{"LibSBMLc::Species_initDefaults", _wrap_Species_initDefaults},
{"LibSBMLc::Species_getId", _wrap_Species_getId},
{"LibSBMLc::Species_getName", _wrap_Species_getName},
{"LibSBMLc::Species_getSpeciesType", _wrap_Species_getSpeciesType},
{"LibSBMLc::Species_getCompartment", _wrap_Species_getCompartment},
{"LibSBMLc::Species_getInitialAmount", _wrap_Species_getInitialAmount},
{"LibSBMLc::Species_getInitialConcentration", _wrap_Species_getInitialConcentration},
{"LibSBMLc::Species_getSubstanceUnits", _wrap_Species_getSubstanceUnits},
{"LibSBMLc::Species_getSpatialSizeUnits", _wrap_Species_getSpatialSizeUnits},
{"LibSBMLc::Species_getUnits", _wrap_Species_getUnits},
{"LibSBMLc::Species_getHasOnlySubstanceUnits", _wrap_Species_getHasOnlySubstanceUnits},
{"LibSBMLc::Species_getBoundaryCondition", _wrap_Species_getBoundaryCondition},
{"LibSBMLc::Species_getCharge", _wrap_Species_getCharge},
{"LibSBMLc::Species_getConstant", _wrap_Species_getConstant},
{"LibSBMLc::Species_getConversionFactor", _wrap_Species_getConversionFactor},
{"LibSBMLc::Species_isSetId", _wrap_Species_isSetId},
{"LibSBMLc::Species_isSetName", _wrap_Species_isSetName},
{"LibSBMLc::Species_isSetSpeciesType", _wrap_Species_isSetSpeciesType},
{"LibSBMLc::Species_isSetCompartment", _wrap_Species_isSetCompartment},
{"LibSBMLc::Species_isSetInitialAmount", _wrap_Species_isSetInitialAmount},
{"LibSBMLc::Species_isSetInitialConcentration", _wrap_Species_isSetInitialConcentration},
{"LibSBMLc::Species_isSetSubstanceUnits", _wrap_Species_isSetSubstanceUnits},
{"LibSBMLc::Species_isSetSpatialSizeUnits", _wrap_Species_isSetSpatialSizeUnits},
{"LibSBMLc::Species_isSetUnits", _wrap_Species_isSetUnits},
{"LibSBMLc::Species_isSetCharge", _wrap_Species_isSetCharge},
{"LibSBMLc::Species_isSetConversionFactor", _wrap_Species_isSetConversionFactor},
{"LibSBMLc::Species_isSetBoundaryCondition", _wrap_Species_isSetBoundaryCondition},
{"LibSBMLc::Species_isSetHasOnlySubstanceUnits", _wrap_Species_isSetHasOnlySubstanceUnits},
{"LibSBMLc::Species_isSetConstant", _wrap_Species_isSetConstant},
{"LibSBMLc::Species_setId", _wrap_Species_setId},
{"LibSBMLc::Species_setName", _wrap_Species_setName},
{"LibSBMLc::Species_setSpeciesType", _wrap_Species_setSpeciesType},
{"LibSBMLc::Species_setCompartment", _wrap_Species_setCompartment},
{"LibSBMLc::Species_setInitialAmount", _wrap_Species_setInitialAmount},
{"LibSBMLc::Species_setInitialConcentration", _wrap_Species_setInitialConcentration},
{"LibSBMLc::Species_setSubstanceUnits", _wrap_Species_setSubstanceUnits},
{"LibSBMLc::Species_setSpatialSizeUnits", _wrap_Species_setSpatialSizeUnits},
{"LibSBMLc::Species_setUnits", _wrap_Species_setUnits},
{"LibSBMLc::Species_setHasOnlySubstanceUnits", _wrap_Species_setHasOnlySubstanceUnits},
{"LibSBMLc::Species_setBoundaryCondition", _wrap_Species_setBoundaryCondition},
{"LibSBMLc::Species_setCharge", _wrap_Species_setCharge},
{"LibSBMLc::Species_setConstant", _wrap_Species_setConstant},
{"LibSBMLc::Species_setConversionFactor", _wrap_Species_setConversionFactor},
{"LibSBMLc::Species_unsetName", _wrap_Species_unsetName},
{"LibSBMLc::Species_unsetSpeciesType", _wrap_Species_unsetSpeciesType},
{"LibSBMLc::Species_unsetInitialAmount", _wrap_Species_unsetInitialAmount},
{"LibSBMLc::Species_unsetInitialConcentration", _wrap_Species_unsetInitialConcentration},
{"LibSBMLc::Species_unsetSubstanceUnits", _wrap_Species_unsetSubstanceUnits},
{"LibSBMLc::Species_unsetSpatialSizeUnits", _wrap_Species_unsetSpatialSizeUnits},
{"LibSBMLc::Species_unsetUnits", _wrap_Species_unsetUnits},
{"LibSBMLc::Species_unsetCharge", _wrap_Species_unsetCharge},
{"LibSBMLc::Species_unsetConversionFactor", _wrap_Species_unsetConversionFactor},
{"LibSBMLc::Species_getDerivedUnitDefinition", _wrap_Species_getDerivedUnitDefinition},
{"LibSBMLc::Species_getTypeCode", _wrap_Species_getTypeCode},
{"LibSBMLc::Species_getElementName", _wrap_Species_getElementName},
{"LibSBMLc::Species_hasRequiredAttributes", _wrap_Species_hasRequiredAttributes},
{"LibSBMLc::ListOfSpecies_clone", _wrap_ListOfSpecies_clone},
{"LibSBMLc::ListOfSpecies_getTypeCode", _wrap_ListOfSpecies_getTypeCode},
{"LibSBMLc::ListOfSpecies_getItemTypeCode", _wrap_ListOfSpecies_getItemTypeCode},
{"LibSBMLc::ListOfSpecies_getElementName", _wrap_ListOfSpecies_getElementName},
{"LibSBMLc::ListOfSpecies_get", _wrap_ListOfSpecies_get},
{"LibSBMLc::ListOfSpecies_remove", _wrap_ListOfSpecies_remove},
{"LibSBMLc::new_ListOfSpecies", _wrap_new_ListOfSpecies},
{"LibSBMLc::delete_ListOfSpecies", _wrap_delete_ListOfSpecies},
{"LibSBMLc::delete_Parameter", _wrap_delete_Parameter},
{"LibSBMLc::new_Parameter", _wrap_new_Parameter},
{"LibSBMLc::Parameter_clone", _wrap_Parameter_clone},
{"LibSBMLc::Parameter_initDefaults", _wrap_Parameter_initDefaults},
{"LibSBMLc::Parameter_getId", _wrap_Parameter_getId},
{"LibSBMLc::Parameter_getName", _wrap_Parameter_getName},
{"LibSBMLc::Parameter_getValue", _wrap_Parameter_getValue},
{"LibSBMLc::Parameter_getUnits", _wrap_Parameter_getUnits},
{"LibSBMLc::Parameter_getConstant", _wrap_Parameter_getConstant},
{"LibSBMLc::Parameter_isSetId", _wrap_Parameter_isSetId},
{"LibSBMLc::Parameter_isSetName", _wrap_Parameter_isSetName},
{"LibSBMLc::Parameter_isSetValue", _wrap_Parameter_isSetValue},
{"LibSBMLc::Parameter_isSetUnits", _wrap_Parameter_isSetUnits},
{"LibSBMLc::Parameter_isSetConstant", _wrap_Parameter_isSetConstant},
{"LibSBMLc::Parameter_setId", _wrap_Parameter_setId},
{"LibSBMLc::Parameter_setName", _wrap_Parameter_setName},
{"LibSBMLc::Parameter_setValue", _wrap_Parameter_setValue},
{"LibSBMLc::Parameter_setUnits", _wrap_Parameter_setUnits},
{"LibSBMLc::Parameter_setConstant", _wrap_Parameter_setConstant},
{"LibSBMLc::Parameter_unsetName", _wrap_Parameter_unsetName},
{"LibSBMLc::Parameter_unsetValue", _wrap_Parameter_unsetValue},
{"LibSBMLc::Parameter_unsetUnits", _wrap_Parameter_unsetUnits},
{"LibSBMLc::Parameter_getDerivedUnitDefinition", _wrap_Parameter_getDerivedUnitDefinition},
{"LibSBMLc::Parameter_getTypeCode", _wrap_Parameter_getTypeCode},
{"LibSBMLc::Parameter_getElementName", _wrap_Parameter_getElementName},
{"LibSBMLc::Parameter_hasRequiredAttributes", _wrap_Parameter_hasRequiredAttributes},
{"LibSBMLc::ListOfParameters_clone", _wrap_ListOfParameters_clone},
{"LibSBMLc::ListOfParameters_getTypeCode", _wrap_ListOfParameters_getTypeCode},
{"LibSBMLc::ListOfParameters_getItemTypeCode", _wrap_ListOfParameters_getItemTypeCode},
{"LibSBMLc::ListOfParameters_getElementName", _wrap_ListOfParameters_getElementName},
{"LibSBMLc::ListOfParameters_get", _wrap_ListOfParameters_get},
{"LibSBMLc::ListOfParameters_remove", _wrap_ListOfParameters_remove},
{"LibSBMLc::new_ListOfParameters", _wrap_new_ListOfParameters},
{"LibSBMLc::delete_ListOfParameters", _wrap_delete_ListOfParameters},
{"LibSBMLc::delete_LocalParameter", _wrap_delete_LocalParameter},
{"LibSBMLc::new_LocalParameter", _wrap_new_LocalParameter},
{"LibSBMLc::LocalParameter_clone", _wrap_LocalParameter_clone},
{"LibSBMLc::LocalParameter_getDerivedUnitDefinition", _wrap_LocalParameter_getDerivedUnitDefinition},
{"LibSBMLc::LocalParameter_getTypeCode", _wrap_LocalParameter_getTypeCode},
{"LibSBMLc::LocalParameter_getElementName", _wrap_LocalParameter_getElementName},
{"LibSBMLc::LocalParameter_hasRequiredAttributes", _wrap_LocalParameter_hasRequiredAttributes},
{"LibSBMLc::ListOfLocalParameters_clone", _wrap_ListOfLocalParameters_clone},
{"LibSBMLc::ListOfLocalParameters_getTypeCode", _wrap_ListOfLocalParameters_getTypeCode},
{"LibSBMLc::ListOfLocalParameters_getItemTypeCode", _wrap_ListOfLocalParameters_getItemTypeCode},
{"LibSBMLc::ListOfLocalParameters_getElementName", _wrap_ListOfLocalParameters_getElementName},
{"LibSBMLc::ListOfLocalParameters_get", _wrap_ListOfLocalParameters_get},
{"LibSBMLc::ListOfLocalParameters_remove", _wrap_ListOfLocalParameters_remove},
{"LibSBMLc::new_ListOfLocalParameters", _wrap_new_ListOfLocalParameters},
{"LibSBMLc::delete_ListOfLocalParameters", _wrap_delete_ListOfLocalParameters},
{"LibSBMLc::delete_InitialAssignment", _wrap_delete_InitialAssignment},
{"LibSBMLc::new_InitialAssignment", _wrap_new_InitialAssignment},
{"LibSBMLc::InitialAssignment_clone", _wrap_InitialAssignment_clone},
{"LibSBMLc::InitialAssignment_getSymbol", _wrap_InitialAssignment_getSymbol},
{"LibSBMLc::InitialAssignment_getMath", _wrap_InitialAssignment_getMath},
{"LibSBMLc::InitialAssignment_isSetSymbol", _wrap_InitialAssignment_isSetSymbol},
{"LibSBMLc::InitialAssignment_isSetMath", _wrap_InitialAssignment_isSetMath},
{"LibSBMLc::InitialAssignment_setSymbol", _wrap_InitialAssignment_setSymbol},
{"LibSBMLc::InitialAssignment_setMath", _wrap_InitialAssignment_setMath},
{"LibSBMLc::InitialAssignment_getDerivedUnitDefinition", _wrap_InitialAssignment_getDerivedUnitDefinition},
{"LibSBMLc::InitialAssignment_containsUndeclaredUnits", _wrap_InitialAssignment_containsUndeclaredUnits},
{"LibSBMLc::InitialAssignment_getTypeCode", _wrap_InitialAssignment_getTypeCode},
{"LibSBMLc::InitialAssignment_getElementName", _wrap_InitialAssignment_getElementName},
{"LibSBMLc::InitialAssignment_hasRequiredAttributes", _wrap_InitialAssignment_hasRequiredAttributes},
{"LibSBMLc::InitialAssignment_hasRequiredElements", _wrap_InitialAssignment_hasRequiredElements},
{"LibSBMLc::InitialAssignment_getId", _wrap_InitialAssignment_getId},
{"LibSBMLc::ListOfInitialAssignments_clone", _wrap_ListOfInitialAssignments_clone},
{"LibSBMLc::ListOfInitialAssignments_getTypeCode", _wrap_ListOfInitialAssignments_getTypeCode},
{"LibSBMLc::ListOfInitialAssignments_getItemTypeCode", _wrap_ListOfInitialAssignments_getItemTypeCode},
{"LibSBMLc::ListOfInitialAssignments_getElementName", _wrap_ListOfInitialAssignments_getElementName},
{"LibSBMLc::ListOfInitialAssignments_get", _wrap_ListOfInitialAssignments_get},
{"LibSBMLc::ListOfInitialAssignments_remove", _wrap_ListOfInitialAssignments_remove},
{"LibSBMLc::new_ListOfInitialAssignments", _wrap_new_ListOfInitialAssignments},
{"LibSBMLc::delete_ListOfInitialAssignments", _wrap_delete_ListOfInitialAssignments},
{"LibSBMLc::delete_Rule", _wrap_delete_Rule},
{"LibSBMLc::new_Rule", _wrap_new_Rule},
{"LibSBMLc::Rule_clone", _wrap_Rule_clone},
{"LibSBMLc::Rule_getFormula", _wrap_Rule_getFormula},
{"LibSBMLc::Rule_getMath", _wrap_Rule_getMath},
{"LibSBMLc::Rule_getVariable", _wrap_Rule_getVariable},
{"LibSBMLc::Rule_getUnits", _wrap_Rule_getUnits},
{"LibSBMLc::Rule_isSetFormula", _wrap_Rule_isSetFormula},
{"LibSBMLc::Rule_isSetMath", _wrap_Rule_isSetMath},
{"LibSBMLc::Rule_isSetVariable", _wrap_Rule_isSetVariable},
{"LibSBMLc::Rule_isSetUnits", _wrap_Rule_isSetUnits},
{"LibSBMLc::Rule_setFormula", _wrap_Rule_setFormula},
{"LibSBMLc::Rule_setMath", _wrap_Rule_setMath},
{"LibSBMLc::Rule_setVariable", _wrap_Rule_setVariable},
{"LibSBMLc::Rule_setUnits", _wrap_Rule_setUnits},
{"LibSBMLc::Rule_unsetUnits", _wrap_Rule_unsetUnits},
{"LibSBMLc::Rule_getDerivedUnitDefinition", _wrap_Rule_getDerivedUnitDefinition},
{"LibSBMLc::Rule_containsUndeclaredUnits", _wrap_Rule_containsUndeclaredUnits},
{"LibSBMLc::Rule_getType", _wrap_Rule_getType},
{"LibSBMLc::Rule_isAlgebraic", _wrap_Rule_isAlgebraic},
{"LibSBMLc::Rule_isAssignment", _wrap_Rule_isAssignment},
{"LibSBMLc::Rule_isCompartmentVolume", _wrap_Rule_isCompartmentVolume},
{"LibSBMLc::Rule_isParameter", _wrap_Rule_isParameter},
{"LibSBMLc::Rule_isRate", _wrap_Rule_isRate},
{"LibSBMLc::Rule_isScalar", _wrap_Rule_isScalar},
{"LibSBMLc::Rule_isSpeciesConcentration", _wrap_Rule_isSpeciesConcentration},
{"LibSBMLc::Rule_getTypeCode", _wrap_Rule_getTypeCode},
{"LibSBMLc::Rule_getL1TypeCode", _wrap_Rule_getL1TypeCode},
{"LibSBMLc::Rule_getElementName", _wrap_Rule_getElementName},
{"LibSBMLc::Rule_setL1TypeCode", _wrap_Rule_setL1TypeCode},
{"LibSBMLc::Rule_hasRequiredElements", _wrap_Rule_hasRequiredElements},
{"LibSBMLc::Rule_hasRequiredAttributes", _wrap_Rule_hasRequiredAttributes},
{"LibSBMLc::Rule_getId", _wrap_Rule_getId},
{"LibSBMLc::new_AlgebraicRule", _wrap_new_AlgebraicRule},
{"LibSBMLc::delete_AlgebraicRule", _wrap_delete_AlgebraicRule},
{"LibSBMLc::AlgebraicRule_clone", _wrap_AlgebraicRule_clone},
{"LibSBMLc::AlgebraicRule_hasRequiredAttributes", _wrap_AlgebraicRule_hasRequiredAttributes},
{"LibSBMLc::new_AssignmentRule", _wrap_new_AssignmentRule},
{"LibSBMLc::delete_AssignmentRule", _wrap_delete_AssignmentRule},
{"LibSBMLc::AssignmentRule_clone", _wrap_AssignmentRule_clone},
{"LibSBMLc::AssignmentRule_hasRequiredAttributes", _wrap_AssignmentRule_hasRequiredAttributes},
{"LibSBMLc::new_RateRule", _wrap_new_RateRule},
{"LibSBMLc::delete_RateRule", _wrap_delete_RateRule},
{"LibSBMLc::RateRule_clone", _wrap_RateRule_clone},
{"LibSBMLc::RateRule_hasRequiredAttributes", _wrap_RateRule_hasRequiredAttributes},
{"LibSBMLc::ListOfRules_clone", _wrap_ListOfRules_clone},
{"LibSBMLc::ListOfRules_getTypeCode", _wrap_ListOfRules_getTypeCode},
{"LibSBMLc::ListOfRules_getItemTypeCode", _wrap_ListOfRules_getItemTypeCode},
{"LibSBMLc::ListOfRules_getElementName", _wrap_ListOfRules_getElementName},
{"LibSBMLc::ListOfRules_get", _wrap_ListOfRules_get},
{"LibSBMLc::ListOfRules_remove", _wrap_ListOfRules_remove},
{"LibSBMLc::new_ListOfRules", _wrap_new_ListOfRules},
{"LibSBMLc::delete_ListOfRules", _wrap_delete_ListOfRules},
{"LibSBMLc::delete_Constraint", _wrap_delete_Constraint},
{"LibSBMLc::new_Constraint", _wrap_new_Constraint},
{"LibSBMLc::Constraint_clone", _wrap_Constraint_clone},
{"LibSBMLc::Constraint_getMessage", _wrap_Constraint_getMessage},
{"LibSBMLc::Constraint_getMessageString", _wrap_Constraint_getMessageString},
{"LibSBMLc::Constraint_getMath", _wrap_Constraint_getMath},
{"LibSBMLc::Constraint_isSetMessage", _wrap_Constraint_isSetMessage},
{"LibSBMLc::Constraint_isSetMath", _wrap_Constraint_isSetMath},
{"LibSBMLc::Constraint_setMessage", _wrap_Constraint_setMessage},
{"LibSBMLc::Constraint_setMath", _wrap_Constraint_setMath},
{"LibSBMLc::Constraint_unsetMessage", _wrap_Constraint_unsetMessage},
{"LibSBMLc::Constraint_getTypeCode", _wrap_Constraint_getTypeCode},
{"LibSBMLc::Constraint_getElementName", _wrap_Constraint_getElementName},
{"LibSBMLc::Constraint_hasRequiredElements", _wrap_Constraint_hasRequiredElements},
{"LibSBMLc::ListOfConstraints_clone", _wrap_ListOfConstraints_clone},
{"LibSBMLc::ListOfConstraints_getTypeCode", _wrap_ListOfConstraints_getTypeCode},
{"LibSBMLc::ListOfConstraints_getItemTypeCode", _wrap_ListOfConstraints_getItemTypeCode},
{"LibSBMLc::ListOfConstraints_getElementName", _wrap_ListOfConstraints_getElementName},
{"LibSBMLc::ListOfConstraints_get", _wrap_ListOfConstraints_get},
{"LibSBMLc::ListOfConstraints_remove", _wrap_ListOfConstraints_remove},
{"LibSBMLc::new_ListOfConstraints", _wrap_new_ListOfConstraints},
{"LibSBMLc::delete_ListOfConstraints", _wrap_delete_ListOfConstraints},
{"LibSBMLc::delete_Reaction", _wrap_delete_Reaction},
{"LibSBMLc::new_Reaction", _wrap_new_Reaction},
{"LibSBMLc::Reaction_clone", _wrap_Reaction_clone},
{"LibSBMLc::Reaction_initDefaults", _wrap_Reaction_initDefaults},
{"LibSBMLc::Reaction_getId", _wrap_Reaction_getId},
{"LibSBMLc::Reaction_getName", _wrap_Reaction_getName},
{"LibSBMLc::Reaction_getKineticLaw", _wrap_Reaction_getKineticLaw},
{"LibSBMLc::Reaction_getReversible", _wrap_Reaction_getReversible},
{"LibSBMLc::Reaction_getFast", _wrap_Reaction_getFast},
{"LibSBMLc::Reaction_getCompartment", _wrap_Reaction_getCompartment},
{"LibSBMLc::Reaction_isSetId", _wrap_Reaction_isSetId},
{"LibSBMLc::Reaction_isSetName", _wrap_Reaction_isSetName},
{"LibSBMLc::Reaction_isSetKineticLaw", _wrap_Reaction_isSetKineticLaw},
{"LibSBMLc::Reaction_isSetFast", _wrap_Reaction_isSetFast},
{"LibSBMLc::Reaction_isSetCompartment", _wrap_Reaction_isSetCompartment},
{"LibSBMLc::Reaction_isSetReversible", _wrap_Reaction_isSetReversible},
{"LibSBMLc::Reaction_setId", _wrap_Reaction_setId},
{"LibSBMLc::Reaction_setName", _wrap_Reaction_setName},
{"LibSBMLc::Reaction_setKineticLaw", _wrap_Reaction_setKineticLaw},
{"LibSBMLc::Reaction_setReversible", _wrap_Reaction_setReversible},
{"LibSBMLc::Reaction_setFast", _wrap_Reaction_setFast},
{"LibSBMLc::Reaction_setCompartment", _wrap_Reaction_setCompartment},
{"LibSBMLc::Reaction_unsetName", _wrap_Reaction_unsetName},
{"LibSBMLc::Reaction_unsetKineticLaw", _wrap_Reaction_unsetKineticLaw},
{"LibSBMLc::Reaction_unsetFast", _wrap_Reaction_unsetFast},
{"LibSBMLc::Reaction_unsetCompartment", _wrap_Reaction_unsetCompartment},
{"LibSBMLc::Reaction_addReactant", _wrap_Reaction_addReactant},
{"LibSBMLc::Reaction_addProduct", _wrap_Reaction_addProduct},
{"LibSBMLc::Reaction_addModifier", _wrap_Reaction_addModifier},
{"LibSBMLc::Reaction_createReactant", _wrap_Reaction_createReactant},
{"LibSBMLc::Reaction_createProduct", _wrap_Reaction_createProduct},
{"LibSBMLc::Reaction_createModifier", _wrap_Reaction_createModifier},
{"LibSBMLc::Reaction_createKineticLaw", _wrap_Reaction_createKineticLaw},
{"LibSBMLc::Reaction_getListOfReactants", _wrap_Reaction_getListOfReactants},
{"LibSBMLc::Reaction_getListOfProducts", _wrap_Reaction_getListOfProducts},
{"LibSBMLc::Reaction_getListOfModifiers", _wrap_Reaction_getListOfModifiers},
{"LibSBMLc::Reaction_getReactant", _wrap_Reaction_getReactant},
{"LibSBMLc::Reaction_getProduct", _wrap_Reaction_getProduct},
{"LibSBMLc::Reaction_getModifier", _wrap_Reaction_getModifier},
{"LibSBMLc::Reaction_getNumReactants", _wrap_Reaction_getNumReactants},
{"LibSBMLc::Reaction_getNumProducts", _wrap_Reaction_getNumProducts},
{"LibSBMLc::Reaction_getNumModifiers", _wrap_Reaction_getNumModifiers},
{"LibSBMLc::Reaction_removeReactant", _wrap_Reaction_removeReactant},
{"LibSBMLc::Reaction_removeProduct", _wrap_Reaction_removeProduct},
{"LibSBMLc::Reaction_removeModifier", _wrap_Reaction_removeModifier},
{"LibSBMLc::Reaction_getTypeCode", _wrap_Reaction_getTypeCode},
{"LibSBMLc::Reaction_getElementName", _wrap_Reaction_getElementName},
{"LibSBMLc::Reaction_hasRequiredAttributes", _wrap_Reaction_hasRequiredAttributes},
{"LibSBMLc::ListOfReactions_clone", _wrap_ListOfReactions_clone},
{"LibSBMLc::ListOfReactions_getTypeCode", _wrap_ListOfReactions_getTypeCode},
{"LibSBMLc::ListOfReactions_getItemTypeCode", _wrap_ListOfReactions_getItemTypeCode},
{"LibSBMLc::ListOfReactions_getElementName", _wrap_ListOfReactions_getElementName},
{"LibSBMLc::ListOfReactions_get", _wrap_ListOfReactions_get},
{"LibSBMLc::ListOfReactions_remove", _wrap_ListOfReactions_remove},
{"LibSBMLc::new_ListOfReactions", _wrap_new_ListOfReactions},
{"LibSBMLc::delete_ListOfReactions", _wrap_delete_ListOfReactions},
{"LibSBMLc::delete_KineticLaw", _wrap_delete_KineticLaw},
{"LibSBMLc::new_KineticLaw", _wrap_new_KineticLaw},
{"LibSBMLc::KineticLaw_clone", _wrap_KineticLaw_clone},
{"LibSBMLc::KineticLaw_getFormula", _wrap_KineticLaw_getFormula},
{"LibSBMLc::KineticLaw_getMath", _wrap_KineticLaw_getMath},
{"LibSBMLc::KineticLaw_getTimeUnits", _wrap_KineticLaw_getTimeUnits},
{"LibSBMLc::KineticLaw_getSubstanceUnits", _wrap_KineticLaw_getSubstanceUnits},
{"LibSBMLc::KineticLaw_isSetFormula", _wrap_KineticLaw_isSetFormula},
{"LibSBMLc::KineticLaw_isSetMath", _wrap_KineticLaw_isSetMath},
{"LibSBMLc::KineticLaw_isSetTimeUnits", _wrap_KineticLaw_isSetTimeUnits},
{"LibSBMLc::KineticLaw_isSetSubstanceUnits", _wrap_KineticLaw_isSetSubstanceUnits},
{"LibSBMLc::KineticLaw_setFormula", _wrap_KineticLaw_setFormula},
{"LibSBMLc::KineticLaw_setMath", _wrap_KineticLaw_setMath},
{"LibSBMLc::KineticLaw_setTimeUnits", _wrap_KineticLaw_setTimeUnits},
{"LibSBMLc::KineticLaw_setSubstanceUnits", _wrap_KineticLaw_setSubstanceUnits},
{"LibSBMLc::KineticLaw_unsetTimeUnits", _wrap_KineticLaw_unsetTimeUnits},
{"LibSBMLc::KineticLaw_unsetSubstanceUnits", _wrap_KineticLaw_unsetSubstanceUnits},
{"LibSBMLc::KineticLaw_addParameter", _wrap_KineticLaw_addParameter},
{"LibSBMLc::KineticLaw_addLocalParameter", _wrap_KineticLaw_addLocalParameter},
{"LibSBMLc::KineticLaw_createParameter", _wrap_KineticLaw_createParameter},
{"LibSBMLc::KineticLaw_createLocalParameter", _wrap_KineticLaw_createLocalParameter},
{"LibSBMLc::KineticLaw_getListOfParameters", _wrap_KineticLaw_getListOfParameters},
{"LibSBMLc::KineticLaw_getListOfLocalParameters", _wrap_KineticLaw_getListOfLocalParameters},
{"LibSBMLc::KineticLaw_getParameter", _wrap_KineticLaw_getParameter},
{"LibSBMLc::KineticLaw_getLocalParameter", _wrap_KineticLaw_getLocalParameter},
{"LibSBMLc::KineticLaw_getNumParameters", _wrap_KineticLaw_getNumParameters},
{"LibSBMLc::KineticLaw_getNumLocalParameters", _wrap_KineticLaw_getNumLocalParameters},
{"LibSBMLc::KineticLaw_getDerivedUnitDefinition", _wrap_KineticLaw_getDerivedUnitDefinition},
{"LibSBMLc::KineticLaw_containsUndeclaredUnits", _wrap_KineticLaw_containsUndeclaredUnits},
{"LibSBMLc::KineticLaw_removeParameter", _wrap_KineticLaw_removeParameter},
{"LibSBMLc::KineticLaw_removeLocalParameter", _wrap_KineticLaw_removeLocalParameter},
{"LibSBMLc::KineticLaw_getTypeCode", _wrap_KineticLaw_getTypeCode},
{"LibSBMLc::KineticLaw_getElementName", _wrap_KineticLaw_getElementName},
{"LibSBMLc::KineticLaw_hasRequiredAttributes", _wrap_KineticLaw_hasRequiredAttributes},
{"LibSBMLc::KineticLaw_hasRequiredElements", _wrap_KineticLaw_hasRequiredElements},
{"LibSBMLc::delete_SimpleSpeciesReference", _wrap_delete_SimpleSpeciesReference},
{"LibSBMLc::SimpleSpeciesReference_getId", _wrap_SimpleSpeciesReference_getId},
{"LibSBMLc::SimpleSpeciesReference_getName", _wrap_SimpleSpeciesReference_getName},
{"LibSBMLc::SimpleSpeciesReference_getSpecies", _wrap_SimpleSpeciesReference_getSpecies},
{"LibSBMLc::SimpleSpeciesReference_isSetId", _wrap_SimpleSpeciesReference_isSetId},
{"LibSBMLc::SimpleSpeciesReference_isSetName", _wrap_SimpleSpeciesReference_isSetName},
{"LibSBMLc::SimpleSpeciesReference_isSetSpecies", _wrap_SimpleSpeciesReference_isSetSpecies},
{"LibSBMLc::SimpleSpeciesReference_setSpecies", _wrap_SimpleSpeciesReference_setSpecies},
{"LibSBMLc::SimpleSpeciesReference_setId", _wrap_SimpleSpeciesReference_setId},
{"LibSBMLc::SimpleSpeciesReference_setName", _wrap_SimpleSpeciesReference_setName},
{"LibSBMLc::SimpleSpeciesReference_unsetId", _wrap_SimpleSpeciesReference_unsetId},
{"LibSBMLc::SimpleSpeciesReference_unsetName", _wrap_SimpleSpeciesReference_unsetName},
{"LibSBMLc::SimpleSpeciesReference_isModifier", _wrap_SimpleSpeciesReference_isModifier},
{"LibSBMLc::delete_SpeciesReference", _wrap_delete_SpeciesReference},
{"LibSBMLc::new_SpeciesReference", _wrap_new_SpeciesReference},
{"LibSBMLc::SpeciesReference_clone", _wrap_SpeciesReference_clone},
{"LibSBMLc::SpeciesReference_initDefaults", _wrap_SpeciesReference_initDefaults},
{"LibSBMLc::SpeciesReference_getStoichiometry", _wrap_SpeciesReference_getStoichiometry},
{"LibSBMLc::SpeciesReference_getStoichiometryMath", _wrap_SpeciesReference_getStoichiometryMath},
{"LibSBMLc::SpeciesReference_getDenominator", _wrap_SpeciesReference_getDenominator},
{"LibSBMLc::SpeciesReference_getConstant", _wrap_SpeciesReference_getConstant},
{"LibSBMLc::SpeciesReference_isSetStoichiometryMath", _wrap_SpeciesReference_isSetStoichiometryMath},
{"LibSBMLc::SpeciesReference_isSetConstant", _wrap_SpeciesReference_isSetConstant},
{"LibSBMLc::SpeciesReference_isSetStoichiometry", _wrap_SpeciesReference_isSetStoichiometry},
{"LibSBMLc::SpeciesReference_setStoichiometry", _wrap_SpeciesReference_setStoichiometry},
{"LibSBMLc::SpeciesReference_setStoichiometryMath", _wrap_SpeciesReference_setStoichiometryMath},
{"LibSBMLc::SpeciesReference_setDenominator", _wrap_SpeciesReference_setDenominator},
{"LibSBMLc::SpeciesReference_setConstant", _wrap_SpeciesReference_setConstant},
{"LibSBMLc::SpeciesReference_unsetStoichiometryMath", _wrap_SpeciesReference_unsetStoichiometryMath},
{"LibSBMLc::SpeciesReference_unsetStoichiometry", _wrap_SpeciesReference_unsetStoichiometry},
{"LibSBMLc::SpeciesReference_createStoichiometryMath", _wrap_SpeciesReference_createStoichiometryMath},
{"LibSBMLc::SpeciesReference_setAnnotation", _wrap_SpeciesReference_setAnnotation},
{"LibSBMLc::SpeciesReference_appendAnnotation", _wrap_SpeciesReference_appendAnnotation},
{"LibSBMLc::SpeciesReference_getTypeCode", _wrap_SpeciesReference_getTypeCode},
{"LibSBMLc::SpeciesReference_getElementName", _wrap_SpeciesReference_getElementName},
{"LibSBMLc::SpeciesReference_initL2Stoichiometry", _wrap_SpeciesReference_initL2Stoichiometry},
{"LibSBMLc::SpeciesReference_hasRequiredAttributes", _wrap_SpeciesReference_hasRequiredAttributes},
{"LibSBMLc::new_ModifierSpeciesReference", _wrap_new_ModifierSpeciesReference},
{"LibSBMLc::delete_ModifierSpeciesReference", _wrap_delete_ModifierSpeciesReference},
{"LibSBMLc::ModifierSpeciesReference_clone", _wrap_ModifierSpeciesReference_clone},
{"LibSBMLc::ModifierSpeciesReference_getTypeCode", _wrap_ModifierSpeciesReference_getTypeCode},
{"LibSBMLc::ModifierSpeciesReference_getElementName", _wrap_ModifierSpeciesReference_getElementName},
{"LibSBMLc::ModifierSpeciesReference_hasRequiredAttributes", _wrap_ModifierSpeciesReference_hasRequiredAttributes},
{"LibSBMLc::new_ListOfSpeciesReferences", _wrap_new_ListOfSpeciesReferences},
{"LibSBMLc::ListOfSpeciesReferences_clone", _wrap_ListOfSpeciesReferences_clone},
{"LibSBMLc::ListOfSpeciesReferences_getTypeCode", _wrap_ListOfSpeciesReferences_getTypeCode},
{"LibSBMLc::ListOfSpeciesReferences_getItemTypeCode", _wrap_ListOfSpeciesReferences_getItemTypeCode},
{"LibSBMLc::ListOfSpeciesReferences_getElementName", _wrap_ListOfSpeciesReferences_getElementName},
{"LibSBMLc::ListOfSpeciesReferences_get", _wrap_ListOfSpeciesReferences_get},
{"LibSBMLc::ListOfSpeciesReferences_remove", _wrap_ListOfSpeciesReferences_remove},
{"LibSBMLc::delete_ListOfSpeciesReferences", _wrap_delete_ListOfSpeciesReferences},
{"LibSBMLc::delete_Event", _wrap_delete_Event},
{"LibSBMLc::new_Event", _wrap_new_Event},
{"LibSBMLc::Event_clone", _wrap_Event_clone},
{"LibSBMLc::Event_getId", _wrap_Event_getId},
{"LibSBMLc::Event_getName", _wrap_Event_getName},
{"LibSBMLc::Event_getTrigger", _wrap_Event_getTrigger},
{"LibSBMLc::Event_getDelay", _wrap_Event_getDelay},
{"LibSBMLc::Event_getPriority", _wrap_Event_getPriority},
{"LibSBMLc::Event_getTimeUnits", _wrap_Event_getTimeUnits},
{"LibSBMLc::Event_getUseValuesFromTriggerTime", _wrap_Event_getUseValuesFromTriggerTime},
{"LibSBMLc::Event_isSetId", _wrap_Event_isSetId},
{"LibSBMLc::Event_isSetName", _wrap_Event_isSetName},
{"LibSBMLc::Event_isSetTrigger", _wrap_Event_isSetTrigger},
{"LibSBMLc::Event_isSetDelay", _wrap_Event_isSetDelay},
{"LibSBMLc::Event_isSetPriority", _wrap_Event_isSetPriority},
{"LibSBMLc::Event_isSetTimeUnits", _wrap_Event_isSetTimeUnits},
{"LibSBMLc::Event_isSetUseValuesFromTriggerTime", _wrap_Event_isSetUseValuesFromTriggerTime},
{"LibSBMLc::Event_setId", _wrap_Event_setId},
{"LibSBMLc::Event_setName", _wrap_Event_setName},
{"LibSBMLc::Event_setTrigger", _wrap_Event_setTrigger},
{"LibSBMLc::Event_setDelay", _wrap_Event_setDelay},
{"LibSBMLc::Event_setPriority", _wrap_Event_setPriority},
{"LibSBMLc::Event_setTimeUnits", _wrap_Event_setTimeUnits},
{"LibSBMLc::Event_setUseValuesFromTriggerTime", _wrap_Event_setUseValuesFromTriggerTime},
{"LibSBMLc::Event_unsetId", _wrap_Event_unsetId},
{"LibSBMLc::Event_unsetName", _wrap_Event_unsetName},
{"LibSBMLc::Event_unsetDelay", _wrap_Event_unsetDelay},
{"LibSBMLc::Event_unsetPriority", _wrap_Event_unsetPriority},
{"LibSBMLc::Event_unsetTimeUnits", _wrap_Event_unsetTimeUnits},
{"LibSBMLc::Event_addEventAssignment", _wrap_Event_addEventAssignment},
{"LibSBMLc::Event_createEventAssignment", _wrap_Event_createEventAssignment},
{"LibSBMLc::Event_createTrigger", _wrap_Event_createTrigger},
{"LibSBMLc::Event_createDelay", _wrap_Event_createDelay},
{"LibSBMLc::Event_createPriority", _wrap_Event_createPriority},
{"LibSBMLc::Event_getListOfEventAssignments", _wrap_Event_getListOfEventAssignments},
{"LibSBMLc::Event_getEventAssignment", _wrap_Event_getEventAssignment},
{"LibSBMLc::Event_getNumEventAssignments", _wrap_Event_getNumEventAssignments},
{"LibSBMLc::Event_removeEventAssignment", _wrap_Event_removeEventAssignment},
{"LibSBMLc::Event_getTypeCode", _wrap_Event_getTypeCode},
{"LibSBMLc::Event_getElementName", _wrap_Event_getElementName},
{"LibSBMLc::Event_hasRequiredAttributes", _wrap_Event_hasRequiredAttributes},
{"LibSBMLc::Event_hasRequiredElements", _wrap_Event_hasRequiredElements},
{"LibSBMLc::ListOfEvents_clone", _wrap_ListOfEvents_clone},
{"LibSBMLc::ListOfEvents_getTypeCode", _wrap_ListOfEvents_getTypeCode},
{"LibSBMLc::ListOfEvents_getItemTypeCode", _wrap_ListOfEvents_getItemTypeCode},
{"LibSBMLc::ListOfEvents_getElementName", _wrap_ListOfEvents_getElementName},
{"LibSBMLc::ListOfEvents_get", _wrap_ListOfEvents_get},
{"LibSBMLc::ListOfEvents_remove", _wrap_ListOfEvents_remove},
{"LibSBMLc::new_ListOfEvents", _wrap_new_ListOfEvents},
{"LibSBMLc::delete_ListOfEvents", _wrap_delete_ListOfEvents},
{"LibSBMLc::delete_EventAssignment", _wrap_delete_EventAssignment},
{"LibSBMLc::new_EventAssignment", _wrap_new_EventAssignment},
{"LibSBMLc::EventAssignment_clone", _wrap_EventAssignment_clone},
{"LibSBMLc::EventAssignment_getVariable", _wrap_EventAssignment_getVariable},
{"LibSBMLc::EventAssignment_getMath", _wrap_EventAssignment_getMath},
{"LibSBMLc::EventAssignment_isSetVariable", _wrap_EventAssignment_isSetVariable},
{"LibSBMLc::EventAssignment_isSetMath", _wrap_EventAssignment_isSetMath},
{"LibSBMLc::EventAssignment_setVariable", _wrap_EventAssignment_setVariable},
{"LibSBMLc::EventAssignment_setMath", _wrap_EventAssignment_setMath},
{"LibSBMLc::EventAssignment_getDerivedUnitDefinition", _wrap_EventAssignment_getDerivedUnitDefinition},
{"LibSBMLc::EventAssignment_containsUndeclaredUnits", _wrap_EventAssignment_containsUndeclaredUnits},
{"LibSBMLc::EventAssignment_getTypeCode", _wrap_EventAssignment_getTypeCode},
{"LibSBMLc::EventAssignment_getElementName", _wrap_EventAssignment_getElementName},
{"LibSBMLc::EventAssignment_hasRequiredAttributes", _wrap_EventAssignment_hasRequiredAttributes},
{"LibSBMLc::EventAssignment_hasRequiredElements", _wrap_EventAssignment_hasRequiredElements},
{"LibSBMLc::EventAssignment_getId", _wrap_EventAssignment_getId},
{"LibSBMLc::ListOfEventAssignments_clone", _wrap_ListOfEventAssignments_clone},
{"LibSBMLc::ListOfEventAssignments_getTypeCode", _wrap_ListOfEventAssignments_getTypeCode},
{"LibSBMLc::ListOfEventAssignments_getItemTypeCode", _wrap_ListOfEventAssignments_getItemTypeCode},
{"LibSBMLc::ListOfEventAssignments_getElementName", _wrap_ListOfEventAssignments_getElementName},
{"LibSBMLc::ListOfEventAssignments_get", _wrap_ListOfEventAssignments_get},
{"LibSBMLc::ListOfEventAssignments_remove", _wrap_ListOfEventAssignments_remove},
{"LibSBMLc::new_ListOfEventAssignments", _wrap_new_ListOfEventAssignments},
{"LibSBMLc::delete_ListOfEventAssignments", _wrap_delete_ListOfEventAssignments},
{"LibSBMLc::delete_Trigger", _wrap_delete_Trigger},
{"LibSBMLc::new_Trigger", _wrap_new_Trigger},
{"LibSBMLc::Trigger_clone", _wrap_Trigger_clone},
{"LibSBMLc::Trigger_getMath", _wrap_Trigger_getMath},
{"LibSBMLc::Trigger_getInitialValue", _wrap_Trigger_getInitialValue},
{"LibSBMLc::Trigger_getPersistent", _wrap_Trigger_getPersistent},
{"LibSBMLc::Trigger_isSetMath", _wrap_Trigger_isSetMath},
{"LibSBMLc::Trigger_isSetInitialValue", _wrap_Trigger_isSetInitialValue},
{"LibSBMLc::Trigger_isSetPersistent", _wrap_Trigger_isSetPersistent},
{"LibSBMLc::Trigger_setMath", _wrap_Trigger_setMath},
{"LibSBMLc::Trigger_setInitialValue", _wrap_Trigger_setInitialValue},
{"LibSBMLc::Trigger_setPersistent", _wrap_Trigger_setPersistent},
{"LibSBMLc::Trigger_getTypeCode", _wrap_Trigger_getTypeCode},
{"LibSBMLc::Trigger_getElementName", _wrap_Trigger_getElementName},
{"LibSBMLc::Trigger_hasRequiredElements", _wrap_Trigger_hasRequiredElements},
{"LibSBMLc::Trigger_hasRequiredAttributes", _wrap_Trigger_hasRequiredAttributes},
{"LibSBMLc::delete_Delay", _wrap_delete_Delay},
{"LibSBMLc::new_Delay", _wrap_new_Delay},
{"LibSBMLc::Delay_clone", _wrap_Delay_clone},
{"LibSBMLc::Delay_getMath", _wrap_Delay_getMath},
{"LibSBMLc::Delay_isSetMath", _wrap_Delay_isSetMath},
{"LibSBMLc::Delay_setMath", _wrap_Delay_setMath},
{"LibSBMLc::Delay_getDerivedUnitDefinition", _wrap_Delay_getDerivedUnitDefinition},
{"LibSBMLc::Delay_containsUndeclaredUnits", _wrap_Delay_containsUndeclaredUnits},
{"LibSBMLc::Delay_getTypeCode", _wrap_Delay_getTypeCode},
{"LibSBMLc::Delay_getElementName", _wrap_Delay_getElementName},
{"LibSBMLc::Delay_hasRequiredElements", _wrap_Delay_hasRequiredElements},
{"LibSBMLc::delete_Priority", _wrap_delete_Priority},
{"LibSBMLc::new_Priority", _wrap_new_Priority},
{"LibSBMLc::Priority_clone", _wrap_Priority_clone},
{"LibSBMLc::Priority_getMath", _wrap_Priority_getMath},
{"LibSBMLc::Priority_isSetMath", _wrap_Priority_isSetMath},
{"LibSBMLc::Priority_setMath", _wrap_Priority_setMath},
{"LibSBMLc::Priority_getTypeCode", _wrap_Priority_getTypeCode},
{"LibSBMLc::Priority_getElementName", _wrap_Priority_getElementName},
{"LibSBMLc::Priority_hasRequiredElements", _wrap_Priority_hasRequiredElements},
{"LibSBMLc::SBO_isQuantitativeParameter", _wrap_SBO_isQuantitativeParameter},
{"LibSBMLc::SBO_isParticipantRole", _wrap_SBO_isParticipantRole},
{"LibSBMLc::SBO_isModellingFramework", _wrap_SBO_isModellingFramework},
{"LibSBMLc::SBO_isMathematicalExpression", _wrap_SBO_isMathematicalExpression},
{"LibSBMLc::SBO_isKineticConstant", _wrap_SBO_isKineticConstant},
{"LibSBMLc::SBO_isReactant", _wrap_SBO_isReactant},
{"LibSBMLc::SBO_isProduct", _wrap_SBO_isProduct},
{"LibSBMLc::SBO_isModifier", _wrap_SBO_isModifier},
{"LibSBMLc::SBO_isRateLaw", _wrap_SBO_isRateLaw},
{"LibSBMLc::SBO_isEvent", _wrap_SBO_isEvent},
{"LibSBMLc::SBO_isPhysicalParticipant", _wrap_SBO_isPhysicalParticipant},
{"LibSBMLc::SBO_isParticipant", _wrap_SBO_isParticipant},
{"LibSBMLc::SBO_isInteraction", _wrap_SBO_isInteraction},
{"LibSBMLc::SBO_isEntity", _wrap_SBO_isEntity},
{"LibSBMLc::SBO_isFunctionalEntity", _wrap_SBO_isFunctionalEntity},
{"LibSBMLc::SBO_isMaterialEntity", _wrap_SBO_isMaterialEntity},
{"LibSBMLc::SBO_isConservationLaw", _wrap_SBO_isConservationLaw},
{"LibSBMLc::SBO_isSteadyStateExpression", _wrap_SBO_isSteadyStateExpression},
{"LibSBMLc::SBO_isFunctionalCompartment", _wrap_SBO_isFunctionalCompartment},
{"LibSBMLc::SBO_isContinuousFramework", _wrap_SBO_isContinuousFramework},
{"LibSBMLc::SBO_isDiscreteFramework", _wrap_SBO_isDiscreteFramework},
{"LibSBMLc::SBO_isLogicalFramework", _wrap_SBO_isLogicalFramework},
{"LibSBMLc::SBO_isObselete", _wrap_SBO_isObselete},
{"LibSBMLc::SBO_intToString", _wrap_SBO_intToString},
{"LibSBMLc::SBO_stringToInt", _wrap_SBO_stringToInt},
{"LibSBMLc::SBO_checkTerm", _wrap_SBO_checkTerm},
{"LibSBMLc::new_SBO", _wrap_new_SBO},
{"LibSBMLc::delete_SBO", _wrap_delete_SBO},
{"LibSBMLc::SyntaxChecker_isValidSBMLSId", _wrap_SyntaxChecker_isValidSBMLSId},
{"LibSBMLc::SyntaxChecker_isValidXMLID", _wrap_SyntaxChecker_isValidXMLID},
{"LibSBMLc::SyntaxChecker_isValidUnitSId", _wrap_SyntaxChecker_isValidUnitSId},
{"LibSBMLc::SyntaxChecker_hasExpectedXHTMLSyntax", _wrap_SyntaxChecker_hasExpectedXHTMLSyntax},
{"LibSBMLc::new_SyntaxChecker", _wrap_new_SyntaxChecker},
{"LibSBMLc::delete_SyntaxChecker", _wrap_delete_SyntaxChecker},
{"LibSBMLc::delete_StoichiometryMath", _wrap_delete_StoichiometryMath},
{"LibSBMLc::new_StoichiometryMath", _wrap_new_StoichiometryMath},
{"LibSBMLc::StoichiometryMath_clone", _wrap_StoichiometryMath_clone},
{"LibSBMLc::StoichiometryMath_getMath", _wrap_StoichiometryMath_getMath},
{"LibSBMLc::StoichiometryMath_isSetMath", _wrap_StoichiometryMath_isSetMath},
{"LibSBMLc::StoichiometryMath_setMath", _wrap_StoichiometryMath_setMath},
{"LibSBMLc::StoichiometryMath_getDerivedUnitDefinition", _wrap_StoichiometryMath_getDerivedUnitDefinition},
{"LibSBMLc::StoichiometryMath_containsUndeclaredUnits", _wrap_StoichiometryMath_containsUndeclaredUnits},
{"LibSBMLc::StoichiometryMath_getTypeCode", _wrap_StoichiometryMath_getTypeCode},
{"LibSBMLc::StoichiometryMath_getElementName", _wrap_StoichiometryMath_getElementName},
{"LibSBMLc::StoichiometryMath_hasRequiredElements", _wrap_StoichiometryMath_hasRequiredElements},
{"LibSBMLc::delete_SBMLNamespaces", _wrap_delete_SBMLNamespaces},
{"LibSBMLc::new_SBMLNamespaces", _wrap_new_SBMLNamespaces},
{"LibSBMLc::SBMLNamespaces_clone", _wrap_SBMLNamespaces_clone},
{"LibSBMLc::SBMLNamespaces_getSBMLNamespaceURI", _wrap_SBMLNamespaces_getSBMLNamespaceURI},
{"LibSBMLc::SBMLNamespaces_getSupportedNamespaces", _wrap_SBMLNamespaces_getSupportedNamespaces},
{"LibSBMLc::SBMLNamespaces_getLevel", _wrap_SBMLNamespaces_getLevel},
{"LibSBMLc::SBMLNamespaces_getVersion", _wrap_SBMLNamespaces_getVersion},
{"LibSBMLc::SBMLNamespaces_getNamespaces", _wrap_SBMLNamespaces_getNamespaces},
{"LibSBMLc::SBMLNamespaces_addNamespaces", _wrap_SBMLNamespaces_addNamespaces},
{"LibSBMLc::new_SBMLTransforms", _wrap_new_SBMLTransforms},
{"LibSBMLc::delete_SBMLTransforms", _wrap_delete_SBMLTransforms},
{"LibSBMLc::readMathMLFromString", _wrap_readMathMLFromString},
{"LibSBMLc::writeMathMLToString", _wrap_writeMathMLToString},
{"LibSBMLc::new_ASTNode", _wrap_new_ASTNode},
{"LibSBMLc::delete_ASTNode", _wrap_delete_ASTNode},
{"LibSBMLc::ASTNode_freeName", _wrap_ASTNode_freeName},
{"LibSBMLc::ASTNode_canonicalize", _wrap_ASTNode_canonicalize},
{"LibSBMLc::ASTNode_addChild", _wrap_ASTNode_addChild},
{"LibSBMLc::ASTNode_prependChild", _wrap_ASTNode_prependChild},
{"LibSBMLc::ASTNode_removeChild", _wrap_ASTNode_removeChild},
{"LibSBMLc::ASTNode_replaceChild", _wrap_ASTNode_replaceChild},
{"LibSBMLc::ASTNode_insertChild", _wrap_ASTNode_insertChild},
{"LibSBMLc::ASTNode_deepCopy", _wrap_ASTNode_deepCopy},
{"LibSBMLc::ASTNode_getChild", _wrap_ASTNode_getChild},
{"LibSBMLc::ASTNode_getLeftChild", _wrap_ASTNode_getLeftChild},
{"LibSBMLc::ASTNode_getRightChild", _wrap_ASTNode_getRightChild},
{"LibSBMLc::ASTNode_getNumChildren", _wrap_ASTNode_getNumChildren},
{"LibSBMLc::ASTNode_addSemanticsAnnotation", _wrap_ASTNode_addSemanticsAnnotation},
{"LibSBMLc::ASTNode_getNumSemanticsAnnotations", _wrap_ASTNode_getNumSemanticsAnnotations},
{"LibSBMLc::ASTNode_getSemanticsAnnotation", _wrap_ASTNode_getSemanticsAnnotation},
{"LibSBMLc::ASTNode_getCharacter", _wrap_ASTNode_getCharacter},
{"LibSBMLc::ASTNode_getInteger", _wrap_ASTNode_getInteger},
{"LibSBMLc::ASTNode_getName", _wrap_ASTNode_getName},
{"LibSBMLc::ASTNode_getNumerator", _wrap_ASTNode_getNumerator},
{"LibSBMLc::ASTNode_getDenominator", _wrap_ASTNode_getDenominator},
{"LibSBMLc::ASTNode_getReal", _wrap_ASTNode_getReal},
{"LibSBMLc::ASTNode_getMantissa", _wrap_ASTNode_getMantissa},
{"LibSBMLc::ASTNode_getExponent", _wrap_ASTNode_getExponent},
{"LibSBMLc::ASTNode_getPrecedence", _wrap_ASTNode_getPrecedence},
{"LibSBMLc::ASTNode_getType", _wrap_ASTNode_getType},
{"LibSBMLc::ASTNode_getUnits", _wrap_ASTNode_getUnits},
{"LibSBMLc::ASTNode_isBoolean", _wrap_ASTNode_isBoolean},
{"LibSBMLc::ASTNode_isConstant", _wrap_ASTNode_isConstant},
{"LibSBMLc::ASTNode_isFunction", _wrap_ASTNode_isFunction},
{"LibSBMLc::ASTNode_isInfinity", _wrap_ASTNode_isInfinity},
{"LibSBMLc::ASTNode_isInteger", _wrap_ASTNode_isInteger},
{"LibSBMLc::ASTNode_isLambda", _wrap_ASTNode_isLambda},
{"LibSBMLc::ASTNode_isLog10", _wrap_ASTNode_isLog10},
{"LibSBMLc::ASTNode_isLogical", _wrap_ASTNode_isLogical},
{"LibSBMLc::ASTNode_isName", _wrap_ASTNode_isName},
{"LibSBMLc::ASTNode_isNaN", _wrap_ASTNode_isNaN},
{"LibSBMLc::ASTNode_isNegInfinity", _wrap_ASTNode_isNegInfinity},
{"LibSBMLc::ASTNode_isNumber", _wrap_ASTNode_isNumber},
{"LibSBMLc::ASTNode_isOperator", _wrap_ASTNode_isOperator},
{"LibSBMLc::ASTNode_isPiecewise", _wrap_ASTNode_isPiecewise},
{"LibSBMLc::ASTNode_isRational", _wrap_ASTNode_isRational},
{"LibSBMLc::ASTNode_isReal", _wrap_ASTNode_isReal},
{"LibSBMLc::ASTNode_isRelational", _wrap_ASTNode_isRelational},
{"LibSBMLc::ASTNode_isSqrt", _wrap_ASTNode_isSqrt},
{"LibSBMLc::ASTNode_isUMinus", _wrap_ASTNode_isUMinus},
{"LibSBMLc::ASTNode_isUnknown", _wrap_ASTNode_isUnknown},
{"LibSBMLc::ASTNode_isSetUnits", _wrap_ASTNode_isSetUnits},
{"LibSBMLc::ASTNode_hasUnits", _wrap_ASTNode_hasUnits},
{"LibSBMLc::ASTNode_setCharacter", _wrap_ASTNode_setCharacter},
{"LibSBMLc::ASTNode_setName", _wrap_ASTNode_setName},
{"LibSBMLc::ASTNode_setValue", _wrap_ASTNode_setValue},
{"LibSBMLc::ASTNode_setType", _wrap_ASTNode_setType},
{"LibSBMLc::ASTNode_setUnits", _wrap_ASTNode_setUnits},
{"LibSBMLc::ASTNode_swapChildren", _wrap_ASTNode_swapChildren},
{"LibSBMLc::ASTNode_unsetUnits", _wrap_ASTNode_unsetUnits},
{"LibSBMLc::ASTNode_getDefinitionURL", _wrap_ASTNode_getDefinitionURL},
{"LibSBMLc::ASTNode_replaceArgument", _wrap_ASTNode_replaceArgument},
{"LibSBMLc::ASTNode_getParentSBMLObject", _wrap_ASTNode_getParentSBMLObject},
{"LibSBMLc::ASTNode_reduceToBinary", _wrap_ASTNode_reduceToBinary},
{"LibSBMLc::ASTNode_isWellFormedASTNode", _wrap_ASTNode_isWellFormedASTNode},
{"LibSBMLc::ASTNode_hasCorrectNumberArguments", _wrap_ASTNode_hasCorrectNumberArguments},
{"LibSBMLc::ASTNode_isBvar", _wrap_ASTNode_isBvar},
{"LibSBMLc::ASTNode_setBvar", _wrap_ASTNode_setBvar},
{"LibSBMLc::ASTNode_getListOfNodes", _wrap_ASTNode_getListOfNodes},
{"LibSBMLc::parseFormula", _wrap_parseFormula},
{"LibSBMLc::formulaToString", _wrap_formulaToString},
{"LibSBMLc::new_XMLConstructorException", _wrap_new_XMLConstructorException},
{"LibSBMLc::delete_XMLConstructorException", _wrap_delete_XMLConstructorException},
{"LibSBMLc::delete_XMLAttributes", _wrap_delete_XMLAttributes},
{"LibSBMLc::new_XMLAttributes", _wrap_new_XMLAttributes},
{"LibSBMLc::XMLAttributes_clone", _wrap_XMLAttributes_clone},
{"LibSBMLc::XMLAttributes_add", _wrap_XMLAttributes_add},
{"LibSBMLc::XMLAttributes_removeResource", _wrap_XMLAttributes_removeResource},
{"LibSBMLc::XMLAttributes_remove", _wrap_XMLAttributes_remove},
{"LibSBMLc::XMLAttributes_clear", _wrap_XMLAttributes_clear},
{"LibSBMLc::XMLAttributes_getIndex", _wrap_XMLAttributes_getIndex},
{"LibSBMLc::XMLAttributes_getLength", _wrap_XMLAttributes_getLength},
{"LibSBMLc::XMLAttributes_getName", _wrap_XMLAttributes_getName},
{"LibSBMLc::XMLAttributes_getPrefix", _wrap_XMLAttributes_getPrefix},
{"LibSBMLc::XMLAttributes_getPrefixedName", _wrap_XMLAttributes_getPrefixedName},
{"LibSBMLc::XMLAttributes_getURI", _wrap_XMLAttributes_getURI},
{"LibSBMLc::XMLAttributes_getValue", _wrap_XMLAttributes_getValue},
{"LibSBMLc::XMLAttributes_hasAttribute", _wrap_XMLAttributes_hasAttribute},
{"LibSBMLc::XMLAttributes_isEmpty", _wrap_XMLAttributes_isEmpty},
{"LibSBMLc::delete_XMLNamespaces", _wrap_delete_XMLNamespaces},
{"LibSBMLc::new_XMLNamespaces", _wrap_new_XMLNamespaces},
{"LibSBMLc::XMLNamespaces_clone", _wrap_XMLNamespaces_clone},
{"LibSBMLc::XMLNamespaces_add", _wrap_XMLNamespaces_add},
{"LibSBMLc::XMLNamespaces_remove", _wrap_XMLNamespaces_remove},
{"LibSBMLc::XMLNamespaces_clear", _wrap_XMLNamespaces_clear},
{"LibSBMLc::XMLNamespaces_getIndex", _wrap_XMLNamespaces_getIndex},
{"LibSBMLc::XMLNamespaces_getIndexByPrefix", _wrap_XMLNamespaces_getIndexByPrefix},
{"LibSBMLc::XMLNamespaces_getLength", _wrap_XMLNamespaces_getLength},
{"LibSBMLc::XMLNamespaces_getPrefix", _wrap_XMLNamespaces_getPrefix},
{"LibSBMLc::XMLNamespaces_getURI", _wrap_XMLNamespaces_getURI},
{"LibSBMLc::XMLNamespaces_isEmpty", _wrap_XMLNamespaces_isEmpty},
{"LibSBMLc::XMLNamespaces_hasURI", _wrap_XMLNamespaces_hasURI},
{"LibSBMLc::XMLNamespaces_hasPrefix", _wrap_XMLNamespaces_hasPrefix},
{"LibSBMLc::XMLNamespaces_hasNS", _wrap_XMLNamespaces_hasNS},
{"LibSBMLc::delete_XMLToken", _wrap_delete_XMLToken},
{"LibSBMLc::new_XMLToken", _wrap_new_XMLToken},
{"LibSBMLc::XMLToken_clone", _wrap_XMLToken_clone},
{"LibSBMLc::XMLToken_getAttributes", _wrap_XMLToken_getAttributes},
{"LibSBMLc::XMLToken_setAttributes", _wrap_XMLToken_setAttributes},
{"LibSBMLc::XMLToken_addAttr", _wrap_XMLToken_addAttr},
{"LibSBMLc::XMLToken_removeAttr", _wrap_XMLToken_removeAttr},
{"LibSBMLc::XMLToken_clearAttributes", _wrap_XMLToken_clearAttributes},
{"LibSBMLc::XMLToken_getAttrIndex", _wrap_XMLToken_getAttrIndex},
{"LibSBMLc::XMLToken_getAttributesLength", _wrap_XMLToken_getAttributesLength},
{"LibSBMLc::XMLToken_getAttrName", _wrap_XMLToken_getAttrName},
{"LibSBMLc::XMLToken_getAttrPrefix", _wrap_XMLToken_getAttrPrefix},
{"LibSBMLc::XMLToken_getAttrPrefixedName", _wrap_XMLToken_getAttrPrefixedName},
{"LibSBMLc::XMLToken_getAttrURI", _wrap_XMLToken_getAttrURI},
{"LibSBMLc::XMLToken_getAttrValue", _wrap_XMLToken_getAttrValue},
{"LibSBMLc::XMLToken_hasAttr", _wrap_XMLToken_hasAttr},
{"LibSBMLc::XMLToken_isAttributesEmpty", _wrap_XMLToken_isAttributesEmpty},
{"LibSBMLc::XMLToken_getNamespaces", _wrap_XMLToken_getNamespaces},
{"LibSBMLc::XMLToken_setNamespaces", _wrap_XMLToken_setNamespaces},
{"LibSBMLc::XMLToken_addNamespace", _wrap_XMLToken_addNamespace},
{"LibSBMLc::XMLToken_removeNamespace", _wrap_XMLToken_removeNamespace},
{"LibSBMLc::XMLToken_clearNamespaces", _wrap_XMLToken_clearNamespaces},
{"LibSBMLc::XMLToken_getNamespaceIndex", _wrap_XMLToken_getNamespaceIndex},
{"LibSBMLc::XMLToken_getNamespaceIndexByPrefix", _wrap_XMLToken_getNamespaceIndexByPrefix},
{"LibSBMLc::XMLToken_getNamespacesLength", _wrap_XMLToken_getNamespacesLength},
{"LibSBMLc::XMLToken_getNamespacePrefix", _wrap_XMLToken_getNamespacePrefix},
{"LibSBMLc::XMLToken_getNamespaceURI", _wrap_XMLToken_getNamespaceURI},
{"LibSBMLc::XMLToken_isNamespacesEmpty", _wrap_XMLToken_isNamespacesEmpty},
{"LibSBMLc::XMLToken_hasNamespaceURI", _wrap_XMLToken_hasNamespaceURI},
{"LibSBMLc::XMLToken_hasNamespacePrefix", _wrap_XMLToken_hasNamespacePrefix},
{"LibSBMLc::XMLToken_hasNamespaceNS", _wrap_XMLToken_hasNamespaceNS},
{"LibSBMLc::XMLToken_setTriple", _wrap_XMLToken_setTriple},
{"LibSBMLc::XMLToken_getName", _wrap_XMLToken_getName},
{"LibSBMLc::XMLToken_getPrefix", _wrap_XMLToken_getPrefix},
{"LibSBMLc::XMLToken_getURI", _wrap_XMLToken_getURI},
{"LibSBMLc::XMLToken_getCharacters", _wrap_XMLToken_getCharacters},
{"LibSBMLc::XMLToken_append", _wrap_XMLToken_append},
{"LibSBMLc::XMLToken_getColumn", _wrap_XMLToken_getColumn},
{"LibSBMLc::XMLToken_getLine", _wrap_XMLToken_getLine},
{"LibSBMLc::XMLToken_isElement", _wrap_XMLToken_isElement},
{"LibSBMLc::XMLToken_isEnd", _wrap_XMLToken_isEnd},
{"LibSBMLc::XMLToken_isEndFor", _wrap_XMLToken_isEndFor},
{"LibSBMLc::XMLToken_isEOF", _wrap_XMLToken_isEOF},
{"LibSBMLc::XMLToken_isStart", _wrap_XMLToken_isStart},
{"LibSBMLc::XMLToken_isText", _wrap_XMLToken_isText},
{"LibSBMLc::XMLToken_setEnd", _wrap_XMLToken_setEnd},
{"LibSBMLc::XMLToken_setEOF", _wrap_XMLToken_setEOF},
{"LibSBMLc::XMLToken_unsetEnd", _wrap_XMLToken_unsetEnd},
{"LibSBMLc::XMLToken_toString", _wrap_XMLToken_toString},
{"LibSBMLc::delete_XMLNode", _wrap_delete_XMLNode},
{"LibSBMLc::new_XMLNode", _wrap_new_XMLNode},
{"LibSBMLc::XMLNode_clone", _wrap_XMLNode_clone},
{"LibSBMLc::XMLNode_addChild", _wrap_XMLNode_addChild},
{"LibSBMLc::XMLNode_insertChild", _wrap_XMLNode_insertChild},
{"LibSBMLc::XMLNode_removeChild", _wrap_XMLNode_removeChild},
{"LibSBMLc::XMLNode_removeChildren", _wrap_XMLNode_removeChildren},
{"LibSBMLc::XMLNode_getChild", _wrap_XMLNode_getChild},
{"LibSBMLc::XMLNode_getIndex", _wrap_XMLNode_getIndex},
{"LibSBMLc::XMLNode_hasChild", _wrap_XMLNode_hasChild},
{"LibSBMLc::XMLNode_equals", _wrap_XMLNode_equals},
{"LibSBMLc::XMLNode_getNumChildren", _wrap_XMLNode_getNumChildren},
{"LibSBMLc::XMLNode_toXMLString", _wrap_XMLNode_toXMLString},
{"LibSBMLc::XMLNode_convertXMLNodeToString", _wrap_XMLNode_convertXMLNodeToString},
{"LibSBMLc::XMLNode_convertStringToXMLNode", _wrap_XMLNode_convertStringToXMLNode},
{"LibSBMLc::new_XMLTriple", _wrap_new_XMLTriple},
{"LibSBMLc::XMLTriple_clone", _wrap_XMLTriple_clone},
{"LibSBMLc::XMLTriple_getName", _wrap_XMLTriple_getName},
{"LibSBMLc::XMLTriple_getPrefix", _wrap_XMLTriple_getPrefix},
{"LibSBMLc::XMLTriple_getURI", _wrap_XMLTriple_getURI},
{"LibSBMLc::XMLTriple_getPrefixedName", _wrap_XMLTriple_getPrefixedName},
{"LibSBMLc::XMLTriple_isEmpty", _wrap_XMLTriple_isEmpty},
{"LibSBMLc::delete_XMLTriple", _wrap_delete_XMLTriple},
{"LibSBMLc::new_XMLOutputStream", _wrap_new_XMLOutputStream},
{"LibSBMLc::XMLOutputStream_endElement", _wrap_XMLOutputStream_endElement},
{"LibSBMLc::XMLOutputStream_setAutoIndent", _wrap_XMLOutputStream_setAutoIndent},
{"LibSBMLc::XMLOutputStream_startElement", _wrap_XMLOutputStream_startElement},
{"LibSBMLc::XMLOutputStream_startEndElement", _wrap_XMLOutputStream_startEndElement},
{"LibSBMLc::XMLOutputStream_writeAttribute", _wrap_XMLOutputStream_writeAttribute},
{"LibSBMLc::XMLOutputStream_writeXMLDecl", _wrap_XMLOutputStream_writeXMLDecl},
{"LibSBMLc::XMLOutputStream_writeComment", _wrap_XMLOutputStream_writeComment},
{"LibSBMLc::XMLOutputStream_downIndent", _wrap_XMLOutputStream_downIndent},
{"LibSBMLc::XMLOutputStream_upIndent", _wrap_XMLOutputStream_upIndent},
{"LibSBMLc::delete_XMLOutputStream", _wrap_delete_XMLOutputStream},
{"LibSBMLc::new_XMLError", _wrap_new_XMLError},
{"LibSBMLc::delete_XMLError", _wrap_delete_XMLError},
{"LibSBMLc::XMLError_getErrorId", _wrap_XMLError_getErrorId},
{"LibSBMLc::XMLError_getMessage", _wrap_XMLError_getMessage},
{"LibSBMLc::XMLError_getShortMessage", _wrap_XMLError_getShortMessage},
{"LibSBMLc::XMLError_getLine", _wrap_XMLError_getLine},
{"LibSBMLc::XMLError_getColumn", _wrap_XMLError_getColumn},
{"LibSBMLc::XMLError_getSeverity", _wrap_XMLError_getSeverity},
{"LibSBMLc::XMLError_getSeverityAsString", _wrap_XMLError_getSeverityAsString},
{"LibSBMLc::XMLError_getCategory", _wrap_XMLError_getCategory},
{"LibSBMLc::XMLError_getCategoryAsString", _wrap_XMLError_getCategoryAsString},
{"LibSBMLc::XMLError_isInfo", _wrap_XMLError_isInfo},
{"LibSBMLc::XMLError_isWarning", _wrap_XMLError_isWarning},
{"LibSBMLc::XMLError_isError", _wrap_XMLError_isError},
{"LibSBMLc::XMLError_isFatal", _wrap_XMLError_isFatal},
{"LibSBMLc::XMLError_isInternal", _wrap_XMLError_isInternal},
{"LibSBMLc::XMLError_isSystem", _wrap_XMLError_isSystem},
{"LibSBMLc::XMLError_isXML", _wrap_XMLError_isXML},
{"LibSBMLc::XMLError_setLine", _wrap_XMLError_setLine},
{"LibSBMLc::XMLError_setColumn", _wrap_XMLError_setColumn},
{"LibSBMLc::XMLError_getStandardMessage", _wrap_XMLError_getStandardMessage},
{"LibSBMLc::XMLErrorLog_getNumErrors", _wrap_XMLErrorLog_getNumErrors},
{"LibSBMLc::XMLErrorLog_getError", _wrap_XMLErrorLog_getError},
{"LibSBMLc::XMLErrorLog_clearLog", _wrap_XMLErrorLog_clearLog},
{"LibSBMLc::delete_XMLErrorLog", _wrap_delete_XMLErrorLog},
{"LibSBMLc::SBMLErrorLog_getError", _wrap_SBMLErrorLog_getError},
{"LibSBMLc::SBMLErrorLog_getNumFailsWithSeverity", _wrap_SBMLErrorLog_getNumFailsWithSeverity},
{"LibSBMLc::delete_SBMLErrorLog", _wrap_delete_SBMLErrorLog},
{"LibSBMLc::new_SBMLError", _wrap_new_SBMLError},
{"LibSBMLc::delete_SBMLError", _wrap_delete_SBMLError},
{"LibSBMLc::delete_CVTerm", _wrap_delete_CVTerm},
{"LibSBMLc::new_CVTerm", _wrap_new_CVTerm},
{"LibSBMLc::CVTerm_clone", _wrap_CVTerm_clone},
{"LibSBMLc::CVTerm_getQualifierType", _wrap_CVTerm_getQualifierType},
{"LibSBMLc::CVTerm_getModelQualifierType", _wrap_CVTerm_getModelQualifierType},
{"LibSBMLc::CVTerm_getBiologicalQualifierType", _wrap_CVTerm_getBiologicalQualifierType},
{"LibSBMLc::CVTerm_getResources", _wrap_CVTerm_getResources},
{"LibSBMLc::CVTerm_getNumResources", _wrap_CVTerm_getNumResources},
{"LibSBMLc::CVTerm_getResourceURI", _wrap_CVTerm_getResourceURI},
{"LibSBMLc::CVTerm_setQualifierType", _wrap_CVTerm_setQualifierType},
{"LibSBMLc::CVTerm_setModelQualifierType", _wrap_CVTerm_setModelQualifierType},
{"LibSBMLc::CVTerm_setBiologicalQualifierType", _wrap_CVTerm_setBiologicalQualifierType},
{"LibSBMLc::CVTerm_addResource", _wrap_CVTerm_addResource},
{"LibSBMLc::CVTerm_removeResource", _wrap_CVTerm_removeResource},
{"LibSBMLc::CVTerm_hasRequiredAttributes", _wrap_CVTerm_hasRequiredAttributes},
{"LibSBMLc::delete_Date", _wrap_delete_Date},
{"LibSBMLc::new_Date", _wrap_new_Date},
{"LibSBMLc::Date_clone", _wrap_Date_clone},
{"LibSBMLc::Date_getYear", _wrap_Date_getYear},
{"LibSBMLc::Date_getMonth", _wrap_Date_getMonth},
{"LibSBMLc::Date_getDay", _wrap_Date_getDay},
{"LibSBMLc::Date_getHour", _wrap_Date_getHour},
{"LibSBMLc::Date_getMinute", _wrap_Date_getMinute},
{"LibSBMLc::Date_getSecond", _wrap_Date_getSecond},
{"LibSBMLc::Date_getSignOffset", _wrap_Date_getSignOffset},
{"LibSBMLc::Date_getHoursOffset", _wrap_Date_getHoursOffset},
{"LibSBMLc::Date_getMinutesOffset", _wrap_Date_getMinutesOffset},
{"LibSBMLc::Date_getDateAsString", _wrap_Date_getDateAsString},
{"LibSBMLc::Date_setYear", _wrap_Date_setYear},
{"LibSBMLc::Date_setMonth", _wrap_Date_setMonth},
{"LibSBMLc::Date_setDay", _wrap_Date_setDay},
{"LibSBMLc::Date_setHour", _wrap_Date_setHour},
{"LibSBMLc::Date_setMinute", _wrap_Date_setMinute},
{"LibSBMLc::Date_setSecond", _wrap_Date_setSecond},
{"LibSBMLc::Date_setSignOffset", _wrap_Date_setSignOffset},
{"LibSBMLc::Date_setHoursOffset", _wrap_Date_setHoursOffset},
{"LibSBMLc::Date_setMinutesOffset", _wrap_Date_setMinutesOffset},
{"LibSBMLc::Date_setDateAsString", _wrap_Date_setDateAsString},
{"LibSBMLc::Date_representsValidDate", _wrap_Date_representsValidDate},
{"LibSBMLc::delete_ModelCreator", _wrap_delete_ModelCreator},
{"LibSBMLc::new_ModelCreator", _wrap_new_ModelCreator},
{"LibSBMLc::ModelCreator_clone", _wrap_ModelCreator_clone},
{"LibSBMLc::ModelCreator_getFamilyName", _wrap_ModelCreator_getFamilyName},
{"LibSBMLc::ModelCreator_getGivenName", _wrap_ModelCreator_getGivenName},
{"LibSBMLc::ModelCreator_getEmail", _wrap_ModelCreator_getEmail},
{"LibSBMLc::ModelCreator_getOrganization", _wrap_ModelCreator_getOrganization},
{"LibSBMLc::ModelCreator_getOrganisation", _wrap_ModelCreator_getOrganisation},
{"LibSBMLc::ModelCreator_isSetFamilyName", _wrap_ModelCreator_isSetFamilyName},
{"LibSBMLc::ModelCreator_isSetGivenName", _wrap_ModelCreator_isSetGivenName},
{"LibSBMLc::ModelCreator_isSetEmail", _wrap_ModelCreator_isSetEmail},
{"LibSBMLc::ModelCreator_isSetOrganization", _wrap_ModelCreator_isSetOrganization},
{"LibSBMLc::ModelCreator_isSetOrganisation", _wrap_ModelCreator_isSetOrganisation},
{"LibSBMLc::ModelCreator_setFamilyName", _wrap_ModelCreator_setFamilyName},
{"LibSBMLc::ModelCreator_setGivenName", _wrap_ModelCreator_setGivenName},
{"LibSBMLc::ModelCreator_setEmail", _wrap_ModelCreator_setEmail},
{"LibSBMLc::ModelCreator_setOrganization", _wrap_ModelCreator_setOrganization},
{"LibSBMLc::ModelCreator_setOrganisation", _wrap_ModelCreator_setOrganisation},
{"LibSBMLc::ModelCreator_unsetFamilyName", _wrap_ModelCreator_unsetFamilyName},
{"LibSBMLc::ModelCreator_unsetGivenName", _wrap_ModelCreator_unsetGivenName},
{"LibSBMLc::ModelCreator_unsetEmail", _wrap_ModelCreator_unsetEmail},
{"LibSBMLc::ModelCreator_unsetOrganization", _wrap_ModelCreator_unsetOrganization},
{"LibSBMLc::ModelCreator_unsetOrganisation", _wrap_ModelCreator_unsetOrganisation},
{"LibSBMLc::ModelCreator_hasRequiredAttributes", _wrap_ModelCreator_hasRequiredAttributes},
{"LibSBMLc::delete_ModelHistory", _wrap_delete_ModelHistory},
{"LibSBMLc::new_ModelHistory", _wrap_new_ModelHistory},
{"LibSBMLc::ModelHistory_clone", _wrap_ModelHistory_clone},
{"LibSBMLc::ModelHistory_getCreatedDate", _wrap_ModelHistory_getCreatedDate},
{"LibSBMLc::ModelHistory_isSetCreatedDate", _wrap_ModelHistory_isSetCreatedDate},
{"LibSBMLc::ModelHistory_isSetModifiedDate", _wrap_ModelHistory_isSetModifiedDate},
{"LibSBMLc::ModelHistory_setCreatedDate", _wrap_ModelHistory_setCreatedDate},
{"LibSBMLc::ModelHistory_setModifiedDate", _wrap_ModelHistory_setModifiedDate},
{"LibSBMLc::ModelHistory_addModifiedDate", _wrap_ModelHistory_addModifiedDate},
{"LibSBMLc::ModelHistory_getListModifiedDates", _wrap_ModelHistory_getListModifiedDates},
{"LibSBMLc::ModelHistory_getModifiedDate", _wrap_ModelHistory_getModifiedDate},
{"LibSBMLc::ModelHistory_getNumModifiedDates", _wrap_ModelHistory_getNumModifiedDates},
{"LibSBMLc::ModelHistory_addCreator", _wrap_ModelHistory_addCreator},
{"LibSBMLc::ModelHistory_getListCreators", _wrap_ModelHistory_getListCreators},
{"LibSBMLc::ModelHistory_getCreator", _wrap_ModelHistory_getCreator},
{"LibSBMLc::ModelHistory_getNumCreators", _wrap_ModelHistory_getNumCreators},
{"LibSBMLc::ModelHistory_hasRequiredAttributes", _wrap_ModelHistory_hasRequiredAttributes},
{"LibSBMLc::RDFAnnotationParser_createAnnotation", _wrap_RDFAnnotationParser_createAnnotation},
{"LibSBMLc::RDFAnnotationParser_createRDFAnnotation", _wrap_RDFAnnotationParser_createRDFAnnotation},
{"LibSBMLc::RDFAnnotationParser_deleteRDFAnnotation", _wrap_RDFAnnotationParser_deleteRDFAnnotation},
{"LibSBMLc::RDFAnnotationParser_createRDFDescription", _wrap_RDFAnnotationParser_createRDFDescription},
{"LibSBMLc::RDFAnnotationParser_createCVTerms", _wrap_RDFAnnotationParser_createCVTerms},
{"LibSBMLc::RDFAnnotationParser_parseCVTerms", _wrap_RDFAnnotationParser_parseCVTerms},
{"LibSBMLc::RDFAnnotationParser_parseModelHistory", _wrap_RDFAnnotationParser_parseModelHistory},
{"LibSBMLc::RDFAnnotationParser_parseRDFAnnotation", _wrap_RDFAnnotationParser_parseRDFAnnotation},
{"LibSBMLc::new_RDFAnnotationParser", _wrap_new_RDFAnnotationParser},
{"LibSBMLc::delete_RDFAnnotationParser", _wrap_delete_RDFAnnotationParser},
{0,0}
};
/* -----------------------------------------------------------------------------
 * Type initialization:
 * This problem is tough by the requirement that no dynamic 
 * memory is used. Also, since swig_type_info structures store pointers to 
 * 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 
 * 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 
 * 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
 * cast linked list. The cast data is initially stored in something like a
 * two-dimensional array. Each row corresponds to a type (there are the same
 * number of rows as there are in the swig_type_initial array). Each entry in
 * 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 
 * 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. 
 * 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 
 *     cast->type) are loaded, THEN the cast info has already been loaded by
 *     the previous module so we just ignore it.
 *  3) Finally, if cast->type has not already been loaded, then we add that
 *     swig_cast_info to the linked list (because the cast->type) pointer will
 *     be correct.
 * ----------------------------------------------------------------------------- */

#ifdef __cplusplus
extern "C" {
#if 0
} /* c-mode */
#endif
#endif

#if 0
#define SWIGRUNTIME_DEBUG
#endif


SWIGRUNTIME void
SWIG_InitializeModule(void *clientdata) {
  size_t i;
  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 */
    swig_module.type_initial = swig_type_initial;
    swig_module.cast_initial = swig_cast_initial;
    swig_module.next = &swig_module;
    init = 1;
  } else {
    init = 0;
  }
  
  /* Try and load any already created modules */
  module_head = SWIG_GetModule(clientdata);
  if (!module_head) {
    /* This is the first module loaded for this interpreter */
    /* so set the swig module into the interpreter */
    SWIG_SetModule(clientdata, &swig_module);
    module_head = &swig_module;
  } else {
    /* the interpreter has loaded a SWIG module, but has it loaded this one? */
    found=0;
    iter=module_head;
    do {
      if (iter==&swig_module) {
        found=1;
        break;
      }
      iter=iter->next;
    } while (iter!= module_head);
    
    /* if the is found in the list, then all is done and we may leave */
    if (found) return;
    /* otherwise we must add out module into the list */
    swig_module.next = module_head->next;
    module_head->next = &swig_module;
  }
  
  /* When multiple interpeters 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 */
  if (init == 0) return;
  
  /* Now work on filling in swig_module.types */
#ifdef SWIGRUNTIME_DEBUG
  printf("SWIG_InitializeModule: size %d\n", swig_module.size);
#endif
  for (i = 0; i < swig_module.size; ++i) {
    swig_type_info *type = 0;
    swig_type_info *ret;
    swig_cast_info *cast;
    
#ifdef SWIGRUNTIME_DEBUG
    printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
#endif
    
    /* if there is another module already loaded */
    if (swig_module.next != &swig_module) {
      type = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, swig_module.type_initial[i]->name);
    }
    if (type) {
      /* Overwrite clientdata field */
#ifdef SWIGRUNTIME_DEBUG
      printf("SWIG_InitializeModule: found type %s\n", type->name);
#endif
      if (swig_module.type_initial[i]->clientdata) {
        type->clientdata = swig_module.type_initial[i]->clientdata;
#ifdef SWIGRUNTIME_DEBUG
        printf("SWIG_InitializeModule: found and overwrite type %s \n", type->name);
#endif
      }
    } else {
      type = swig_module.type_initial[i];
    }
    
    /* Insert casting types */
    cast = swig_module.cast_initial[i];
    while (cast->type) {
      /* Don't need to add information already in the list */
      ret = 0;
#ifdef SWIGRUNTIME_DEBUG
      printf("SWIG_InitializeModule: look cast %s\n", cast->type->name);
#endif
      if (swig_module.next != &swig_module) {
        ret = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, cast->type->name);
#ifdef SWIGRUNTIME_DEBUG
        if (ret) printf("SWIG_InitializeModule: found cast %s\n", ret->name);
#endif
      }
      if (ret) {
        if (type == swig_module.type_initial[i]) {
#ifdef SWIGRUNTIME_DEBUG
          printf("SWIG_InitializeModule: skip old type %s\n", ret->name);
#endif
          cast->type = ret;
          ret = 0;
        } else {
          /* Check for casting already in the list */
          swig_cast_info *ocast = SWIG_TypeCheck(ret->name, type);
#ifdef SWIGRUNTIME_DEBUG
          if (ocast) printf("SWIG_InitializeModule: skip old cast %s\n", ret->name);
#endif
          if (!ocast) ret = 0;
        }
      }
      
      if (!ret) {
#ifdef SWIGRUNTIME_DEBUG
        printf("SWIG_InitializeModule: adding cast %s\n", cast->type->name);
#endif
        if (type->cast) {
          type->cast->prev = cast;
          cast->next = type->cast;
        }
        type->cast = cast;
      }
      cast++;
    }
    /* Set entry in modules->types array equal to the type */
    swig_module.types[i] = type;
  }
  swig_module.types[i] = 0;
  
#ifdef SWIGRUNTIME_DEBUG
  printf("**** SWIG_InitializeModule: Cast List ******\n");
  for (i = 0; i < swig_module.size; ++i) {
    int j = 0;
    swig_cast_info *cast = swig_module.cast_initial[i];
    printf("SWIG_InitializeModule: type %d %s\n", i, swig_module.type_initial[i]->name);
    while (cast->type) {
      printf("SWIG_InitializeModule: cast type %s\n", cast->type->name);
      cast++;
      ++j;
    }
    printf("---- Total casts: %d\n",j);
  }
  printf("**** SWIG_InitializeModule: Cast List ******\n");
#endif
}

/* This function will propagate the clientdata field of type to
* any new swig_type_info structures that have been added into the list
* of equivalent types.  It is like calling
* SWIG_TypeClientData(type, clientdata) a second time.
*/
SWIGRUNTIME void
SWIG_PropagateClientData(void) {
  size_t i;
  swig_cast_info *equiv;
  static int init_run = 0;
  
  if (init_run) return;
  init_run = 1;
  
  for (i = 0; i < swig_module.size; i++) {
    if (swig_module.types[i]->clientdata) {
      equiv = swig_module.types[i]->cast;
      while (equiv) {
        if (!equiv->converter) {
          if (equiv->type && !equiv->type->clientdata)
          SWIG_TypeClientData(equiv->type, swig_module.types[i]->clientdata);
        }
        equiv = equiv->next;
      }
    }
  }
}

#ifdef __cplusplus
#if 0
{
  /* c-mode */
#endif
}
#endif



#ifdef __cplusplus
extern "C"
#endif

XS(SWIG_init) {
  dXSARGS;
  int i;
  
  SWIG_InitializeModule(0);
  
  /* Install commands */
  for (i = 0; swig_commands[i].name; i++) {
    newXS((char*) swig_commands[i].name,swig_commands[i].wrapper, (char*)__FILE__);
  }
  
  /* Install variables */
  for (i = 0; swig_variables[i].name; i++) {
    SV *sv;
    sv = get_sv((char*) swig_variables[i].name, TRUE | 0x2 | GV_ADDMULTI);
    if (swig_variables[i].type) {
      SWIG_MakePtr(sv,(void *)1, *swig_variables[i].type,0);
    } else {
      sv_setiv(sv,(IV) 0);
    }
    swig_create_magic(sv, (char *) swig_variables[i].name, swig_variables[i].set, swig_variables[i].get); 
  }
  
  /* Install constant */
  for (i = 0; swig_constants[i].type; i++) {
    SV *sv;
    sv = get_sv((char*)swig_constants[i].name, TRUE | 0x2 | GV_ADDMULTI);
    switch(swig_constants[i].type) {
    case SWIG_INT:
      sv_setiv(sv, (IV) swig_constants[i].lvalue);
      break;
    case SWIG_FLOAT:
      sv_setnv(sv, (double) swig_constants[i].dvalue);
      break;
    case SWIG_STRING:
      sv_setpv(sv, (char *) swig_constants[i].pvalue);
      break;
    case SWIG_POINTER:
      SWIG_MakePtr(sv, swig_constants[i].pvalue, *(swig_constants[i].ptype),0);
      break;
    case SWIG_BINARY:
      SWIG_MakePackedObj(sv, swig_constants[i].pvalue, swig_constants[i].lvalue, *(swig_constants[i].ptype));
      break;
    default:
      break;
    }
    SvREADONLY_on(sv);
  }
  
  SWIG_TypeClientData(SWIGTYPE_p_ListWrapperT_ModelCreator_t, (void*) "LibSBML::ModelCreatorList");
  SWIG_TypeClientData(SWIGTYPE_p_ListWrapperT_Date_t, (void*) "LibSBML::DateList");
  SWIG_TypeClientData(SWIGTYPE_p_ListWrapperT_CVTerm_t, (void*) "LibSBML::CVTermList");
  SWIG_TypeClientData(SWIGTYPE_p_ListWrapperT_ASTNode_t, (void*) "LibSBML::ASTNodeList");
  SWIG_TypeClientData(SWIGTYPE_p_ListWrapperT_SBMLNamespaces_t, (void*) "LibSBML::SBMLNamespacesList");
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OStream_COUT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OStream::COUT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OStream_CERR", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OStream::CERR)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OStream_CLOG", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OStream::CLOG)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  SWIG_TypeClientData(SWIGTYPE_p_OStream, (void*) "LibSBML::OStream");
  SWIG_TypeClientData(SWIGTYPE_p_OFStream, (void*) "LibSBML::OFStream");
  SWIG_TypeClientData(SWIGTYPE_p_OStringStream, (void*) "LibSBML::OStringStream");
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_DOTTED_VERSION", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_FromCharPtr("4.3.0"));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_VERSION", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(40300)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_VERSION_STRING", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_FromCharPtr("40300"));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_OPERATION_SUCCESS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_OPERATION_SUCCESS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_INDEX_EXCEEDS_SIZE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_INDEX_EXCEEDS_SIZE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_UNEXPECTED_ATTRIBUTE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_UNEXPECTED_ATTRIBUTE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_OPERATION_FAILED", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_OPERATION_FAILED)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_INVALID_ATTRIBUTE_VALUE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_INVALID_ATTRIBUTE_VALUE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_INVALID_OBJECT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_INVALID_OBJECT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_DUPLICATE_OBJECT_ID", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_DUPLICATE_OBJECT_ID)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_LEVEL_MISMATCH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_LEVEL_MISMATCH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_VERSION_MISMATCH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_VERSION_MISMATCH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_INVALID_XML_OPERATION", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_INVALID_XML_OPERATION)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  SWIG_TypeClientData(SWIGTYPE_p_SBMLReader, (void*) "LibSBML::SBMLReader");
  SWIG_TypeClientData(SWIGTYPE_p_SBMLWriter, (void*) "LibSBML::SBMLWriter");
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_UNKNOWN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_UNKNOWN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_COMPARTMENT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_COMPARTMENT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_COMPARTMENT_TYPE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_COMPARTMENT_TYPE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_CONSTRAINT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_CONSTRAINT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_DOCUMENT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_DOCUMENT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_EVENT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_EVENT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_EVENT_ASSIGNMENT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_EVENT_ASSIGNMENT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_FUNCTION_DEFINITION", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_FUNCTION_DEFINITION)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_INITIAL_ASSIGNMENT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_INITIAL_ASSIGNMENT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_KINETIC_LAW", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_KINETIC_LAW)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LIST_OF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LIST_OF)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_MODEL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_MODEL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_PARAMETER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_PARAMETER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_REACTION", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_REACTION)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_RULE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_RULE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_SPECIES", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_SPECIES)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_SPECIES_REFERENCE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_SPECIES_REFERENCE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_SPECIES_TYPE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_SPECIES_TYPE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_MODIFIER_SPECIES_REFERENCE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_MODIFIER_SPECIES_REFERENCE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_UNIT_DEFINITION", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_UNIT_DEFINITION)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_UNIT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_UNIT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_ALGEBRAIC_RULE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_ALGEBRAIC_RULE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_ASSIGNMENT_RULE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_ASSIGNMENT_RULE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_RATE_RULE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_RATE_RULE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_SPECIES_CONCENTRATION_RULE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_SPECIES_CONCENTRATION_RULE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_COMPARTMENT_VOLUME_RULE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_COMPARTMENT_VOLUME_RULE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_PARAMETER_RULE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_PARAMETER_RULE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_TRIGGER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_TRIGGER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_DELAY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_DELAY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_STOICHIOMETRY_MATH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_STOICHIOMETRY_MATH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LOCAL_PARAMETER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LOCAL_PARAMETER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_PRIORITY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_PRIORITY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_FORMULA_UNITS_DATA", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_FORMULA_UNITS_DATA)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LIST_FORMULA_UNITS_DATA", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LIST_FORMULA_UNITS_DATA)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_COMPARTMENTS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_COMPARTMENTS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_COMPARTMENT_TYPES", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_COMPARTMENT_TYPES)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_CONSTRAINTS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_CONSTRAINTS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_EVENTS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_EVENTS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_EVENT_ASSIGNMENTS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_EVENT_ASSIGNMENTS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_FUNCTION_DEFINITIONS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_FUNCTION_DEFINITIONS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_INITIAL_ASSIGNMENTS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_INITIAL_ASSIGNMENTS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_PARAMETERS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_PARAMETERS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_REACTIONS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_REACTIONS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_RULES", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_RULES)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_SPECIES", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_SPECIES)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_SPECIES_REFERENCES", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_SPECIES_REFERENCES)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_SPECIES_TYPES", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_SPECIES_TYPES)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_UNIT_DEFINITIONS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_UNIT_DEFINITIONS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_LISTOF_UNITS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBML_LISTOF_UNITS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  SWIG_TypeClientData(SWIGTYPE_p_SBMLConstructorException, (void*) "LibSBML::SBMLConstructorException");
  SWIG_TypeClientData(SWIGTYPE_p_SBase, (void*) "LibSBML::SBase");
  SWIG_TypeClientData(SWIGTYPE_p_ListOf, (void*) "LibSBML::ListOf");
  SWIG_TypeClientData(SWIGTYPE_p_Model, (void*) "LibSBML::Model");
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "IdCheckON", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0x01)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "IdCheckOFF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0xfe)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBMLCheckON", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0x02)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBMLCheckOFF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0xfd)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBOCheckON", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0x04)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBOCheckOFF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0xfb)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MathCheckON", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0x08)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MathCheckOFF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0xf7)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UnitsCheckON", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0x10)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UnitsCheckOFF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0xef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OverdeterCheckON", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0x20)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OverdeterCheckOFF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0xdf)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "PracticeCheckON", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0x40)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "PracticeCheckOFF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0xbf)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllChecksON", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(0x7f)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  SWIG_TypeClientData(SWIGTYPE_p_SBMLDocument, (void*) "LibSBML::SBMLDocument");
  SWIG_TypeClientData(SWIGTYPE_p_FunctionDefinition, (void*) "LibSBML::FunctionDefinition");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfFunctionDefinitions, (void*) "LibSBML::ListOfFunctionDefinitions");
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_AMPERE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_AMPERE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_AVOGADRO", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_AVOGADRO)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_BECQUEREL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_BECQUEREL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_CANDELA", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_CANDELA)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_CELSIUS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_CELSIUS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_COULOMB", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_COULOMB)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_DIMENSIONLESS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_DIMENSIONLESS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_FARAD", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_FARAD)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_GRAM", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_GRAM)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_GRAY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_GRAY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_HENRY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_HENRY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_HERTZ", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_HERTZ)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_ITEM", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_ITEM)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_JOULE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_JOULE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_KATAL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_KATAL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_KELVIN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_KELVIN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_KILOGRAM", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_KILOGRAM)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_LITER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_LITER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_LITRE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_LITRE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_LUMEN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_LUMEN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_LUX", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_LUX)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_METER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_METER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_METRE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_METRE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_MOLE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_MOLE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_NEWTON", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_NEWTON)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_OHM", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_OHM)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_PASCAL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_PASCAL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_RADIAN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_RADIAN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_SECOND", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_SECOND)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_SIEMENS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_SIEMENS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_SIEVERT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_SIEVERT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_STERADIAN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_STERADIAN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_TESLA", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_TESLA)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_VOLT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_VOLT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_WATT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_WATT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_WEBER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_WEBER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNIT_KIND_INVALID", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNIT_KIND_INVALID)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  SWIG_TypeClientData(SWIGTYPE_p_Unit, (void*) "LibSBML::Unit");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfUnits, (void*) "LibSBML::ListOfUnits");
  SWIG_TypeClientData(SWIGTYPE_p_UnitDefinition, (void*) "LibSBML::UnitDefinition");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfUnitDefinitions, (void*) "LibSBML::ListOfUnitDefinitions");
  SWIG_TypeClientData(SWIGTYPE_p_CompartmentType, (void*) "LibSBML::CompartmentType");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfCompartmentTypes, (void*) "LibSBML::ListOfCompartmentTypes");
  SWIG_TypeClientData(SWIGTYPE_p_SpeciesType, (void*) "LibSBML::SpeciesType");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfSpeciesTypes, (void*) "LibSBML::ListOfSpeciesTypes");
  SWIG_TypeClientData(SWIGTYPE_p_Compartment, (void*) "LibSBML::Compartment");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfCompartments, (void*) "LibSBML::ListOfCompartments");
  SWIG_TypeClientData(SWIGTYPE_p_Species, (void*) "LibSBML::Species");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfSpecies, (void*) "LibSBML::ListOfSpecies");
  SWIG_TypeClientData(SWIGTYPE_p_Parameter, (void*) "LibSBML::Parameter");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfParameters, (void*) "LibSBML::ListOfParameters");
  SWIG_TypeClientData(SWIGTYPE_p_LocalParameter, (void*) "LibSBML::LocalParameter");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfLocalParameters, (void*) "LibSBML::ListOfLocalParameters");
  SWIG_TypeClientData(SWIGTYPE_p_InitialAssignment, (void*) "LibSBML::InitialAssignment");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfInitialAssignments, (void*) "LibSBML::ListOfInitialAssignments");
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RULE_TYPE_RATE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RULE_TYPE_RATE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RULE_TYPE_SCALAR", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RULE_TYPE_SCALAR)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RULE_TYPE_INVALID", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RULE_TYPE_INVALID)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  SWIG_TypeClientData(SWIGTYPE_p_Rule, (void*) "LibSBML::Rule");
  SWIG_TypeClientData(SWIGTYPE_p_AlgebraicRule, (void*) "LibSBML::AlgebraicRule");
  SWIG_TypeClientData(SWIGTYPE_p_AssignmentRule, (void*) "LibSBML::AssignmentRule");
  SWIG_TypeClientData(SWIGTYPE_p_RateRule, (void*) "LibSBML::RateRule");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfRules, (void*) "LibSBML::ListOfRules");
  SWIG_TypeClientData(SWIGTYPE_p_Constraint, (void*) "LibSBML::Constraint");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfConstraints, (void*) "LibSBML::ListOfConstraints");
  SWIG_TypeClientData(SWIGTYPE_p_Reaction, (void*) "LibSBML::Reaction");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfReactions, (void*) "LibSBML::ListOfReactions");
  SWIG_TypeClientData(SWIGTYPE_p_KineticLaw, (void*) "LibSBML::KineticLaw");
  SWIG_TypeClientData(SWIGTYPE_p_SimpleSpeciesReference, (void*) "LibSBML::SimpleSpeciesReference");
  SWIG_TypeClientData(SWIGTYPE_p_SpeciesReference, (void*) "LibSBML::SpeciesReference");
  SWIG_TypeClientData(SWIGTYPE_p_ModifierSpeciesReference, (void*) "LibSBML::ModifierSpeciesReference");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfSpeciesReferences, (void*) "LibSBML::ListOfSpeciesReferences");
  SWIG_TypeClientData(SWIGTYPE_p_Event, (void*) "LibSBML::Event");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfEvents, (void*) "LibSBML::ListOfEvents");
  SWIG_TypeClientData(SWIGTYPE_p_EventAssignment, (void*) "LibSBML::EventAssignment");
  SWIG_TypeClientData(SWIGTYPE_p_ListOfEventAssignments, (void*) "LibSBML::ListOfEventAssignments");
  SWIG_TypeClientData(SWIGTYPE_p_Trigger, (void*) "LibSBML::Trigger");
  SWIG_TypeClientData(SWIGTYPE_p_Delay, (void*) "LibSBML::Delay");
  SWIG_TypeClientData(SWIGTYPE_p_Priority, (void*) "LibSBML::Priority");
  SWIG_TypeClientData(SWIGTYPE_p_SBO, (void*) "LibSBML::SBO");
  SWIG_TypeClientData(SWIGTYPE_p_SyntaxChecker, (void*) "LibSBML::SyntaxChecker");
  SWIG_TypeClientData(SWIGTYPE_p_StoichiometryMath, (void*) "LibSBML::StoichiometryMath");
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_DEFAULT_LEVEL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_DEFAULT_VERSION", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_XMLNS_L1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_FromCharPtr("http://www.sbml.org/sbml/level1"));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_XMLNS_L2V1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_FromCharPtr("http://www.sbml.org/sbml/level2"));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_XMLNS_L2V2", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_FromCharPtr("http://www.sbml.org/sbml/level2/version2"));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_XMLNS_L2V3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_FromCharPtr("http://www.sbml.org/sbml/level2/version3"));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_XMLNS_L2V4", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_FromCharPtr("http://www.sbml.org/sbml/level2/version4"));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBML_XMLNS_L3V1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_FromCharPtr("http://www.sbml.org/sbml/level3/version1/core"));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  SWIG_TypeClientData(SWIGTYPE_p_SBMLNamespaces, (void*) "LibSBML::SBMLNamespaces");
  SWIG_TypeClientData(SWIGTYPE_p_SBMLTransforms, (void*) "LibSBML::SBMLTransforms");
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_PLUS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_PLUS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_MINUS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_MINUS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_TIMES", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_TIMES)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_DIVIDE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_DIVIDE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_POWER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_POWER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_INTEGER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_INTEGER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_REAL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_REAL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_REAL_E", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_REAL_E)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_RATIONAL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_RATIONAL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_NAME", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_NAME)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_NAME_AVOGADRO", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_NAME_AVOGADRO)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_NAME_TIME", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_NAME_TIME)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_CONSTANT_E", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_CONSTANT_E)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_CONSTANT_FALSE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_CONSTANT_FALSE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_CONSTANT_PI", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_CONSTANT_PI)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_CONSTANT_TRUE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_CONSTANT_TRUE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_LAMBDA", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_LAMBDA)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ABS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ABS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCCOS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCCOS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCCOSH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCCOSH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCCOT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCCOT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCCOTH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCCOTH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCCSC", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCCSC)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCCSCH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCCSCH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCSEC", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCSEC)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCSECH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCSECH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCSIN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCSIN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCSINH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCSINH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCTAN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCTAN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ARCTANH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ARCTANH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_CEILING", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_CEILING)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_COS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_COS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_COSH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_COSH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_COT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_COT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_COTH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_COTH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_CSC", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_CSC)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_CSCH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_CSCH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_DELAY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_DELAY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_EXP", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_EXP)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_FACTORIAL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_FACTORIAL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_FLOOR", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_FLOOR)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_LN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_LN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_LOG", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_LOG)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_PIECEWISE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_PIECEWISE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_POWER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_POWER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_ROOT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_ROOT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_SEC", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_SEC)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_SECH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_SECH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_SIN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_SIN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_SINH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_SINH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_TAN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_TAN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_FUNCTION_TANH", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_FUNCTION_TANH)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_LOGICAL_AND", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_LOGICAL_AND)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_LOGICAL_NOT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_LOGICAL_NOT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_LOGICAL_OR", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_LOGICAL_OR)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_LOGICAL_XOR", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_LOGICAL_XOR)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_RELATIONAL_EQ", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_RELATIONAL_EQ)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_RELATIONAL_GEQ", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_RELATIONAL_GEQ)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_RELATIONAL_GT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_RELATIONAL_GT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_RELATIONAL_LEQ", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_RELATIONAL_LEQ)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_RELATIONAL_LT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_RELATIONAL_LT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_RELATIONAL_NEQ", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_RELATIONAL_NEQ)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AST_UNKNOWN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AST_UNKNOWN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  SWIG_TypeClientData(SWIGTYPE_p_ASTNode, (void*) "LibSBML::ASTNode");
  SWIG_TypeClientData(SWIGTYPE_p_XMLConstructorException, (void*) "LibSBML::XMLConstructorException");
  SWIG_TypeClientData(SWIGTYPE_p_XMLAttributes, (void*) "LibSBML::XMLAttributes");
  SWIG_TypeClientData(SWIGTYPE_p_XMLNamespaces, (void*) "LibSBML::XMLNamespaces");
  SWIG_TypeClientData(SWIGTYPE_p_XMLToken, (void*) "LibSBML::XMLToken");
  SWIG_TypeClientData(SWIGTYPE_p_XMLNode, (void*) "LibSBML::XMLNode");
  SWIG_TypeClientData(SWIGTYPE_p_XMLTriple, (void*) "LibSBML::XMLTriple");
  SWIG_TypeClientData(SWIGTYPE_p_XMLOutputStream, (void*) "LibSBML::XMLOutputStream");
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLUnknownError", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLUnknownError)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLOutOfMemory", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLOutOfMemory)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLFileUnreadable", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLFileUnreadable)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLFileUnwritable", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLFileUnwritable)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLFileOperationError", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLFileOperationError)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLNetworkAccessError", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLNetworkAccessError)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InternalXMLParserError", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InternalXMLParserError)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UnrecognizedXMLParserCode", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UnrecognizedXMLParserCode)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLTranscoderError", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLTranscoderError)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingXMLDecl", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingXMLDecl)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingXMLEncoding", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingXMLEncoding)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadXMLDecl", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadXMLDecl)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadXMLDOCTYPE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadXMLDOCTYPE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidCharInXML", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidCharInXML)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadlyFormedXML", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadlyFormedXML)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UnclosedXMLToken", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UnclosedXMLToken)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidXMLConstruct", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidXMLConstruct)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLTagMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLTagMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DuplicateXMLAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DuplicateXMLAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UndefinedXMLEntity", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UndefinedXMLEntity)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadProcessingInstruction", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadProcessingInstruction)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadXMLPrefix", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadXMLPrefix)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadXMLPrefixValue", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadXMLPrefixValue)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingXMLRequiredAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingXMLRequiredAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLAttributeTypeMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLAttributeTypeMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLBadUTF8Content", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLBadUTF8Content)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingXMLAttributeValue", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingXMLAttributeValue)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadXMLAttributeValue", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadXMLAttributeValue)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadXMLAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadXMLAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UnrecognizedXMLElement", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UnrecognizedXMLElement)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadXMLComment", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadXMLComment)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadXMLDeclLocation", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadXMLDeclLocation)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLUnexpectedEOF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLUnexpectedEOF)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadXMLIDValue", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadXMLIDValue)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadXMLIDRef", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadXMLIDRef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UninterpretableXMLContent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UninterpretableXMLContent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadXMLDocumentStructure", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadXMLDocumentStructure)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidAfterXMLContent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidAfterXMLContent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLExpectedQuotedString", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLExpectedQuotedString)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLEmptyValueNotPermitted", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLEmptyValueNotPermitted)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLBadNumber", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLBadNumber)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLBadColon", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLBadColon)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingXMLElements", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingXMLElements)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLContentEmpty", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLContentEmpty)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "XMLErrorCodesUpperBound", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(XMLErrorCodesUpperBound)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_INTERNAL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_INTERNAL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_SYSTEM", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_SYSTEM)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_XML", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_XML)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_SEV_INFO", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_SEV_INFO)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_SEV_WARNING", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_SEV_WARNING)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_SEV_ERROR", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_SEV_ERROR)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_SEV_FATAL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_SEV_FATAL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  SWIG_TypeClientData(SWIGTYPE_p_XMLError, (void*) "LibSBML::XMLError");
  SWIG_TypeClientData(SWIGTYPE_p_XMLErrorLog, (void*) "LibSBML::XMLErrorLog");
  SWIG_TypeClientData(SWIGTYPE_p_SBMLErrorLog, (void*) "LibSBML::SBMLErrorLog");
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UnknownError", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UnknownError)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NotUTF8", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NotUTF8)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UnrecognizedElement", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UnrecognizedElement)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NotSchemaConformant", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NotSchemaConformant)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "L3NotSchemaConformant", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(L3NotSchemaConformant)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidMathElement", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidMathElement)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DisallowedMathMLSymbol", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DisallowedMathMLSymbol)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DisallowedMathMLEncodingUse", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DisallowedMathMLEncodingUse)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DisallowedDefinitionURLUse", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DisallowedDefinitionURLUse)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadCsymbolDefinitionURLValue", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadCsymbolDefinitionURLValue)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DisallowedMathTypeAttributeUse", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DisallowedMathTypeAttributeUse)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DisallowedMathTypeAttributeValue", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DisallowedMathTypeAttributeValue)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LambdaOnlyAllowedInFunctionDef", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LambdaOnlyAllowedInFunctionDef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BooleanOpsNeedBooleanArgs", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BooleanOpsNeedBooleanArgs)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NumericOpsNeedNumericArgs", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NumericOpsNeedNumericArgs)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ArgsToEqNeedSameType", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ArgsToEqNeedSameType)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "PiecewiseNeedsConsistentTypes", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(PiecewiseNeedsConsistentTypes)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "PieceNeedsBoolean", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(PieceNeedsBoolean)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ApplyCiMustBeUserFunction", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ApplyCiMustBeUserFunction)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ApplyCiMustBeModelComponent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ApplyCiMustBeModelComponent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "KineticLawParametersAreLocalOnly", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(KineticLawParametersAreLocalOnly)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MathResultMustBeNumeric", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MathResultMustBeNumeric)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OpsNeedCorrectNumberOfArgs", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OpsNeedCorrectNumberOfArgs)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidNoArgsPassedToFunctionDef", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidNoArgsPassedToFunctionDef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DisallowedMathUnitsUse", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DisallowedMathUnitsUse)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidUnitsValue", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidUnitsValue)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DuplicateComponentId", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DuplicateComponentId)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DuplicateUnitDefinitionId", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DuplicateUnitDefinitionId)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DuplicateLocalParameterId", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DuplicateLocalParameterId)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MultipleAssignmentOrRateRules", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MultipleAssignmentOrRateRules)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MultipleEventAssignmentsForId", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MultipleEventAssignmentsForId)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EventAndAssignmentRuleForId", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EventAndAssignmentRuleForId)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DuplicateMetaId", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DuplicateMetaId)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidSBOTermSyntax", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidSBOTermSyntax)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidMetaidSyntax", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidMetaidSyntax)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidIdSyntax", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidIdSyntax)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidUnitIdSyntax", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidUnitIdSyntax)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidNameSyntax", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidNameSyntax)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingAnnotationNamespace", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingAnnotationNamespace)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DuplicateAnnotationNamespaces", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DuplicateAnnotationNamespaces)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBMLNamespaceInAnnotation", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBMLNamespaceInAnnotation)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MultipleAnnotations", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MultipleAnnotations)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InconsistentArgUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InconsistentArgUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InconsistentKineticLawUnitsL3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InconsistentKineticLawUnitsL3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AssignRuleCompartmentMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AssignRuleCompartmentMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AssignRuleSpeciesMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AssignRuleSpeciesMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AssignRuleParameterMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AssignRuleParameterMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AssignRuleStoichiometryMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AssignRuleStoichiometryMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InitAssignCompartmenMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InitAssignCompartmenMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InitAssignSpeciesMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InitAssignSpeciesMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InitAssignParameterMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InitAssignParameterMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InitAssignStoichiometryMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InitAssignStoichiometryMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RateRuleCompartmentMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RateRuleCompartmentMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RateRuleSpeciesMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RateRuleSpeciesMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RateRuleParameterMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RateRuleParameterMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RateRuleStoichiometryMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RateRuleStoichiometryMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "KineticLawNotSubstancePerTime", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(KineticLawNotSubstancePerTime)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SpeciesInvalidExtentUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SpeciesInvalidExtentUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DelayUnitsNotTime", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DelayUnitsNotTime)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EventAssignCompartmentMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EventAssignCompartmentMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EventAssignSpeciesMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EventAssignSpeciesMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EventAssignParameterMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EventAssignParameterMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EventAssignStoichiometryMismatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EventAssignStoichiometryMismatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "PriorityUnitsNotDimensionless", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(PriorityUnitsNotDimensionless)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OverdeterminedSystem", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OverdeterminedSystem)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidModelSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidModelSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidFunctionDefSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidFunctionDefSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidParameterSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidParameterSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidInitAssignSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidInitAssignSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidRuleSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidRuleSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidConstraintSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidConstraintSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidReactionSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidReactionSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidSpeciesReferenceSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidSpeciesReferenceSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidKineticLawSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidKineticLawSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidEventSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidEventSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidEventAssignmentSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidEventAssignmentSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidCompartmentSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidCompartmentSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidSpeciesSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidSpeciesSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidCompartmentTypeSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidCompartmentTypeSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidSpeciesTypeSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidSpeciesTypeSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidTriggerSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidTriggerSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidDelaySBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidDelaySBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NotesNotInXHTMLNamespace", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NotesNotInXHTMLNamespace)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NotesContainsXMLDecl", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NotesContainsXMLDecl)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NotesContainsDOCTYPE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NotesContainsDOCTYPE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidNotesContent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidNotesContent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyOneNotesElementAllowed", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyOneNotesElementAllowed)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidNamespaceOnSBML", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidNamespaceOnSBML)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingOrInconsistentLevel", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingOrInconsistentLevel)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingOrInconsistentVersion", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingOrInconsistentVersion)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "PackageNSMustMatch", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(PackageNSMustMatch)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LevelPositiveInteger", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LevelPositiveInteger)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "VersionPositiveInteger", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(VersionPositiveInteger)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnSBML", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnSBML)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingModel", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingModel)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "IncorrectOrderInModel", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(IncorrectOrderInModel)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EmptyListElement", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EmptyListElement)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NeedCompartmentIfHaveSpecies", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NeedCompartmentIfHaveSpecies)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneOfEachListOf", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneOfEachListOf)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyFuncDefsInListOfFuncDefs", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyFuncDefsInListOfFuncDefs)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyUnitDefsInListOfUnitDefs", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyUnitDefsInListOfUnitDefs)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyCompartmentsInListOfCompartments", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyCompartmentsInListOfCompartments)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlySpeciesInListOfSpecies", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlySpeciesInListOfSpecies)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyParametersInListOfParameters", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyParametersInListOfParameters)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyInitAssignsInListOfInitAssigns", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyInitAssignsInListOfInitAssigns)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyRulesInListOfRules", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyRulesInListOfRules)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyConstraintsInListOfConstraints", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyConstraintsInListOfConstraints)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyReactionsInListOfReactions", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyReactionsInListOfReactions)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyEventsInListOfEvents", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyEventsInListOfEvents)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "L3ConversionFactorOnModel", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(L3ConversionFactorOnModel)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "L3TimeUnitsOnModel", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(L3TimeUnitsOnModel)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "L3VolumeUnitsOnModel", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(L3VolumeUnitsOnModel)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "L3AreaUnitsOnModel", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(L3AreaUnitsOnModel)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "L3LengthUnitsOnModel", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(L3LengthUnitsOnModel)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "L3ExtentUnitsOnModel", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(L3ExtentUnitsOnModel)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnModel", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnModel)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfFuncs", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfFuncs)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfUnitDefs", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfUnitDefs)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfComps", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfComps)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfSpecies", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfSpecies)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfParams", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfParams)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfInitAssign", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfInitAssign)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfRules", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfRules)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfConstraints", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfConstraints)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfReactions", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfReactions)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfEvents", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfEvents)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "FunctionDefMathNotLambda", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(FunctionDefMathNotLambda)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidApplyCiInLambda", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidApplyCiInLambda)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RecursiveFunctionDefinition", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RecursiveFunctionDefinition)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidCiInLambda", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidCiInLambda)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidFunctionDefReturnType", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidFunctionDefReturnType)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneMathElementPerFunc", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneMathElementPerFunc)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnFunc", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnFunc)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidUnitDefId", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidUnitDefId)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidSubstanceRedefinition", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidSubstanceRedefinition)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidLengthRedefinition", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidLengthRedefinition)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidAreaRedefinition", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidAreaRedefinition)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidTimeRedefinition", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidTimeRedefinition)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidVolumeRedefinition", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidVolumeRedefinition)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "VolumeLitreDefExponentNotOne", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(VolumeLitreDefExponentNotOne)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "VolumeMetreDefExponentNot3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(VolumeMetreDefExponentNot3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EmptyListOfUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EmptyListOfUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidUnitKind", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidUnitKind)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OffsetNoLongerValid", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OffsetNoLongerValid)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "CelsiusNoLongerValid", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(CelsiusNoLongerValid)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EmptyUnitListElement", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EmptyUnitListElement)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneListOfUnitsPerUnitDef", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneListOfUnitsPerUnitDef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyUnitsInListOfUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyUnitsInListOfUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnUnitDefinition", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnUnitDefinition)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnUnit", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnUnit)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ZeroDimensionalCompartmentSize", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ZeroDimensionalCompartmentSize)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ZeroDimensionalCompartmentUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ZeroDimensionalCompartmentUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ZeroDimensionalCompartmentConst", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ZeroDimensionalCompartmentConst)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UndefinedOutsideCompartment", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UndefinedOutsideCompartment)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RecursiveCompartmentContainment", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RecursiveCompartmentContainment)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ZeroDCompartmentContainment", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ZeroDCompartmentContainment)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "Invalid1DCompartmentUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(Invalid1DCompartmentUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "Invalid2DCompartmentUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(Invalid2DCompartmentUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "Invalid3DCompartmentUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(Invalid3DCompartmentUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidCompartmentTypeRef", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidCompartmentTypeRef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneDimensionalCompartmentUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneDimensionalCompartmentUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "TwoDimensionalCompartmentUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(TwoDimensionalCompartmentUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ThreeDimensionalCompartmentUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ThreeDimensionalCompartmentUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnCompartment", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnCompartment)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoUnitsOnCompartment", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoUnitsOnCompartment)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidSpeciesCompartmentRef", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidSpeciesCompartmentRef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "HasOnlySubsNoSpatialUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(HasOnlySubsNoSpatialUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoSpatialUnitsInZeroD", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoSpatialUnitsInZeroD)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoConcentrationInZeroD", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoConcentrationInZeroD)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SpatialUnitsInOneD", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SpatialUnitsInOneD)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SpatialUnitsInTwoD", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SpatialUnitsInTwoD)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SpatialUnitsInThreeD", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SpatialUnitsInThreeD)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidSpeciesSusbstanceUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidSpeciesSusbstanceUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BothAmountAndConcentrationSet", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BothAmountAndConcentrationSet)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NonBoundarySpeciesAssignedAndUsed", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NonBoundarySpeciesAssignedAndUsed)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NonConstantSpeciesUsed", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NonConstantSpeciesUsed)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidSpeciesTypeRef", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidSpeciesTypeRef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MultSpeciesSameTypeInCompartment", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MultSpeciesSameTypeInCompartment)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingSpeciesCompartment", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingSpeciesCompartment)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SpatialSizeUnitsRemoved", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SpatialSizeUnitsRemoved)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SubstanceUnitsOnSpecies", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SubstanceUnitsOnSpecies)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ConversionFactorOnSpecies", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ConversionFactorOnSpecies)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnSpecies", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnSpecies)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidParameterUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidParameterUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ParameterUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ParameterUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ConversionFactorMustConstant", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ConversionFactorMustConstant)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnParameter", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnParameter)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidInitAssignSymbol", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidInitAssignSymbol)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MultipleInitAssignments", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MultipleInitAssignments)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InitAssignmentAndRuleForSameId", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InitAssignmentAndRuleForSameId)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneMathElementPerInitialAssign", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneMathElementPerInitialAssign)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnInitialAssign", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnInitialAssign)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidAssignRuleVariable", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidAssignRuleVariable)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidRateRuleVariable", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidRateRuleVariable)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AssignmentToConstantEntity", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AssignmentToConstantEntity)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RateRuleForConstantEntity", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RateRuleForConstantEntity)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RepeatedRule10304", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RepeatedRule10304)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "CircularRuleDependency", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(CircularRuleDependency)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneMathElementPerRule", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneMathElementPerRule)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnAssignRule", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnAssignRule)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnRateRule", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnRateRule)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnAlgRule", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnAlgRule)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ConstraintMathNotBoolean", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ConstraintMathNotBoolean)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "IncorrectOrderInConstraint", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(IncorrectOrderInConstraint)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ConstraintNotInXHTMLNamespace", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ConstraintNotInXHTMLNamespace)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ConstraintContainsXMLDecl", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ConstraintContainsXMLDecl)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ConstraintContainsDOCTYPE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ConstraintContainsDOCTYPE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidConstraintContent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidConstraintContent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneMathElementPerConstraint", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneMathElementPerConstraint)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneMessageElementPerConstraint", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneMessageElementPerConstraint)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnConstraint", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnConstraint)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoReactantsOrProducts", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoReactantsOrProducts)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "IncorrectOrderInReaction", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(IncorrectOrderInReaction)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EmptyListInReaction", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EmptyListInReaction)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidReactantsProductsList", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidReactantsProductsList)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidModifiersList", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidModifiersList)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneSubElementPerReaction", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneSubElementPerReaction)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "CompartmentOnReaction", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(CompartmentOnReaction)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnReaction", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnReaction)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidSpeciesReference", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidSpeciesReference)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RepeatedRule20611", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RepeatedRule20611)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BothStoichiometryAndMath", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BothStoichiometryAndMath)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnSpeciesReference", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnSpeciesReference)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnModifier", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnModifier)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UndeclaredSpeciesRef", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UndeclaredSpeciesRef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "IncorrectOrderInKineticLaw", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(IncorrectOrderInKineticLaw)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EmptyListInKineticLaw", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EmptyListInKineticLaw)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NonConstantLocalParameter", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NonConstantLocalParameter)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SubsUnitsNoLongerValid", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SubsUnitsNoLongerValid)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "TimeUnitsNoLongerValid", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(TimeUnitsNoLongerValid)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneListOfPerKineticLaw", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneListOfPerKineticLaw)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyLocalParamsInListOfLocalParams", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyLocalParamsInListOfLocalParams)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfLocalParam", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfLocalParam)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneMathPerKineticLaw", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneMathPerKineticLaw)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UndeclaredSpeciesInStoichMath", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UndeclaredSpeciesInStoichMath)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnKineticLaw", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnKineticLaw)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfSpeciesRef", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfSpeciesRef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfMods", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfMods)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnLocalParameter", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnLocalParameter)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingTriggerInEvent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingTriggerInEvent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "TriggerMathNotBoolean", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(TriggerMathNotBoolean)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MissingEventAssignment", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MissingEventAssignment)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "TimeUnitsEvent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(TimeUnitsEvent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "IncorrectOrderInEvent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(IncorrectOrderInEvent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ValuesFromTriggerTimeNeedDelay", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ValuesFromTriggerTimeNeedDelay)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DelayNeedsValuesFromTriggerTime", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DelayNeedsValuesFromTriggerTime)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneMathPerTrigger", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneMathPerTrigger)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneMathPerDelay", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneMathPerDelay)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidEventAssignmentVariable", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidEventAssignmentVariable)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EventAssignmentForConstantEntity", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EventAssignmentForConstantEntity)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneMathPerEventAssignment", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneMathPerEventAssignment)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnEventAssignment", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnEventAssignment)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyOneDelayPerEvent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyOneDelayPerEvent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneListOfEventAssignmentsPerEvent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneListOfEventAssignmentsPerEvent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyEventAssignInListOfEventAssign", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyEventAssignInListOfEventAssign)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnListOfEventAssign", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnListOfEventAssign)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnEvent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnEvent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnTrigger", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnTrigger)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnDelay", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnDelay)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "PersistentNotBoolean", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(PersistentNotBoolean)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InitialValueNotBoolean", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InitialValueNotBoolean)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OnlyOnePriorityPerEvent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OnlyOnePriorityPerEvent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OneMathPerPriority", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OneMathPerPriority)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AllowedAttributesOnPriority", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AllowedAttributesOnPriority)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "GeneralWarningNotSpecified", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(GeneralWarningNotSpecified)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "CompartmentShouldHaveSize", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(CompartmentShouldHaveSize)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ParameterShouldHaveUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ParameterShouldHaveUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LocalParameterShadowsId", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LocalParameterShadowsId)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LibSBMLAdditionalCodesLowerBound", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LibSBMLAdditionalCodesLowerBound)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "CannotConvertToL1V1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(CannotConvertToL1V1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoEventsInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoEventsInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoFunctionDefinitionsInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoFunctionDefinitionsInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoConstraintsInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoConstraintsInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoInitialAssignmentsInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoInitialAssignmentsInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoSpeciesTypesInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoSpeciesTypesInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoCompartmentTypeInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoCompartmentTypeInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoNon3DComparmentsInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoNon3DComparmentsInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoFancyStoichiometryMathInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoFancyStoichiometryMathInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoNonIntegerStoichiometryInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoNonIntegerStoichiometryInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoUnitMultipliersOrOffsetsInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoUnitMultipliersOrOffsetsInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SpeciesCompartmentRequiredInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SpeciesCompartmentRequiredInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoSpeciesSpatialSizeUnitsInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoSpeciesSpatialSizeUnitsInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoSBOTermsInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoSBOTermsInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "StrictUnitsRequiredInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(StrictUnitsRequiredInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ConversionFactorNotInL1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ConversionFactorNotInL1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "CompartmentNotOnL1Reaction", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(CompartmentNotOnL1Reaction)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ExtentUnitsNotSubstance", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ExtentUnitsNotSubstance)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoConstraintsInL2v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoConstraintsInL2v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoInitialAssignmentsInL2v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoInitialAssignmentsInL2v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoSpeciesTypeInL2v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoSpeciesTypeInL2v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoCompartmentTypeInL2v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoCompartmentTypeInL2v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoSBOTermsInL2v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoSBOTermsInL2v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoIdOnSpeciesReferenceInL2v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoIdOnSpeciesReferenceInL2v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoDelayedEventAssignmentInL2v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoDelayedEventAssignmentInL2v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "StrictUnitsRequiredInL2v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(StrictUnitsRequiredInL2v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "IntegerSpatialDimensions", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(IntegerSpatialDimensions)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "StoichiometryMathNotYetSupported", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(StoichiometryMathNotYetSupported)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "PrioirtyLostFromL3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(PrioirtyLostFromL3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NonPersistentNotSupported", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NonPersistentNotSupported)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InitialValueFalseEventNotSupported", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InitialValueFalseEventNotSupported)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBOTermNotUniversalInL2v2", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBOTermNotUniversalInL2v2)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoUnitOffsetInL2v2", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoUnitOffsetInL2v2)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoKineticLawTimeUnitsInL2v2", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoKineticLawTimeUnitsInL2v2)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoKineticLawSubstanceUnitsInL2v2", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoKineticLawSubstanceUnitsInL2v2)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoDelayedEventAssignmentInL2v2", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoDelayedEventAssignmentInL2v2)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ModelSBOBranchChangedBeyondL2v2", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ModelSBOBranchChangedBeyondL2v2)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "StrictUnitsRequiredInL2v2", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(StrictUnitsRequiredInL2v2)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "StrictSBORequiredInL2v2", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(StrictSBORequiredInL2v2)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DuplicateAnnotationInvalidInL2v2", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DuplicateAnnotationInvalidInL2v2)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoUnitOffsetInL2v3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoUnitOffsetInL2v3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoKineticLawTimeUnitsInL2v3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoKineticLawTimeUnitsInL2v3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoKineticLawSubstanceUnitsInL2v3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoKineticLawSubstanceUnitsInL2v3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoSpeciesSpatialSizeUnitsInL2v3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoSpeciesSpatialSizeUnitsInL2v3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoEventTimeUnitsInL2v3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoEventTimeUnitsInL2v3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoDelayedEventAssignmentInL2v3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoDelayedEventAssignmentInL2v3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ModelSBOBranchChangedBeyondL2v3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ModelSBOBranchChangedBeyondL2v3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "StrictUnitsRequiredInL2v3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(StrictUnitsRequiredInL2v3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "StrictSBORequiredInL2v3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(StrictSBORequiredInL2v3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DuplicateAnnotationInvalidInL2v3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DuplicateAnnotationInvalidInL2v3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoUnitOffsetInL2v4", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoUnitOffsetInL2v4)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoKineticLawTimeUnitsInL2v4", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoKineticLawTimeUnitsInL2v4)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoKineticLawSubstanceUnitsInL2v4", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoKineticLawSubstanceUnitsInL2v4)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoSpeciesSpatialSizeUnitsInL2v4", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoSpeciesSpatialSizeUnitsInL2v4)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoEventTimeUnitsInL2v4", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoEventTimeUnitsInL2v4)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ModelSBOBranchChangedInL2v4", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ModelSBOBranchChangedInL2v4)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DuplicateAnnotationInvalidInL2v4", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DuplicateAnnotationInvalidInL2v4)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoSpeciesTypeInL3v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoSpeciesTypeInL3v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoCompartmentTypeInL3v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoCompartmentTypeInL3v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoUnitOffsetInL3v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoUnitOffsetInL3v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoKineticLawTimeUnitsInL3v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoKineticLawTimeUnitsInL3v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoKineticLawSubstanceUnitsInL3v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoKineticLawSubstanceUnitsInL3v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoSpeciesSpatialSizeUnitsInL3v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoSpeciesSpatialSizeUnitsInL3v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoEventTimeUnitsInL3v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoEventTimeUnitsInL3v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ModelSBOBranchChangedInL3v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ModelSBOBranchChangedInL3v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "DuplicateAnnotationInvalidInL3v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(DuplicateAnnotationInvalidInL3v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoCompartmentOutsideInL3v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoCompartmentOutsideInL3v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoStoichiometryMathInL3v1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoStoichiometryMathInL3v1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidSBMLLevelVersion", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidSBMLLevelVersion)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "AnnotationNotesNotAllowedLevel1", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(AnnotationNotesNotAllowedLevel1)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidRuleOrdering", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidRuleOrdering)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "RequiredPackagePresent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(RequiredPackagePresent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SubsUnitsAllowedInKL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SubsUnitsAllowedInKL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "TimeUnitsAllowedInKL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(TimeUnitsAllowedInKL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "FormulaInLevel1KL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(FormulaInLevel1KL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "TimeUnitsRemoved", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(TimeUnitsRemoved)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadMathML", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadMathML)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "FailedMathMLReadOfDouble", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(FailedMathMLReadOfDouble)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "FailedMathMLReadOfInteger", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(FailedMathMLReadOfInteger)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "FailedMathMLReadOfExponential", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(FailedMathMLReadOfExponential)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "FailedMathMLReadOfRational", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(FailedMathMLReadOfRational)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BadMathMLNodeType", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BadMathMLNodeType)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoTimeSymbolInFunctionDef", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoTimeSymbolInFunctionDef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NoBodyInFunctionDef", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NoBodyInFunctionDef)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InconsistentArgUnitsWarnings", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InconsistentArgUnitsWarnings)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InconsistentPowerUnitsWarnings", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InconsistentPowerUnitsWarnings)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InconsistentExponUnitsWarnings", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InconsistentExponUnitsWarnings)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UndeclaredUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UndeclaredUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UnrecognisedSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UnrecognisedSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ObseleteSBOTerm", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ObseleteSBOTerm)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "IncorrectCompartmentSpatialDimensions", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(IncorrectCompartmentSpatialDimensions)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "CompartmentTypeNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(CompartmentTypeNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ConstantNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ConstantNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MetaIdNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MetaIdNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBOTermNotValidAttributeBeforeL2V3", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBOTermNotValidAttributeBeforeL2V3)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidL1CompartmentUnits", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidL1CompartmentUnits)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "L1V1CompartmentVolumeReqd", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(L1V1CompartmentVolumeReqd)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "CompartmentTypeNotValidComponent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(CompartmentTypeNotValidComponent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ConstraintNotValidComponent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ConstraintNotValidComponent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "EventNotValidComponent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(EventNotValidComponent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBOTermNotValidAttributeBeforeL2V2", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBOTermNotValidAttributeBeforeL2V2)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "FuncDefNotValidComponent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(FuncDefNotValidComponent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InitialAssignNotValidComponent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InitialAssignNotValidComponent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "VariableNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(VariableNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UnitsNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UnitsNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "ConstantSpeciesNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(ConstantSpeciesNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SpatialSizeUnitsNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SpatialSizeUnitsNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SpeciesTypeNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SpeciesTypeNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "HasOnlySubsUnitsNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(HasOnlySubsUnitsNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "IdNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(IdNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "NameNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(NameNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SpeciesTypeNotValidComponent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SpeciesTypeNotValidComponent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "StoichiometryMathNotValidComponent", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(StoichiometryMathNotValidComponent)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MultiplierNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MultiplierNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "OffsetNotValidAttribute", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(OffsetNotValidAttribute)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "InvalidTargetLevelVersion", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(InvalidTargetLevelVersion)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "L3NotSupported", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(L3NotSupported)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "SBMLCodesUpperBound", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(SBMLCodesUpperBound)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_SBML", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_SBML)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_SBML_L1_COMPAT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_SBML_L1_COMPAT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_SBML_L2V1_COMPAT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_SBML_L2V1_COMPAT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_SBML_L2V2_COMPAT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_SBML_L2V2_COMPAT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_GENERAL_CONSISTENCY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_GENERAL_CONSISTENCY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_IDENTIFIER_CONSISTENCY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_IDENTIFIER_CONSISTENCY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_UNITS_CONSISTENCY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_UNITS_CONSISTENCY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_MATHML_CONSISTENCY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_MATHML_CONSISTENCY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_SBO_CONSISTENCY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_SBO_CONSISTENCY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_OVERDETERMINED_MODEL", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_OVERDETERMINED_MODEL)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_SBML_L2V3_COMPAT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_SBML_L2V3_COMPAT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_MODELING_PRACTICE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_MODELING_PRACTICE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_INTERNAL_CONSISTENCY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_INTERNAL_CONSISTENCY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_SBML_L2V4_COMPAT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_SBML_L2V4_COMPAT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_CAT_SBML_L3V1_COMPAT", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_CAT_SBML_L3V1_COMPAT)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_SEV_SCHEMA_ERROR", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_SEV_SCHEMA_ERROR)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_SEV_GENERAL_WARNING", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_SEV_GENERAL_WARNING)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "LIBSBML_SEV_NOT_APPLICABLE", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(LIBSBML_SEV_NOT_APPLICABLE)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  SWIG_TypeClientData(SWIGTYPE_p_SBMLError, (void*) "LibSBML::SBMLError");
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "MODEL_QUALIFIER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(MODEL_QUALIFIER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BIOLOGICAL_QUALIFIER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BIOLOGICAL_QUALIFIER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "UNKNOWN_QUALIFIER", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(UNKNOWN_QUALIFIER)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQM_IS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQM_IS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQM_IS_DESCRIBED_BY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQM_IS_DESCRIBED_BY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQM_IS_DERIVED_FROM", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQM_IS_DERIVED_FROM)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQM_UNKNOWN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQM_UNKNOWN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_IS", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_IS)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_HAS_PART", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_HAS_PART)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_IS_PART_OF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_IS_PART_OF)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_IS_VERSION_OF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_IS_VERSION_OF)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_HAS_VERSION", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_HAS_VERSION)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_IS_HOMOLOG_TO", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_IS_HOMOLOG_TO)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_IS_DESCRIBED_BY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_IS_DESCRIBED_BY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_IS_ENCODED_BY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_IS_ENCODED_BY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_ENCODES", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_ENCODES)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_OCCURS_IN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_OCCURS_IN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_HAS_PROPERTY", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_HAS_PROPERTY)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_IS_PROPERTY_OF", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_IS_PROPERTY_OF)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  /*@SWIG:/usr/local/share/swig/2.0.0/perl5/perltypemaps.swg,65,%set_constant@*/ do {
    SV *sv = get_sv((char*) SWIG_prefix "BQB_UNKNOWN", TRUE | 0x2 | GV_ADDMULTI);
    sv_setsv(sv, SWIG_From_int  SWIG_PERL_CALL_ARGS_1(static_cast< int >(BQB_UNKNOWN)));
    SvREADONLY_on(sv);
  } while(0) /*@SWIG@*/;
  SWIG_TypeClientData(SWIGTYPE_p_CVTerm, (void*) "LibSBML::CVTerm");
  SWIG_TypeClientData(SWIGTYPE_p_Date, (void*) "LibSBML::Date");
  SWIG_TypeClientData(SWIGTYPE_p_ModelCreator, (void*) "LibSBML::ModelCreator");
  SWIG_TypeClientData(SWIGTYPE_p_ModelHistory, (void*) "LibSBML::ModelHistory");
  SWIG_TypeClientData(SWIGTYPE_p_RDFAnnotationParser, (void*) "LibSBML::RDFAnnotationParser");
  ST(0) = &PL_sv_yes;
  XSRETURN(1);
}

