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


#ifndef SWIGPYTHON
#define SWIGPYTHON
#endif

#define SWIG_PYTHON_DIRECTOR_NO_VTABLE

/* -----------------------------------------------------------------------------
 *  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 defined(__GNUC__)
#  if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
#    ifndef GCC_HASCLASSVISIBILITY
#      define GCC_HASCLASSVISIBILITY
#    endif
#  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

/* Deal with Apple's deprecated 'AssertMacros.h' from Carbon-framework */
#if defined(__APPLE__) && !defined(__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES)
# define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0
#endif

/* Intel's compiler complains if a variable which was never initialised is
 * cast to void, which is a common idiom which we use to indicate that we
 * are aware a variable isn't used.  So we just silence that warning.
 * See: https://github.com/swig/swig/issues/192 for more discussion.
 */
#ifdef __INTEL_COMPILER
# pragma warning disable 592
#endif


#if defined(__GNUC__) && defined(_WIN32) && !defined(SWIG_PYTHON_NO_HYPOT_WORKAROUND)
/* Workaround for '::hypot' has not been declared', see https://bugs.python.org/issue11566 */
# include <math.h>
#endif

#if defined(_DEBUG) && defined(SWIG_PYTHON_INTERPRETER_NO_DEBUG)
/* Use debug wrappers with the Python release dll */
# undef _DEBUG
# include <Python.h>
# define _DEBUG 1
#else
# include <Python.h>
#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
#define SWIG_POINTER_NO_NULL       0x4

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


/*
   Flags/methods for returning states.

   The SWIG conversion methods, as ConvertPtr, return an integer
   that tells if the conversion was successful or not. And if not,
   an error code can be returned (see swigerrors.swg for the codes).

   Use the following macros/flags to set or process the returning
   states.

   In old versions of SWIG, code such as the following was usually written:

     if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
       // 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(r) (r)
#  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 equal, -1 if nb < tb, 1 if nb > tb
*/
SWIGRUNTIME int
SWIG_TypeCmp(const char *nb, const char *tb) {
  int equiv = 1;
  const char* te = tb + strlen(tb);
  const char* ne = nb;
  while (equiv != 0 && *ne) {
    for (nb = ne; *ne; ++ne) {
      if (*ne == '|') break;
    }
    equiv = SWIG_TypeNameComp(nb, ne, tb, te);
    if (*ne) ++ne;
  }
  return equiv;
}

/*
  Check type equivalence in a name list like <name1>|<name2>|...
  Return 0 if not equal, 1 if equal
*/
SWIGRUNTIME int
SWIG_TypeEquiv(const char *nb, const char *tb) {
  return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
}

/*
  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) {
      size_t l = 0;
      size_t r = iter->size - 1;
      do {
	/* since l+r >= 0, we can (>> 1) instead (/ 2) */
	size_t i = (l + r) >> 1;
	const char *iname = iter->types[i]->name;
	if (iname) {
	  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 {
      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";
  const unsigned char *u = (unsigned char *) ptr;
  const unsigned char *eu =  u + sz;
  for (; u != eu; ++u) {
    unsigned char uu = *u;
    *(c++) = hex[(uu & 0xf0) >> 4];
    *(c++) = hex[uu & 0xf];
  }
  return c;
}

/*
   Unpack binary data from a string
*/
SWIGRUNTIME const char *
SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
  unsigned char *u = (unsigned char *) ptr;
  const unsigned char *eu = u + sz;
  for (; u != eu; ++u) {
    char d = *(c++);
    unsigned char uu;
    if ((d >= '0') && (d <= '9'))
      uu = (unsigned char)((d - '0') << 4);
    else if ((d >= 'a') && (d <= 'f'))
      uu = (unsigned char)((d - ('a'-10)) << 4);
    else
      return (char *) 0;
    d = *(c++);
    if ((d >= '0') && (d <= '9'))
      uu |= (unsigned char)(d - '0');
    else if ((d >= 'a') && (d <= 'f'))
      uu |= (unsigned char)(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



/* Compatibility macros for Python 3 */
#if PY_VERSION_HEX >= 0x03000000

#define PyClass_Check(obj) PyObject_IsInstance(obj, (PyObject *)&PyType_Type)
#define PyInt_Check(x) PyLong_Check(x)
#define PyInt_AsLong(x) PyLong_AsLong(x)
#define PyInt_FromLong(x) PyLong_FromLong(x)
#define PyInt_FromSize_t(x) PyLong_FromSize_t(x)
#define PyString_Check(name) PyBytes_Check(name)
#define PyString_FromString(x) PyUnicode_FromString(x)
#define PyString_Format(fmt, args)  PyUnicode_Format(fmt, args)
#define PyString_AsString(str) PyBytes_AsString(str)
#define PyString_Size(str) PyBytes_Size(str)	
#define PyString_InternFromString(key) PyUnicode_InternFromString(key)
#define Py_TPFLAGS_HAVE_CLASS Py_TPFLAGS_BASETYPE
#define PyString_AS_STRING(x) PyUnicode_AS_STRING(x)
#define _PyLong_FromSsize_t(x) PyLong_FromSsize_t(x)

#endif

#ifndef Py_TYPE
#  define Py_TYPE(op) ((op)->ob_type)
#endif

/* SWIG APIs for compatibility of both Python 2 & 3 */

#if PY_VERSION_HEX >= 0x03000000
#  define SWIG_Python_str_FromFormat PyUnicode_FromFormat
#else
#  define SWIG_Python_str_FromFormat PyString_FromFormat
#endif


/* Warning: This function will allocate a new string in Python 3,
 * so please call SWIG_Python_str_DelForPy3(x) to free the space.
 */
SWIGINTERN char*
SWIG_Python_str_AsChar(PyObject *str)
{
#if PY_VERSION_HEX >= 0x03000000
  char *newstr = 0;
  str = PyUnicode_AsUTF8String(str);
  if (str) {
    char *cstr;
    Py_ssize_t len;
    PyBytes_AsStringAndSize(str, &cstr, &len);
    newstr = (char *) malloc(len+1);
    memcpy(newstr, cstr, len+1);
    Py_XDECREF(str);
  }
  return newstr;
#else
  return PyString_AsString(str);
#endif
}

#if PY_VERSION_HEX >= 0x03000000
#  define SWIG_Python_str_DelForPy3(x) free( (void*) (x) )
#else
#  define SWIG_Python_str_DelForPy3(x) 
#endif


SWIGINTERN PyObject*
SWIG_Python_str_FromChar(const char *c)
{
#if PY_VERSION_HEX >= 0x03000000
  return PyUnicode_FromString(c); 
#else
  return PyString_FromString(c);
#endif
}

#ifndef PyObject_DEL
# define PyObject_DEL PyObject_Del
#endif

// SWIGPY_USE_CAPSULE is no longer used within SWIG itself, but some user
// interface files check for it.
# define SWIGPY_USE_CAPSULE
# define SWIGPY_CAPSULE_NAME ("swig_runtime_data" SWIG_RUNTIME_VERSION ".type_pointer_capsule" SWIG_TYPE_TABLE_NAME)

#if PY_VERSION_HEX < 0x03020000
#define PyDescr_TYPE(x) (((PyDescrObject *)(x))->d_type)
#define PyDescr_NAME(x) (((PyDescrObject *)(x))->d_name)
#define Py_hash_t long
#endif

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

SWIGRUNTIME PyObject*
SWIG_Python_ErrorType(int code) {
  PyObject* type = 0;
  switch(code) {
  case SWIG_MemoryError:
    type = PyExc_MemoryError;
    break;
  case SWIG_IOError:
    type = PyExc_IOError;
    break;
  case SWIG_RuntimeError:
    type = PyExc_RuntimeError;
    break;
  case SWIG_IndexError:
    type = PyExc_IndexError;
    break;
  case SWIG_TypeError:
    type = PyExc_TypeError;
    break;
  case SWIG_DivisionByZero:
    type = PyExc_ZeroDivisionError;
    break;
  case SWIG_OverflowError:
    type = PyExc_OverflowError;
    break;
  case SWIG_SyntaxError:
    type = PyExc_SyntaxError;
    break;
  case SWIG_ValueError:
    type = PyExc_ValueError;
    break;
  case SWIG_SystemError:
    type = PyExc_SystemError;
    break;
  case SWIG_AttributeError:
    type = PyExc_AttributeError;
    break;
  default:
    type = PyExc_RuntimeError;
  }
  return type;
}


SWIGRUNTIME void
SWIG_Python_AddErrorMsg(const char* mesg)
{
  PyObject *type = 0;
  PyObject *value = 0;
  PyObject *traceback = 0;

  if (PyErr_Occurred())
    PyErr_Fetch(&type, &value, &traceback);
  if (value) {
    PyObject *old_str = PyObject_Str(value);
    const char *tmp = SWIG_Python_str_AsChar(old_str);
    PyErr_Clear();
    Py_XINCREF(type);
    if (tmp)
      PyErr_Format(type, "%s %s", tmp, mesg);
    else
      PyErr_Format(type, "%s", mesg);
    SWIG_Python_str_DelForPy3(tmp);
    Py_DECREF(old_str);
    Py_DECREF(value);
  } else {
    PyErr_SetString(PyExc_RuntimeError, mesg);
  }
}

SWIGRUNTIME int
SWIG_Python_TypeErrorOccurred(PyObject *obj)
{
  PyObject *error;
  if (obj)
    return 0;
  error = PyErr_Occurred();
  return error && PyErr_GivenExceptionMatches(error, PyExc_TypeError);
}

SWIGRUNTIME void
SWIG_Python_RaiseOrModifyTypeError(const char *message)
{
  if (SWIG_Python_TypeErrorOccurred(NULL)) {
    /* Use existing TypeError to preserve stacktrace and enhance with given message */
    PyObject *newvalue;
    PyObject *type = NULL, *value = NULL, *traceback = NULL;
    PyErr_Fetch(&type, &value, &traceback);
#if PY_VERSION_HEX >= 0x03000000
    newvalue = PyUnicode_FromFormat("%S\nAdditional information:\n%s", value, message);
#else
    newvalue = PyString_FromFormat("%s\nAdditional information:\n%s", PyString_AsString(value), message);
#endif
    Py_XDECREF(value);
    PyErr_Restore(type, newvalue, traceback);
  } else {
    /* Raise TypeError using given message */
    PyErr_SetString(PyExc_TypeError, message);
  }
}

#if defined(SWIG_PYTHON_NO_THREADS)
#  if defined(SWIG_PYTHON_THREADS)
#    undef SWIG_PYTHON_THREADS
#  endif
#endif
#if defined(SWIG_PYTHON_THREADS) /* Threading support is enabled */
#  if !defined(SWIG_PYTHON_USE_GIL) && !defined(SWIG_PYTHON_NO_USE_GIL)
#    define SWIG_PYTHON_USE_GIL
#  endif
#  if defined(SWIG_PYTHON_USE_GIL) /* Use PyGILState threads calls */
#    ifndef SWIG_PYTHON_INITIALIZE_THREADS
#     define SWIG_PYTHON_INITIALIZE_THREADS  PyEval_InitThreads() 
#    endif
#    ifdef __cplusplus /* C++ code */
       class SWIG_Python_Thread_Block {
         bool status;
         PyGILState_STATE state;
       public:
         void end() { if (status) { PyGILState_Release(state); status = false;} }
         SWIG_Python_Thread_Block() : status(true), state(PyGILState_Ensure()) {}
         ~SWIG_Python_Thread_Block() { end(); }
       };
       class SWIG_Python_Thread_Allow {
         bool status;
         PyThreadState *save;
       public:
         void end() { if (status) { PyEval_RestoreThread(save); status = false; }}
         SWIG_Python_Thread_Allow() : status(true), save(PyEval_SaveThread()) {}
         ~SWIG_Python_Thread_Allow() { end(); }
       };
#      define SWIG_PYTHON_THREAD_BEGIN_BLOCK   SWIG_Python_Thread_Block _swig_thread_block
#      define SWIG_PYTHON_THREAD_END_BLOCK     _swig_thread_block.end()
#      define SWIG_PYTHON_THREAD_BEGIN_ALLOW   SWIG_Python_Thread_Allow _swig_thread_allow
#      define SWIG_PYTHON_THREAD_END_ALLOW     _swig_thread_allow.end()
#    else /* C code */
#      define SWIG_PYTHON_THREAD_BEGIN_BLOCK   PyGILState_STATE _swig_thread_block = PyGILState_Ensure()
#      define SWIG_PYTHON_THREAD_END_BLOCK     PyGILState_Release(_swig_thread_block)
#      define SWIG_PYTHON_THREAD_BEGIN_ALLOW   PyThreadState *_swig_thread_allow = PyEval_SaveThread()
#      define SWIG_PYTHON_THREAD_END_ALLOW     PyEval_RestoreThread(_swig_thread_allow)
#    endif
#  else /* Old thread way, not implemented, user must provide it */
#    if !defined(SWIG_PYTHON_INITIALIZE_THREADS)
#      define SWIG_PYTHON_INITIALIZE_THREADS
#    endif
#    if !defined(SWIG_PYTHON_THREAD_BEGIN_BLOCK)
#      define SWIG_PYTHON_THREAD_BEGIN_BLOCK
#    endif
#    if !defined(SWIG_PYTHON_THREAD_END_BLOCK)
#      define SWIG_PYTHON_THREAD_END_BLOCK
#    endif
#    if !defined(SWIG_PYTHON_THREAD_BEGIN_ALLOW)
#      define SWIG_PYTHON_THREAD_BEGIN_ALLOW
#    endif
#    if !defined(SWIG_PYTHON_THREAD_END_ALLOW)
#      define SWIG_PYTHON_THREAD_END_ALLOW
#    endif
#  endif
#else /* No thread support */
#  define SWIG_PYTHON_INITIALIZE_THREADS
#  define SWIG_PYTHON_THREAD_BEGIN_BLOCK
#  define SWIG_PYTHON_THREAD_END_BLOCK
#  define SWIG_PYTHON_THREAD_BEGIN_ALLOW
#  define SWIG_PYTHON_THREAD_END_ALLOW
#endif

/* -----------------------------------------------------------------------------
 * Python API portion that goes into the runtime
 * ----------------------------------------------------------------------------- */

#ifdef __cplusplus
extern "C" {
#endif

/* -----------------------------------------------------------------------------
 * Constant declarations
 * ----------------------------------------------------------------------------- */

/* Constant Types */
#define SWIG_PY_POINTER 4
#define SWIG_PY_BINARY  5

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

#ifdef __cplusplus
}
#endif


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

#if PY_VERSION_HEX < 0x02070000 /* 2.7.0 */
# error "This version of SWIG only supports Python >= 2.7"
#endif

#if PY_VERSION_HEX >= 0x03000000 && PY_VERSION_HEX < 0x03020000
# error "This version of SWIG only supports Python 3 >= 3.2"
#endif

/* Common SWIG API */

/* for raw pointers */
#define SWIG_Python_ConvertPtr(obj, pptr, type, flags)  SWIG_Python_ConvertPtrAndOwn(obj, pptr, type, flags, 0)
#define SWIG_ConvertPtr(obj, pptr, type, flags)         SWIG_Python_ConvertPtr(obj, pptr, type, flags)
#define SWIG_ConvertPtrAndOwn(obj,pptr,type,flags,own)  SWIG_Python_ConvertPtrAndOwn(obj, pptr, type, flags, own)

#ifdef SWIGPYTHON_BUILTIN
#define SWIG_NewPointerObj(ptr, type, flags)            SWIG_Python_NewPointerObj(self, ptr, type, flags)
#else
#define SWIG_NewPointerObj(ptr, type, flags)            SWIG_Python_NewPointerObj(NULL, ptr, type, flags)
#endif

#define SWIG_InternalNewPointerObj(ptr, type, flags)	SWIG_Python_NewPointerObj(NULL, ptr, type, flags)

#define SWIG_CheckImplicit(ty)                          SWIG_Python_CheckImplicit(ty) 
#define SWIG_AcquirePtr(ptr, src)                       SWIG_Python_AcquirePtr(ptr, src)
#define swig_owntype                                    int

/* for raw packed data */
#define SWIG_ConvertPacked(obj, ptr, sz, ty)            SWIG_Python_ConvertPacked(obj, ptr, sz, ty)
#define SWIG_NewPackedObj(ptr, sz, type)                SWIG_Python_NewPackedObj(ptr, sz, 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_Python_ConvertFunctionPtr(obj, pptr, type)
#define SWIG_NewFunctionPtrObj(ptr, type)               SWIG_Python_NewPointerObj(NULL, ptr, type, 0)

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


/* Runtime API */

#define SWIG_GetModule(clientdata)                      SWIG_Python_GetModule(clientdata)
#define SWIG_SetModule(clientdata, pointer)             SWIG_Python_SetModule(pointer)
#define SWIG_NewClientData(obj)                         SwigPyClientData_New(obj)

#define SWIG_SetErrorObj                                SWIG_Python_SetErrorObj                            
#define SWIG_SetErrorMsg                        	SWIG_Python_SetErrorMsg				   
#define SWIG_ErrorType(code)                    	SWIG_Python_ErrorType(code)                        
#define SWIG_Error(code, msg)            		SWIG_Python_SetErrorMsg(SWIG_ErrorType(code), msg) 
#define SWIG_fail                        		goto fail					   


/* Runtime API implementation */

/* Error manipulation */

SWIGINTERN void 
SWIG_Python_SetErrorObj(PyObject *errtype, PyObject *obj) {
  SWIG_PYTHON_THREAD_BEGIN_BLOCK; 
  PyErr_SetObject(errtype, obj);
  Py_DECREF(obj);
  SWIG_PYTHON_THREAD_END_BLOCK;
}

SWIGINTERN void 
SWIG_Python_SetErrorMsg(PyObject *errtype, const char *msg) {
  SWIG_PYTHON_THREAD_BEGIN_BLOCK;
  PyErr_SetString(errtype, msg);
  SWIG_PYTHON_THREAD_END_BLOCK;
}

#define SWIG_Python_Raise(obj, type, desc)  SWIG_Python_SetErrorObj(SWIG_Python_ExceptionType(desc), obj)

/* Set a constant value */

#if defined(SWIGPYTHON_BUILTIN)

SWIGINTERN void
SwigPyBuiltin_AddPublicSymbol(PyObject *seq, const char *key) {
  PyObject *s = PyString_InternFromString(key);
  PyList_Append(seq, s);
  Py_DECREF(s);
}

SWIGINTERN void
SWIG_Python_SetConstant(PyObject *d, PyObject *public_interface, const char *name, PyObject *obj) {   
  PyDict_SetItemString(d, name, obj);
  Py_DECREF(obj);
  if (public_interface)
    SwigPyBuiltin_AddPublicSymbol(public_interface, name);
}

#else

SWIGINTERN void
SWIG_Python_SetConstant(PyObject *d, const char *name, PyObject *obj) {   
  PyDict_SetItemString(d, name, obj);
  Py_DECREF(obj);                            
}

#endif

/* Append a value to the result obj */

SWIGINTERN PyObject*
SWIG_Python_AppendOutput(PyObject* result, PyObject* obj) {
  if (!result) {
    result = obj;
  } else if (result == Py_None) {
    Py_DECREF(result);
    result = obj;
  } else {
    if (!PyList_Check(result)) {
      PyObject *o2 = result;
      result = PyList_New(1);
      PyList_SetItem(result, 0, o2);
    }
    PyList_Append(result,obj);
    Py_DECREF(obj);
  }
  return result;
}

/* Unpack the argument tuple */

SWIGINTERN Py_ssize_t
SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssize_t max, PyObject **objs)
{
  if (!args) {
    if (!min && !max) {
      return 1;
    } else {
      PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got none", 
		   name, (min == max ? "" : "at least "), (int)min);
      return 0;
    }
  }  
  if (!PyTuple_Check(args)) {
    if (min <= 1 && max >= 1) {
      Py_ssize_t i;
      objs[0] = args;
      for (i = 1; i < max; ++i) {
	objs[i] = 0;
      }
      return 2;
    }
    PyErr_SetString(PyExc_SystemError, "UnpackTuple() argument list is not a tuple");
    return 0;
  } else {
    Py_ssize_t l = PyTuple_GET_SIZE(args);
    if (l < min) {
      PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got %d", 
		   name, (min == max ? "" : "at least "), (int)min, (int)l);
      return 0;
    } else if (l > max) {
      PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got %d", 
		   name, (min == max ? "" : "at most "), (int)max, (int)l);
      return 0;
    } else {
      Py_ssize_t i;
      for (i = 0; i < l; ++i) {
	objs[i] = PyTuple_GET_ITEM(args, i);
      }
      for (; l < max; ++l) {
	objs[l] = 0;
      }
      return i + 1;
    }    
  }
}

/* A functor is a function object with one single object argument */
#define SWIG_Python_CallFunctor(functor, obj)	        PyObject_CallFunctionObjArgs(functor, obj, NULL);

/*
  Helper for static pointer initialization for both C and C++ code, for example
  static PyObject *SWIG_STATIC_POINTER(MyVar) = NewSomething(...);
*/
#ifdef __cplusplus
#define SWIG_STATIC_POINTER(var)  var
#else
#define SWIG_STATIC_POINTER(var)  var = 0; if (!var) var
#endif

/* -----------------------------------------------------------------------------
 * Pointer declarations
 * ----------------------------------------------------------------------------- */

/* Flags for new pointer objects */
#define SWIG_POINTER_NOSHADOW       (SWIG_POINTER_OWN      << 1)
#define SWIG_POINTER_NEW            (SWIG_POINTER_NOSHADOW | SWIG_POINTER_OWN)

#define SWIG_POINTER_IMPLICIT_CONV  (SWIG_POINTER_DISOWN   << 1)

#define SWIG_BUILTIN_TP_INIT	    (SWIG_POINTER_OWN << 2)
#define SWIG_BUILTIN_INIT	    (SWIG_BUILTIN_TP_INIT | SWIG_POINTER_OWN)

#ifdef __cplusplus
extern "C" {
#endif

/* The python void return value */

SWIGRUNTIMEINLINE PyObject * 
SWIG_Py_Void(void)
{
  PyObject *none = Py_None;
  Py_INCREF(none);
  return none;
}

/* SwigPyClientData */

typedef struct {
  PyObject *klass;
  PyObject *newraw;
  PyObject *newargs;
  PyObject *destroy;
  int delargs;
  int implicitconv;
  PyTypeObject *pytype;
} SwigPyClientData;

SWIGRUNTIMEINLINE int 
SWIG_Python_CheckImplicit(swig_type_info *ty)
{
  SwigPyClientData *data = (SwigPyClientData *)ty->clientdata;
  int fail = data ? data->implicitconv : 0;
  if (fail)
    PyErr_SetString(PyExc_TypeError, "Implicit conversion is prohibited for explicit constructors.");
  return fail;
}

SWIGRUNTIMEINLINE PyObject *
SWIG_Python_ExceptionType(swig_type_info *desc) {
  SwigPyClientData *data = desc ? (SwigPyClientData *) desc->clientdata : 0;
  PyObject *klass = data ? data->klass : 0;
  return (klass ? klass : PyExc_RuntimeError);
}


SWIGRUNTIME SwigPyClientData * 
SwigPyClientData_New(PyObject* obj)
{
  if (!obj) {
    return 0;
  } else {
    SwigPyClientData *data = (SwigPyClientData *)malloc(sizeof(SwigPyClientData));
    /* the klass element */
    data->klass = obj;
    Py_INCREF(data->klass);
    /* the newraw method and newargs arguments used to create a new raw instance */
    if (PyClass_Check(obj)) {
      data->newraw = 0;
      data->newargs = obj;
      Py_INCREF(obj);
    } else {
      data->newraw = PyObject_GetAttrString(data->klass, "__new__");
      if (data->newraw) {
	Py_INCREF(data->newraw);
	data->newargs = PyTuple_New(1);
	PyTuple_SetItem(data->newargs, 0, obj);
      } else {
	data->newargs = obj;
      }
      Py_INCREF(data->newargs);
    }
    /* the destroy method, aka as the C++ delete method */
    data->destroy = PyObject_GetAttrString(data->klass, "__swig_destroy__");
    if (PyErr_Occurred()) {
      PyErr_Clear();
      data->destroy = 0;
    }
    if (data->destroy) {
      int flags;
      Py_INCREF(data->destroy);
      flags = PyCFunction_GET_FLAGS(data->destroy);
      data->delargs = !(flags & (METH_O));
    } else {
      data->delargs = 0;
    }
    data->implicitconv = 0;
    data->pytype = 0;
    return data;
  }
}

SWIGRUNTIME void 
SwigPyClientData_Del(SwigPyClientData *data) {
  Py_XDECREF(data->newraw);
  Py_XDECREF(data->newargs);
  Py_XDECREF(data->destroy);
}

/* =============== SwigPyObject =====================*/

typedef struct {
  PyObject_HEAD
  void *ptr;
  swig_type_info *ty;
  int own;
  PyObject *next;
#ifdef SWIGPYTHON_BUILTIN
  PyObject *dict;
#endif
} SwigPyObject;


#ifdef SWIGPYTHON_BUILTIN

SWIGRUNTIME PyObject *
SwigPyObject_get___dict__(PyObject *v, PyObject *SWIGUNUSEDPARM(args))
{
  SwigPyObject *sobj = (SwigPyObject *)v;

  if (!sobj->dict)
    sobj->dict = PyDict_New();

  Py_INCREF(sobj->dict);
  return sobj->dict;
}

#endif

SWIGRUNTIME PyObject *
SwigPyObject_long(SwigPyObject *v)
{
  return PyLong_FromVoidPtr(v->ptr);
}

SWIGRUNTIME PyObject *
SwigPyObject_format(const char* fmt, SwigPyObject *v)
{
  PyObject *res = NULL;
  PyObject *args = PyTuple_New(1);
  if (args) {
    if (PyTuple_SetItem(args, 0, SwigPyObject_long(v)) == 0) {
      PyObject *ofmt = SWIG_Python_str_FromChar(fmt);
      if (ofmt) {
#if PY_VERSION_HEX >= 0x03000000
	res = PyUnicode_Format(ofmt,args);
#else
	res = PyString_Format(ofmt,args);
#endif
	Py_DECREF(ofmt);
      }
      Py_DECREF(args);
    }
  }
  return res;
}

SWIGRUNTIME PyObject *
SwigPyObject_oct(SwigPyObject *v)
{
  return SwigPyObject_format("%o",v);
}

SWIGRUNTIME PyObject *
SwigPyObject_hex(SwigPyObject *v)
{
  return SwigPyObject_format("%x",v);
}

SWIGRUNTIME PyObject *
SwigPyObject_repr(SwigPyObject *v)
{
  const char *name = SWIG_TypePrettyName(v->ty);
  PyObject *repr = SWIG_Python_str_FromFormat("<Swig Object of type '%s' at %p>", (name ? name : "unknown"), (void *)v);
  if (v->next) {
    PyObject *nrep = SwigPyObject_repr((SwigPyObject *)v->next);
# if PY_VERSION_HEX >= 0x03000000
    PyObject *joined = PyUnicode_Concat(repr, nrep);
    Py_DecRef(repr);
    Py_DecRef(nrep);
    repr = joined;
# else
    PyString_ConcatAndDel(&repr,nrep);
# endif
  }
  return repr;  
}

/* We need a version taking two PyObject* parameters so it's a valid
 * PyCFunction to use in swigobject_methods[]. */
SWIGRUNTIME PyObject *
SwigPyObject_repr2(PyObject *v, PyObject *SWIGUNUSEDPARM(args))
{
  return SwigPyObject_repr((SwigPyObject*)v);
}

SWIGRUNTIME int
SwigPyObject_compare(SwigPyObject *v, SwigPyObject *w)
{
  void *i = v->ptr;
  void *j = w->ptr;
  return (i < j) ? -1 : ((i > j) ? 1 : 0);
}

/* Added for Python 3.x, would it also be useful for Python 2.x? */
SWIGRUNTIME PyObject*
SwigPyObject_richcompare(SwigPyObject *v, SwigPyObject *w, int op)
{
  PyObject* res;
  if( op != Py_EQ && op != Py_NE ) {
    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
  }
  res = PyBool_FromLong( (SwigPyObject_compare(v, w)==0) == (op == Py_EQ) ? 1 : 0);
  return res;  
}


SWIGRUNTIME PyTypeObject* SwigPyObject_TypeOnce(void);

#ifdef SWIGPYTHON_BUILTIN
static swig_type_info *SwigPyObject_stype = 0;
SWIGRUNTIME PyTypeObject*
SwigPyObject_type(void) {
    SwigPyClientData *cd;
    assert(SwigPyObject_stype);
    cd = (SwigPyClientData*) SwigPyObject_stype->clientdata;
    assert(cd);
    assert(cd->pytype);
    return cd->pytype;
}
#else
SWIGRUNTIME PyTypeObject*
SwigPyObject_type(void) {
  static PyTypeObject *SWIG_STATIC_POINTER(type) = SwigPyObject_TypeOnce();
  return type;
}
#endif

SWIGRUNTIMEINLINE int
SwigPyObject_Check(PyObject *op) {
#ifdef SWIGPYTHON_BUILTIN
  PyTypeObject *target_tp = SwigPyObject_type();
  if (PyType_IsSubtype(op->ob_type, target_tp))
    return 1;
  return (strcmp(op->ob_type->tp_name, "SwigPyObject") == 0);
#else
  return (Py_TYPE(op) == SwigPyObject_type())
    || (strcmp(Py_TYPE(op)->tp_name,"SwigPyObject") == 0);
#endif
}

SWIGRUNTIME PyObject *
SwigPyObject_New(void *ptr, swig_type_info *ty, int own);

SWIGRUNTIME void
SwigPyObject_dealloc(PyObject *v)
{
  SwigPyObject *sobj = (SwigPyObject *) v;
  PyObject *next = sobj->next;
  if (sobj->own == SWIG_POINTER_OWN) {
    swig_type_info *ty = sobj->ty;
    SwigPyClientData *data = ty ? (SwigPyClientData *) ty->clientdata : 0;
    PyObject *destroy = data ? data->destroy : 0;
    if (destroy) {
      /* destroy is always a VARARGS method */
      PyObject *res;

      /* PyObject_CallFunction() has the potential to silently drop
         the active exception.  In cases of unnamed temporary
         variable or where we just finished iterating over a generator
         StopIteration will be active right now, and this needs to
         remain true upon return from SwigPyObject_dealloc.  So save
         and restore. */
      
      PyObject *type = NULL, *value = NULL, *traceback = NULL;
      PyErr_Fetch(&type, &value, &traceback);

      if (data->delargs) {
        /* we need to create a temporary object to carry the destroy operation */
        PyObject *tmp = SwigPyObject_New(sobj->ptr, ty, 0);
        res = SWIG_Python_CallFunctor(destroy, tmp);
        Py_DECREF(tmp);
      } else {
        PyCFunction meth = PyCFunction_GET_FUNCTION(destroy);
        PyObject *mself = PyCFunction_GET_SELF(destroy);
        res = ((*meth)(mself, v));
      }
      if (!res)
        PyErr_WriteUnraisable(destroy);

      PyErr_Restore(type, value, traceback);

      Py_XDECREF(res);
    } 
#if !defined(SWIG_PYTHON_SILENT_MEMLEAK)
    else {
      const char *name = SWIG_TypePrettyName(ty);
      printf("swig/python detected a memory leak of type '%s', no destructor found.\n", (name ? name : "unknown"));
    }
#endif
  } 
  Py_XDECREF(next);
  PyObject_DEL(v);
}

SWIGRUNTIME PyObject* 
SwigPyObject_append(PyObject* v, PyObject* next)
{
  SwigPyObject *sobj = (SwigPyObject *) v;
  if (!SwigPyObject_Check(next)) {
    PyErr_SetString(PyExc_TypeError, "Attempt to append a non SwigPyObject");
    return NULL;
  }
  sobj->next = next;
  Py_INCREF(next);
  return SWIG_Py_Void();
}

SWIGRUNTIME PyObject* 
SwigPyObject_next(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
{
  SwigPyObject *sobj = (SwigPyObject *) v;
  if (sobj->next) {    
    Py_INCREF(sobj->next);
    return sobj->next;
  } else {
    return SWIG_Py_Void();
  }
}

SWIGINTERN PyObject*
SwigPyObject_disown(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
{
  SwigPyObject *sobj = (SwigPyObject *)v;
  sobj->own = 0;
  return SWIG_Py_Void();
}

SWIGINTERN PyObject*
SwigPyObject_acquire(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
{
  SwigPyObject *sobj = (SwigPyObject *)v;
  sobj->own = SWIG_POINTER_OWN;
  return SWIG_Py_Void();
}

SWIGINTERN PyObject*
SwigPyObject_own(PyObject *v, PyObject *args)
{
  PyObject *val = 0;
  if (!PyArg_UnpackTuple(args, "own", 0, 1, &val)) {
    return NULL;
  } else {
    SwigPyObject *sobj = (SwigPyObject *)v;
    PyObject *obj = PyBool_FromLong(sobj->own);
    if (val) {
      if (PyObject_IsTrue(val)) {
        SwigPyObject_acquire(v,args);
      } else {
        SwigPyObject_disown(v,args);
      }
    } 
    return obj;
  }
}

static PyMethodDef
swigobject_methods[] = {
  {"disown",  SwigPyObject_disown,  METH_NOARGS,  "releases ownership of the pointer"},
  {"acquire", SwigPyObject_acquire, METH_NOARGS,  "acquires ownership of the pointer"},
  {"own",     SwigPyObject_own,     METH_VARARGS, "returns/sets ownership of the pointer"},
  {"append",  SwigPyObject_append,  METH_O,       "appends another 'this' object"},
  {"next",    SwigPyObject_next,    METH_NOARGS,  "returns the next 'this' object"},
  {"__repr__",SwigPyObject_repr2,   METH_NOARGS,  "returns object representation"},
  {0, 0, 0, 0}  
};

SWIGRUNTIME PyTypeObject*
SwigPyObject_TypeOnce(void) {
  static char swigobject_doc[] = "Swig object carries a C/C++ instance pointer";

  static PyNumberMethods SwigPyObject_as_number = {
    (binaryfunc)0, /*nb_add*/
    (binaryfunc)0, /*nb_subtract*/
    (binaryfunc)0, /*nb_multiply*/
    /* nb_divide removed in Python 3 */
#if PY_VERSION_HEX < 0x03000000
    (binaryfunc)0, /*nb_divide*/
#endif
    (binaryfunc)0, /*nb_remainder*/
    (binaryfunc)0, /*nb_divmod*/
    (ternaryfunc)0,/*nb_power*/
    (unaryfunc)0,  /*nb_negative*/
    (unaryfunc)0,  /*nb_positive*/
    (unaryfunc)0,  /*nb_absolute*/
    (inquiry)0,    /*nb_nonzero*/
    0,		   /*nb_invert*/
    0,		   /*nb_lshift*/
    0,		   /*nb_rshift*/
    0,		   /*nb_and*/
    0,		   /*nb_xor*/
    0,		   /*nb_or*/
#if PY_VERSION_HEX < 0x03000000
    0,   /*nb_coerce*/
#endif
    (unaryfunc)SwigPyObject_long, /*nb_int*/
#if PY_VERSION_HEX < 0x03000000
    (unaryfunc)SwigPyObject_long, /*nb_long*/
#else
    0, /*nb_reserved*/
#endif
    (unaryfunc)0,                 /*nb_float*/
#if PY_VERSION_HEX < 0x03000000
    (unaryfunc)SwigPyObject_oct,  /*nb_oct*/
    (unaryfunc)SwigPyObject_hex,  /*nb_hex*/
#endif
#if PY_VERSION_HEX >= 0x03050000 /* 3.5 */
    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_inplace_matrix_multiply */
#elif PY_VERSION_HEX >= 0x03000000 /* 3.0 */
    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_index, nb_inplace_divide removed */
#else
    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_index */
#endif
  };

  static PyTypeObject swigpyobject_type;
  static int type_init = 0;
  if (!type_init) {
    const PyTypeObject tmp = {
#if PY_VERSION_HEX >= 0x03000000
      PyVarObject_HEAD_INIT(NULL, 0)
#else
      PyObject_HEAD_INIT(NULL)
      0,                                    /* ob_size */
#endif
      "SwigPyObject",                       /* tp_name */
      sizeof(SwigPyObject),                 /* tp_basicsize */
      0,                                    /* tp_itemsize */
      (destructor)SwigPyObject_dealloc,     /* tp_dealloc */
      0,                                    /* tp_print */
      (getattrfunc)0,                       /* tp_getattr */
      (setattrfunc)0,                       /* tp_setattr */
#if PY_VERSION_HEX >= 0x03000000
      0, /* tp_reserved in 3.0.1, tp_compare in 3.0.0 but not used */
#else
      (cmpfunc)SwigPyObject_compare,        /* tp_compare */
#endif
      (reprfunc)SwigPyObject_repr,          /* tp_repr */
      &SwigPyObject_as_number,              /* tp_as_number */
      0,                                    /* tp_as_sequence */
      0,                                    /* tp_as_mapping */
      (hashfunc)0,                          /* tp_hash */
      (ternaryfunc)0,                       /* tp_call */
      0,                                    /* tp_str */
      PyObject_GenericGetAttr,              /* tp_getattro */
      0,                                    /* tp_setattro */
      0,                                    /* tp_as_buffer */
      Py_TPFLAGS_DEFAULT,                   /* tp_flags */
      swigobject_doc,                       /* tp_doc */
      0,                                    /* tp_traverse */
      0,                                    /* tp_clear */
      (richcmpfunc)SwigPyObject_richcompare,/* tp_richcompare */
      0,                                    /* tp_weaklistoffset */
      0,                                    /* tp_iter */
      0,                                    /* tp_iternext */
      swigobject_methods,                   /* tp_methods */
      0,                                    /* tp_members */
      0,                                    /* tp_getset */
      0,                                    /* tp_base */
      0,                                    /* tp_dict */
      0,                                    /* tp_descr_get */
      0,                                    /* tp_descr_set */
      0,                                    /* tp_dictoffset */
      0,                                    /* tp_init */
      0,                                    /* tp_alloc */
      0,                                    /* tp_new */
      0,                                    /* tp_free */
      0,                                    /* tp_is_gc */
      0,                                    /* tp_bases */
      0,                                    /* tp_mro */
      0,                                    /* tp_cache */
      0,                                    /* tp_subclasses */
      0,                                    /* tp_weaklist */
      0,                                    /* tp_del */
      0,                                    /* tp_version_tag */
#if PY_VERSION_HEX >= 0x03040000
      0,                                    /* tp_finalize */
#endif
#ifdef COUNT_ALLOCS
      0,                                    /* tp_allocs */
      0,                                    /* tp_frees */
      0,                                    /* tp_maxalloc */
      0,                                    /* tp_prev */
      0                                     /* tp_next */
#endif
    };
    swigpyobject_type = tmp;
    type_init = 1;
    if (PyType_Ready(&swigpyobject_type) < 0)
      return NULL;
  }
  return &swigpyobject_type;
}

SWIGRUNTIME PyObject *
SwigPyObject_New(void *ptr, swig_type_info *ty, int own)
{
  SwigPyObject *sobj = PyObject_NEW(SwigPyObject, SwigPyObject_type());
  if (sobj) {
    sobj->ptr  = ptr;
    sobj->ty   = ty;
    sobj->own  = own;
    sobj->next = 0;
  }
  return (PyObject *)sobj;
}

/* -----------------------------------------------------------------------------
 * Implements a simple Swig Packed type, and use it instead of string
 * ----------------------------------------------------------------------------- */

typedef struct {
  PyObject_HEAD
  void *pack;
  swig_type_info *ty;
  size_t size;
} SwigPyPacked;

SWIGRUNTIME PyObject *
SwigPyPacked_repr(SwigPyPacked *v)
{
  char result[SWIG_BUFFER_SIZE];
  if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))) {
    return SWIG_Python_str_FromFormat("<Swig Packed at %s%s>", result, v->ty->name);
  } else {
    return SWIG_Python_str_FromFormat("<Swig Packed %s>", v->ty->name);
  }  
}

SWIGRUNTIME PyObject *
SwigPyPacked_str(SwigPyPacked *v)
{
  char result[SWIG_BUFFER_SIZE];
  if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))){
    return SWIG_Python_str_FromFormat("%s%s", result, v->ty->name);
  } else {
    return SWIG_Python_str_FromChar(v->ty->name);
  }  
}

SWIGRUNTIME int
SwigPyPacked_compare(SwigPyPacked *v, SwigPyPacked *w)
{
  size_t i = v->size;
  size_t j = w->size;
  int s = (i < j) ? -1 : ((i > j) ? 1 : 0);
  return s ? s : strncmp((const char *)v->pack, (const char *)w->pack, 2*v->size);
}

SWIGRUNTIME PyTypeObject* SwigPyPacked_TypeOnce(void);

SWIGRUNTIME PyTypeObject*
SwigPyPacked_type(void) {
  static PyTypeObject *SWIG_STATIC_POINTER(type) = SwigPyPacked_TypeOnce();
  return type;
}

SWIGRUNTIMEINLINE int
SwigPyPacked_Check(PyObject *op) {
  return ((op)->ob_type == SwigPyPacked_TypeOnce()) 
    || (strcmp((op)->ob_type->tp_name,"SwigPyPacked") == 0);
}

SWIGRUNTIME void
SwigPyPacked_dealloc(PyObject *v)
{
  if (SwigPyPacked_Check(v)) {
    SwigPyPacked *sobj = (SwigPyPacked *) v;
    free(sobj->pack);
  }
  PyObject_DEL(v);
}

SWIGRUNTIME PyTypeObject*
SwigPyPacked_TypeOnce(void) {
  static char swigpacked_doc[] = "Swig object carries a C/C++ instance pointer";
  static PyTypeObject swigpypacked_type;
  static int type_init = 0;
  if (!type_init) {
    const PyTypeObject tmp = {
#if PY_VERSION_HEX>=0x03000000
      PyVarObject_HEAD_INIT(NULL, 0)
#else
      PyObject_HEAD_INIT(NULL)
      0,                                    /* ob_size */
#endif
      "SwigPyPacked",                       /* tp_name */
      sizeof(SwigPyPacked),                 /* tp_basicsize */
      0,                                    /* tp_itemsize */
      (destructor)SwigPyPacked_dealloc,     /* tp_dealloc */
      0,                                    /* tp_print */
      (getattrfunc)0,                       /* tp_getattr */
      (setattrfunc)0,                       /* tp_setattr */
#if PY_VERSION_HEX>=0x03000000
      0, /* tp_reserved in 3.0.1 */
#else
      (cmpfunc)SwigPyPacked_compare,        /* tp_compare */
#endif
      (reprfunc)SwigPyPacked_repr,          /* tp_repr */
      0,                                    /* tp_as_number */
      0,                                    /* tp_as_sequence */
      0,                                    /* tp_as_mapping */
      (hashfunc)0,                          /* tp_hash */
      (ternaryfunc)0,                       /* tp_call */
      (reprfunc)SwigPyPacked_str,           /* tp_str */
      PyObject_GenericGetAttr,              /* tp_getattro */
      0,                                    /* tp_setattro */
      0,                                    /* tp_as_buffer */
      Py_TPFLAGS_DEFAULT,                   /* tp_flags */
      swigpacked_doc,                       /* tp_doc */
      0,                                    /* tp_traverse */
      0,                                    /* tp_clear */
      0,                                    /* tp_richcompare */
      0,                                    /* tp_weaklistoffset */
      0,                                    /* tp_iter */
      0,                                    /* tp_iternext */
      0,                                    /* tp_methods */
      0,                                    /* tp_members */
      0,                                    /* tp_getset */
      0,                                    /* tp_base */
      0,                                    /* tp_dict */
      0,                                    /* tp_descr_get */
      0,                                    /* tp_descr_set */
      0,                                    /* tp_dictoffset */
      0,                                    /* tp_init */
      0,                                    /* tp_alloc */
      0,                                    /* tp_new */
      0,                                    /* tp_free */
      0,                                    /* tp_is_gc */
      0,                                    /* tp_bases */
      0,                                    /* tp_mro */
      0,                                    /* tp_cache */
      0,                                    /* tp_subclasses */
      0,                                    /* tp_weaklist */
      0,                                    /* tp_del */
      0,                                    /* tp_version_tag */
#if PY_VERSION_HEX >= 0x03040000
      0,                                    /* tp_finalize */
#endif
#ifdef COUNT_ALLOCS
      0,                                    /* tp_allocs */
      0,                                    /* tp_frees */
      0,                                    /* tp_maxalloc */
      0,                                    /* tp_prev */
      0                                     /* tp_next */
#endif
    };
    swigpypacked_type = tmp;
    type_init = 1;
    if (PyType_Ready(&swigpypacked_type) < 0)
      return NULL;
  }
  return &swigpypacked_type;
}

SWIGRUNTIME PyObject *
SwigPyPacked_New(void *ptr, size_t size, swig_type_info *ty)
{
  SwigPyPacked *sobj = PyObject_NEW(SwigPyPacked, SwigPyPacked_type());
  if (sobj) {
    void *pack = malloc(size);
    if (pack) {
      memcpy(pack, ptr, size);
      sobj->pack = pack;
      sobj->ty   = ty;
      sobj->size = size;
    } else {
      PyObject_DEL((PyObject *) sobj);
      sobj = 0;
    }
  }
  return (PyObject *) sobj;
}

SWIGRUNTIME swig_type_info *
SwigPyPacked_UnpackData(PyObject *obj, void *ptr, size_t size)
{
  if (SwigPyPacked_Check(obj)) {
    SwigPyPacked *sobj = (SwigPyPacked *)obj;
    if (sobj->size != size) return 0;
    memcpy(ptr, sobj->pack, size);
    return sobj->ty;
  } else {
    return 0;
  }
}

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

static PyObject *Swig_This_global = NULL;

SWIGRUNTIME PyObject *
SWIG_This(void)
{
  if (Swig_This_global == NULL)
    Swig_This_global = SWIG_Python_str_FromChar("this");
  return Swig_This_global;
}

/* #define SWIG_PYTHON_SLOW_GETSET_THIS */

/* TODO: I don't know how to implement the fast getset in Python 3 right now */
#if PY_VERSION_HEX>=0x03000000
#define SWIG_PYTHON_SLOW_GETSET_THIS 
#endif

SWIGRUNTIME SwigPyObject *
SWIG_Python_GetSwigThis(PyObject *pyobj) 
{
  PyObject *obj;

  if (SwigPyObject_Check(pyobj))
    return (SwigPyObject *) pyobj;

#ifdef SWIGPYTHON_BUILTIN
  (void)obj;
# ifdef PyWeakref_CheckProxy
  if (PyWeakref_CheckProxy(pyobj)) {
    pyobj = PyWeakref_GET_OBJECT(pyobj);
    if (pyobj && SwigPyObject_Check(pyobj))
      return (SwigPyObject*) pyobj;
  }
# endif
  return NULL;
#else

  obj = 0;

#if !defined(SWIG_PYTHON_SLOW_GETSET_THIS)
  if (PyInstance_Check(pyobj)) {
    obj = _PyInstance_Lookup(pyobj, SWIG_This());      
  } else {
    PyObject **dictptr = _PyObject_GetDictPtr(pyobj);
    if (dictptr != NULL) {
      PyObject *dict = *dictptr;
      obj = dict ? PyDict_GetItem(dict, SWIG_This()) : 0;
    } else {
#ifdef PyWeakref_CheckProxy
      if (PyWeakref_CheckProxy(pyobj)) {
	PyObject *wobj = PyWeakref_GET_OBJECT(pyobj);
	return wobj ? SWIG_Python_GetSwigThis(wobj) : 0;
      }
#endif
      obj = PyObject_GetAttr(pyobj,SWIG_This());
      if (obj) {
	Py_DECREF(obj);
      } else {
	if (PyErr_Occurred()) PyErr_Clear();
	return 0;
      }
    }
  }
#else
  obj = PyObject_GetAttr(pyobj,SWIG_This());
  if (obj) {
    Py_DECREF(obj);
  } else {
    if (PyErr_Occurred()) PyErr_Clear();
    return 0;
  }
#endif
  if (obj && !SwigPyObject_Check(obj)) {
    /* a PyObject is called 'this', try to get the 'real this'
       SwigPyObject from it */ 
    return SWIG_Python_GetSwigThis(obj);
  }
  return (SwigPyObject *)obj;
#endif
}

/* Acquire a pointer value */

SWIGRUNTIME int
SWIG_Python_AcquirePtr(PyObject *obj, int own) {
  if (own == SWIG_POINTER_OWN) {
    SwigPyObject *sobj = SWIG_Python_GetSwigThis(obj);
    if (sobj) {
      int oldown = sobj->own;
      sobj->own = own;
      return oldown;
    }
  }
  return 0;
}

/* Convert a pointer value */

SWIGRUNTIME int
SWIG_Python_ConvertPtrAndOwn(PyObject *obj, void **ptr, swig_type_info *ty, int flags, int *own) {
  int res;
  SwigPyObject *sobj;
  int implicit_conv = (flags & SWIG_POINTER_IMPLICIT_CONV) != 0;

  if (!obj)
    return SWIG_ERROR;
  if (obj == Py_None && !implicit_conv) {
    if (ptr)
      *ptr = 0;
    return (flags & SWIG_POINTER_NO_NULL) ? SWIG_NullReferenceError : SWIG_OK;
  }

  res = SWIG_ERROR;

  sobj = SWIG_Python_GetSwigThis(obj);
  if (own)
    *own = 0;
  while (sobj) {
    void *vptr = sobj->ptr;
    if (ty) {
      swig_type_info *to = sobj->ty;
      if (to == ty) {
        /* no type cast needed */
        if (ptr) *ptr = vptr;
        break;
      } else {
        swig_cast_info *tc = SWIG_TypeCheck(to->name,ty);
        if (!tc) {
          sobj = (SwigPyObject *)sobj->next;
        } else {
          if (ptr) {
            int newmemory = 0;
            *ptr = SWIG_TypeCast(tc,vptr,&newmemory);
            if (newmemory == SWIG_CAST_NEW_MEMORY) {
              assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */
              if (own)
                *own = *own | SWIG_CAST_NEW_MEMORY;
            }
          }
          break;
        }
      }
    } else {
      if (ptr) *ptr = vptr;
      break;
    }
  }
  if (sobj) {
    if (own)
      *own = *own | sobj->own;
    if (flags & SWIG_POINTER_DISOWN) {
      sobj->own = 0;
    }
    res = SWIG_OK;
  } else {
    if (implicit_conv) {
      SwigPyClientData *data = ty ? (SwigPyClientData *) ty->clientdata : 0;
      if (data && !data->implicitconv) {
        PyObject *klass = data->klass;
        if (klass) {
          PyObject *impconv;
          data->implicitconv = 1; /* avoid recursion and call 'explicit' constructors*/
          impconv = SWIG_Python_CallFunctor(klass, obj);
          data->implicitconv = 0;
          if (PyErr_Occurred()) {
            PyErr_Clear();
            impconv = 0;
          }
          if (impconv) {
            SwigPyObject *iobj = SWIG_Python_GetSwigThis(impconv);
            if (iobj) {
              void *vptr;
              res = SWIG_Python_ConvertPtrAndOwn((PyObject*)iobj, &vptr, ty, 0, 0);
              if (SWIG_IsOK(res)) {
                if (ptr) {
                  *ptr = vptr;
                  /* transfer the ownership to 'ptr' */
                  iobj->own = 0;
                  res = SWIG_AddCast(res);
                  res = SWIG_AddNewMask(res);
                } else {
                  res = SWIG_AddCast(res);		    
                }
              }
            }
            Py_DECREF(impconv);
          }
        }
      }
      if (!SWIG_IsOK(res) && obj == Py_None) {
        if (ptr)
          *ptr = 0;
        if (PyErr_Occurred())
          PyErr_Clear();
        res = SWIG_OK;
      }
    }
  }
  return res;
}

/* Convert a function ptr value */

SWIGRUNTIME int
SWIG_Python_ConvertFunctionPtr(PyObject *obj, void **ptr, swig_type_info *ty) {
  if (!PyCFunction_Check(obj)) {
    return SWIG_ConvertPtr(obj, ptr, ty, 0);
  } else {
    void *vptr = 0;
    swig_cast_info *tc;

    /* here we get the method pointer for callbacks */
    const char *doc = (((PyCFunctionObject *)obj) -> m_ml -> ml_doc);
    const char *desc = doc ? strstr(doc, "swig_ptr: ") : 0;
    if (desc)
      desc = ty ? SWIG_UnpackVoidPtr(desc + 10, &vptr, ty->name) : 0;
    if (!desc)
      return SWIG_ERROR;
    tc = SWIG_TypeCheck(desc,ty);
    if (tc) {
      int newmemory = 0;
      *ptr = SWIG_TypeCast(tc,vptr,&newmemory);
      assert(!newmemory); /* newmemory handling not yet implemented */
    } else {
      return SWIG_ERROR;
    }
    return SWIG_OK;
  }
}

/* Convert a packed pointer value */

SWIGRUNTIME int
SWIG_Python_ConvertPacked(PyObject *obj, void *ptr, size_t sz, swig_type_info *ty) {
  swig_type_info *to = SwigPyPacked_UnpackData(obj, ptr, sz);
  if (!to) return SWIG_ERROR;
  if (ty) {
    if (to != ty) {
      /* check type cast? */
      swig_cast_info *tc = SWIG_TypeCheck(to->name,ty);
      if (!tc) return SWIG_ERROR;
    }
  }
  return SWIG_OK;
}  

/* -----------------------------------------------------------------------------
 * Create a new pointer object
 * ----------------------------------------------------------------------------- */

/*
  Create a new instance object, without calling __init__, and set the
  'this' attribute.
*/

SWIGRUNTIME PyObject* 
SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this)
{
  PyObject *inst = 0;
  PyObject *newraw = data->newraw;
  if (newraw) {
    inst = PyObject_Call(newraw, data->newargs, NULL);
    if (inst) {
#if !defined(SWIG_PYTHON_SLOW_GETSET_THIS)
      PyObject **dictptr = _PyObject_GetDictPtr(inst);
      if (dictptr != NULL) {
	PyObject *dict = *dictptr;
	if (dict == NULL) {
	  dict = PyDict_New();
	  *dictptr = dict;
	  PyDict_SetItem(dict, SWIG_This(), swig_this);
	}
      }
#else
      PyObject *key = SWIG_This();
      PyObject_SetAttr(inst, key, swig_this);
#endif
    }
  } else {
#if PY_VERSION_HEX >= 0x03000000
    PyObject *empty_args = PyTuple_New(0);
    if (empty_args) {
      PyObject *empty_kwargs = PyDict_New();
      if (empty_kwargs) {
        inst = ((PyTypeObject *)data->newargs)->tp_new((PyTypeObject *)data->newargs, empty_args, empty_kwargs);
        Py_DECREF(empty_kwargs);
        if (inst) {
          PyObject_SetAttr(inst, SWIG_This(), swig_this);
          Py_TYPE(inst)->tp_flags &= ~Py_TPFLAGS_VALID_VERSION_TAG;
        }
      }
      Py_DECREF(empty_args);
    }
#else
    PyObject *dict = PyDict_New();
    if (dict) {
      PyDict_SetItem(dict, SWIG_This(), swig_this);
      inst = PyInstance_NewRaw(data->newargs, dict);
      Py_DECREF(dict);
    }
#endif
  }
  return inst;
}

SWIGRUNTIME void
SWIG_Python_SetSwigThis(PyObject *inst, PyObject *swig_this)
{
 PyObject *dict;
#if !defined(SWIG_PYTHON_SLOW_GETSET_THIS)
 PyObject **dictptr = _PyObject_GetDictPtr(inst);
 if (dictptr != NULL) {
   dict = *dictptr;
   if (dict == NULL) {
     dict = PyDict_New();
     *dictptr = dict;
   }
   PyDict_SetItem(dict, SWIG_This(), swig_this);
   return;
 }
#endif
 dict = PyObject_GetAttrString(inst, "__dict__");
 PyDict_SetItem(dict, SWIG_This(), swig_this);
 Py_DECREF(dict);
} 


SWIGINTERN PyObject *
SWIG_Python_InitShadowInstance(PyObject *args) {
  PyObject *obj[2];
  if (!SWIG_Python_UnpackTuple(args, "swiginit", 2, 2, obj)) {
    return NULL;
  } else {
    SwigPyObject *sthis = SWIG_Python_GetSwigThis(obj[0]);
    if (sthis) {
      SwigPyObject_append((PyObject*) sthis, obj[1]);
    } else {
      SWIG_Python_SetSwigThis(obj[0], obj[1]);
    }
    return SWIG_Py_Void();
  }
}

/* Create a new pointer object */

SWIGRUNTIME PyObject *
SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int flags) {
  SwigPyClientData *clientdata;
  PyObject * robj;
  int own;

  if (!ptr)
    return SWIG_Py_Void();

  clientdata = type ? (SwigPyClientData *)(type->clientdata) : 0;
  own = (flags & SWIG_POINTER_OWN) ? SWIG_POINTER_OWN : 0;
  if (clientdata && clientdata->pytype) {
    SwigPyObject *newobj;
    if (flags & SWIG_BUILTIN_TP_INIT) {
      newobj = (SwigPyObject*) self;
      if (newobj->ptr) {
        PyObject *next_self = clientdata->pytype->tp_alloc(clientdata->pytype, 0);
        while (newobj->next)
	  newobj = (SwigPyObject *) newobj->next;
        newobj->next = next_self;
        newobj = (SwigPyObject *)next_self;
#ifdef SWIGPYTHON_BUILTIN
        newobj->dict = 0;
#endif
      }
    } else {
      newobj = PyObject_New(SwigPyObject, clientdata->pytype);
#ifdef SWIGPYTHON_BUILTIN
      newobj->dict = 0;
#endif
    }
    if (newobj) {
      newobj->ptr = ptr;
      newobj->ty = type;
      newobj->own = own;
      newobj->next = 0;
      return (PyObject*) newobj;
    }
    return SWIG_Py_Void();
  }

  assert(!(flags & SWIG_BUILTIN_TP_INIT));

  robj = SwigPyObject_New(ptr, type, own);
  if (robj && clientdata && !(flags & SWIG_POINTER_NOSHADOW)) {
    PyObject *inst = SWIG_Python_NewShadowInstance(clientdata, robj);
    Py_DECREF(robj);
    robj = inst;
  }
  return robj;
}

/* Create a new packed object */

SWIGRUNTIMEINLINE PyObject *
SWIG_Python_NewPackedObj(void *ptr, size_t sz, swig_type_info *type) {
  return ptr ? SwigPyPacked_New((void *) ptr, sz, type) : SWIG_Py_Void();
}

/* -----------------------------------------------------------------------------*
 *  Get type list 
 * -----------------------------------------------------------------------------*/

#ifdef SWIG_LINK_RUNTIME
void *SWIG_ReturnGlobalTypeList(void *);
#endif

SWIGRUNTIME swig_module_info *
SWIG_Python_GetModule(void *SWIGUNUSEDPARM(clientdata)) {
  static void *type_pointer = (void *)0;
  /* first check if module already created */
  if (!type_pointer) {
#ifdef SWIG_LINK_RUNTIME
    type_pointer = SWIG_ReturnGlobalTypeList((void *)0);
#else
    type_pointer = PyCapsule_Import(SWIGPY_CAPSULE_NAME, 0);
    if (PyErr_Occurred()) {
      PyErr_Clear();
      type_pointer = (void *)0;
    }
#endif
  }
  return (swig_module_info *) type_pointer;
}

SWIGRUNTIME void
SWIG_Python_DestroyModule(PyObject *obj)
{
  swig_module_info *swig_module = (swig_module_info *) PyCapsule_GetPointer(obj, SWIGPY_CAPSULE_NAME);
  swig_type_info **types = swig_module->types;
  size_t i;
  for (i =0; i < swig_module->size; ++i) {
    swig_type_info *ty = types[i];
    if (ty->owndata) {
      SwigPyClientData *data = (SwigPyClientData *) ty->clientdata;
      if (data) SwigPyClientData_Del(data);
    }
  }
  Py_DECREF(SWIG_This());
  Swig_This_global = NULL;
}

SWIGRUNTIME void
SWIG_Python_SetModule(swig_module_info *swig_module) {
#if PY_VERSION_HEX >= 0x03000000
 /* Add a dummy module object into sys.modules */
  PyObject *module = PyImport_AddModule("swig_runtime_data" SWIG_RUNTIME_VERSION);
#else
  static PyMethodDef swig_empty_runtime_method_table[] = { {NULL, NULL, 0, NULL} }; /* Sentinel */
  PyObject *module = Py_InitModule("swig_runtime_data" SWIG_RUNTIME_VERSION, swig_empty_runtime_method_table);
#endif
  PyObject *pointer = PyCapsule_New((void *) swig_module, SWIGPY_CAPSULE_NAME, SWIG_Python_DestroyModule);
  if (pointer && module) {
    PyModule_AddObject(module, "type_pointer_capsule" SWIG_TYPE_TABLE_NAME, pointer);
  } else {
    Py_XDECREF(pointer);
  }
}

/* The python cached type query */
SWIGRUNTIME PyObject *
SWIG_Python_TypeCache(void) {
  static PyObject *SWIG_STATIC_POINTER(cache) = PyDict_New();
  return cache;
}

SWIGRUNTIME swig_type_info *
SWIG_Python_TypeQuery(const char *type)
{
  PyObject *cache = SWIG_Python_TypeCache();
  PyObject *key = SWIG_Python_str_FromChar(type); 
  PyObject *obj = PyDict_GetItem(cache, key);
  swig_type_info *descriptor;
  if (obj) {
    descriptor = (swig_type_info *) PyCapsule_GetPointer(obj, NULL);
  } else {
    swig_module_info *swig_module = SWIG_GetModule(0);
    descriptor = SWIG_TypeQueryModule(swig_module, swig_module, type);
    if (descriptor) {
      obj = PyCapsule_New((void*) descriptor, NULL, NULL);
      PyDict_SetItem(cache, key, obj);
      Py_DECREF(obj);
    }
  }
  Py_DECREF(key);
  return descriptor;
}

/* 
   For backward compatibility only
*/
#define SWIG_POINTER_EXCEPTION  0
#define SWIG_arg_fail(arg)      SWIG_Python_ArgFail(arg)
#define SWIG_MustGetPtr(p, type, argnum, flags)  SWIG_Python_MustGetPtr(p, type, argnum, flags)

SWIGRUNTIME int
SWIG_Python_AddErrMesg(const char* mesg, int infront)
{  
  if (PyErr_Occurred()) {
    PyObject *type = 0;
    PyObject *value = 0;
    PyObject *traceback = 0;
    PyErr_Fetch(&type, &value, &traceback);
    if (value) {
      PyObject *old_str = PyObject_Str(value);
      const char *tmp = SWIG_Python_str_AsChar(old_str);
      const char *errmesg = tmp ? tmp : "Invalid error message";
      Py_XINCREF(type);
      PyErr_Clear();
      if (infront) {
	PyErr_Format(type, "%s %s", mesg, errmesg);
      } else {
	PyErr_Format(type, "%s %s", errmesg, mesg);
      }
      SWIG_Python_str_DelForPy3(tmp);
      Py_DECREF(old_str);
    }
    return 1;
  } else {
    return 0;
  }
}
  
SWIGRUNTIME int
SWIG_Python_ArgFail(int argnum)
{
  if (PyErr_Occurred()) {
    /* add information about failing argument */
    char mesg[256];
    PyOS_snprintf(mesg, sizeof(mesg), "argument number %d:", argnum);
    return SWIG_Python_AddErrMesg(mesg, 1);
  } else {
    return 0;
  }
}

SWIGRUNTIMEINLINE const char *
SwigPyObject_GetDesc(PyObject *self)
{
  SwigPyObject *v = (SwigPyObject *)self;
  swig_type_info *ty = v ? v->ty : 0;
  return ty ? ty->str : "";
}

SWIGRUNTIME void
SWIG_Python_TypeError(const char *type, PyObject *obj)
{
  if (type) {
#if defined(SWIG_COBJECT_TYPES)
    if (obj && SwigPyObject_Check(obj)) {
      const char *otype = (const char *) SwigPyObject_GetDesc(obj);
      if (otype) {
	PyErr_Format(PyExc_TypeError, "a '%s' is expected, 'SwigPyObject(%s)' is received",
		     type, otype);
	return;
      }
    } else 
#endif      
    {
      const char *otype = (obj ? obj->ob_type->tp_name : 0); 
      if (otype) {
	PyObject *str = PyObject_Str(obj);
	const char *cstr = str ? SWIG_Python_str_AsChar(str) : 0;
	if (cstr) {
	  PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s(%s)' is received",
		       type, otype, cstr);
          SWIG_Python_str_DelForPy3(cstr);
	} else {
	  PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s' is received",
		       type, otype);
	}
	Py_XDECREF(str);
	return;
      }
    }   
    PyErr_Format(PyExc_TypeError, "a '%s' is expected", type);
  } else {
    PyErr_Format(PyExc_TypeError, "unexpected type is received");
  }
}


/* Convert a pointer value, signal an exception on a type mismatch */
SWIGRUNTIME void *
SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int SWIGUNUSEDPARM(argnum), int flags) {
  void *result;
  if (SWIG_Python_ConvertPtr(obj, &result, ty, flags) == -1) {
    PyErr_Clear();
#if SWIG_POINTER_EXCEPTION
    if (flags) {
      SWIG_Python_TypeError(SWIG_TypePrettyName(ty), obj);
      SWIG_Python_ArgFail(argnum);
    }
#endif
  }
  return result;
}

#ifdef SWIGPYTHON_BUILTIN
SWIGRUNTIME int
SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
  PyTypeObject *tp = obj->ob_type;
  PyObject *descr;
  PyObject *encoded_name;
  descrsetfunc f;
  int res = -1;

# ifdef Py_USING_UNICODE
  if (PyString_Check(name)) {
    name = PyUnicode_Decode(PyString_AsString(name), PyString_Size(name), NULL, NULL);
    if (!name)
      return -1;
  } else if (!PyUnicode_Check(name))
# else
  if (!PyString_Check(name))
# endif
  {
    PyErr_Format(PyExc_TypeError, "attribute name must be string, not '%.200s'", name->ob_type->tp_name);
    return -1;
  } else {
    Py_INCREF(name);
  }

  if (!tp->tp_dict) {
    if (PyType_Ready(tp) < 0)
      goto done;
  }

  descr = _PyType_Lookup(tp, name);
  f = NULL;
  if (descr != NULL)
    f = descr->ob_type->tp_descr_set;
  if (!f) {
    if (PyString_Check(name)) {
      encoded_name = name;
      Py_INCREF(name);
    } else {
      encoded_name = PyUnicode_AsUTF8String(name);
      if (!encoded_name)
        return -1;
    }
    PyErr_Format(PyExc_AttributeError, "'%.100s' object has no attribute '%.200s'", tp->tp_name, PyString_AsString(encoded_name));
    Py_DECREF(encoded_name);
  } else {
    res = f(descr, obj, value);
  }
  
  done:
  Py_DECREF(name);
  return res;
}
#endif


#ifdef __cplusplus
}
#endif



#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 



#ifdef __cplusplus
extern "C" {
#endif

/* Method creation and docstring support functions */

SWIGINTERN PyMethodDef *SWIG_PythonGetProxyDoc(const char *name);
SWIGINTERN PyObject *SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func);
SWIGINTERN PyObject *SWIG_PyStaticMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func);

#ifdef __cplusplus
}
#endif


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


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

#define SWIGTYPE_p_Account swig_types[0]
#define SWIGTYPE_p_AccountClass swig_types[1]
#define SWIGTYPE_p_AccountList swig_types[2]
#define SWIGTYPE_p_FILE swig_types[3]
#define SWIGTYPE_p_GCompareFunc swig_types[4]
#define SWIGTYPE_p_GDate swig_types[5]
#define SWIGTYPE_p_GHashTable swig_types[6]
#define SWIGTYPE_p_GList swig_types[7]
#define SWIGTYPE_p_GNCAccountType swig_types[8]
#define SWIGTYPE_p_GNCLot swig_types[9]
#define SWIGTYPE_p_GNCNumericErrorCode swig_types[10]
#define SWIGTYPE_p_GNCPlaceholderType swig_types[11]
#define SWIGTYPE_p_GNCPolicy swig_types[12]
#define SWIGTYPE_p_GNCPrice swig_types[13]
#define SWIGTYPE_p_GSList swig_types[14]
#define SWIGTYPE_p_GType swig_types[15]
#define SWIGTYPE_p_GValue swig_types[16]
#define SWIGTYPE_p_GncAmountType swig_types[17]
#define SWIGTYPE_p_GncBillTermType swig_types[18]
#define SWIGTYPE_p_GncDiscountHow swig_types[19]
#define SWIGTYPE_p_GncEntryPaymentType swig_types[20]
#define SWIGTYPE_p_GncImportMatchMap swig_types[21]
#define SWIGTYPE_p_GncInvoiceType swig_types[22]
#define SWIGTYPE_p_GncLotClass swig_types[23]
#define SWIGTYPE_p_GncOrder swig_types[24]
#define SWIGTYPE_p_GncOwnerType swig_types[25]
#define SWIGTYPE_p_GncTaxIncluded swig_types[26]
#define SWIGTYPE_p_LotList swig_types[27]
#define SWIGTYPE_p_PriceRemoveKeepOptions swig_types[28]
#define SWIGTYPE_p_PriceRemoveSourceFlags swig_types[29]
#define SWIGTYPE_p_PriceSource swig_types[30]
#define SWIGTYPE_p_QofBackend swig_types[31]
#define SWIGTYPE_p_QofBackendError swig_types[32]
#define SWIGTYPE_p_QofBook swig_types[33]
#define SWIGTYPE_p_QofCharMatch swig_types[34]
#define SWIGTYPE_p_QofCollection_s swig_types[35]
#define SWIGTYPE_p_QofDateMatch swig_types[36]
#define SWIGTYPE_p_QofGuidMatch swig_types[37]
#define SWIGTYPE_p_QofInstance swig_types[38]
#define SWIGTYPE_p_QofInstanceClass swig_types[39]
#define SWIGTYPE_p_QofNumericMatch swig_types[40]
#define SWIGTYPE_p_QofParam swig_types[41]
#define SWIGTYPE_p_QofQueryCompare swig_types[42]
#define SWIGTYPE_p_QofQueryOp swig_types[43]
#define SWIGTYPE_p_QofSessionImpl swig_types[44]
#define SWIGTYPE_p_QofStringMatch swig_types[45]
#define SWIGTYPE_p_QofType swig_types[46]
#define SWIGTYPE_p_QuoteSourceType swig_types[47]
#define SWIGTYPE_p_Split swig_types[48]
#define SWIGTYPE_p_SplitList swig_types[49]
#define SWIGTYPE_p_Transaction swig_types[50]
#define SWIGTYPE_p_TransactionCallback swig_types[51]
#define SWIGTYPE_p__GncCommodityClass swig_types[52]
#define SWIGTYPE_p__GncCommodityNamespaceClass swig_types[53]
#define SWIGTYPE_p__GncPriceClass swig_types[54]
#define SWIGTYPE_p__GncPriceDBClass swig_types[55]
#define SWIGTYPE_p__QofQuery swig_types[56]
#define SWIGTYPE_p__QofQueryPredData swig_types[57]
#define SWIGTYPE_p__SplitClass swig_types[58]
#define SWIGTYPE_p__TransactionClass swig_types[59]
#define SWIGTYPE_p__gncAccountValue swig_types[60]
#define SWIGTYPE_p__gncAddress swig_types[61]
#define SWIGTYPE_p__gncAddressClass swig_types[62]
#define SWIGTYPE_p__gncBillTerm swig_types[63]
#define SWIGTYPE_p__gncBillTermClass swig_types[64]
#define SWIGTYPE_p__gncCustomer swig_types[65]
#define SWIGTYPE_p__gncCustomerClass swig_types[66]
#define SWIGTYPE_p__gncEmployee swig_types[67]
#define SWIGTYPE_p__gncEmployeeClass swig_types[68]
#define SWIGTYPE_p__gncEntry swig_types[69]
#define SWIGTYPE_p__gncEntryClass swig_types[70]
#define SWIGTYPE_p__gncGuid swig_types[71]
#define SWIGTYPE_p__gncInvoice swig_types[72]
#define SWIGTYPE_p__gncInvoiceClass swig_types[73]
#define SWIGTYPE_p__gncJob swig_types[74]
#define SWIGTYPE_p__gncJobClass swig_types[75]
#define SWIGTYPE_p__gncOwner swig_types[76]
#define SWIGTYPE_p__gncTaxTable swig_types[77]
#define SWIGTYPE_p__gncTaxTableClass swig_types[78]
#define SWIGTYPE_p__gncTaxTableEntry swig_types[79]
#define SWIGTYPE_p__gncVendor swig_types[80]
#define SWIGTYPE_p__gncVendorClass swig_types[81]
#define SWIGTYPE_p__gnc_monetary swig_types[82]
#define SWIGTYPE_p__gnc_numeric swig_types[83]
#define SWIGTYPE_p_char swig_types[84]
#define SWIGTYPE_p_f_p_Account_p_void__p_void swig_types[85]
#define SWIGTYPE_p_f_p_Account_p_void__void swig_types[86]
#define SWIGTYPE_p_f_p_GNCLot_p_void__gboolean swig_types[87]
#define SWIGTYPE_p_f_p_GNCLot_p_void__p_void swig_types[88]
#define SWIGTYPE_p_f_p_GNCPrice_p_void__gboolean swig_types[89]
#define SWIGTYPE_p_f_p_QofInstance_p_void__void swig_types[90]
#define SWIGTYPE_p_f_p_gnc_commodity_p_void__gboolean swig_types[91]
#define SWIGTYPE_p_f_p_q_const__char_double__void swig_types[92]
#define SWIGTYPE_p_gboolean swig_types[93]
#define SWIGTYPE_p_gconstpointer swig_types[94]
#define SWIGTYPE_p_gnc_commodity swig_types[95]
#define SWIGTYPE_p_gnc_commodity_namespace swig_types[96]
#define SWIGTYPE_p_gnc_commodity_table swig_types[97]
#define SWIGTYPE_p_gnc_price_db_s swig_types[98]
#define SWIGTYPE_p_gnc_quote_source swig_types[99]
#define SWIGTYPE_p_guint32 swig_types[100]
#define SWIGTYPE_p_guint8 swig_types[101]
#define SWIGTYPE_p_gunichar swig_types[102]
#define SWIGTYPE_p_imap_info swig_types[103]
#define SWIGTYPE_p_int swig_types[104]
#define SWIGTYPE_p_long_long swig_types[105]
#define SWIGTYPE_p_p_GList swig_types[106]
#define SWIGTYPE_p_p_Transaction swig_types[107]
#define SWIGTYPE_p_short swig_types[108]
#define SWIGTYPE_p_signed_char swig_types[109]
#define SWIGTYPE_p_time64 swig_types[110]
#define SWIGTYPE_p_unsigned_char swig_types[111]
#define SWIGTYPE_p_unsigned_int swig_types[112]
#define SWIGTYPE_p_unsigned_long_long swig_types[113]
#define SWIGTYPE_p_unsigned_short swig_types[114]
#define SWIGTYPE_p_void swig_types[115]
static swig_type_info *swig_types[117];
static swig_module_info swig_module = {swig_types, 116, 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) -------- */

#ifdef SWIG_TypeQuery
# undef SWIG_TypeQuery
#endif
#define SWIG_TypeQuery SWIG_Python_TypeQuery

/*-----------------------------------------------
              @(target):= _gnucash_core_c.so
  ------------------------------------------------*/
#if PY_VERSION_HEX >= 0x03000000
#  define SWIG_init    PyInit__gnucash_core_c

#else
#  define SWIG_init    init_gnucash_core_c

#endif
#define SWIG_name    "_gnucash_core_c"

#define SWIGVERSION 0x040001 
#define SWIG_VERSION SWIGVERSION


#define SWIG_as_voidptr(a) (void *)((const void *)(a)) 
#define SWIG_as_voidptrptr(a) ((void)SWIG_as_voidptr(*a),(void**)(a)) 


#include <config.h>
#include <datetime.h>
#include "qofsession.h"
#include "qofbook.h"
#include "qofbackend.h"
#include "qoflog.h"
#include "qofutil.h"
#include "qofid.h"
#include "guid.h"
#include "qofquery.h"
#include "qofquerycore.h"
#include "gnc-module.h"
#include "gnc-engine.h"
#include "Transaction.h"
#include "Split.h"
#include "Account.h"
#include "gnc-commodity.h"
#include "gnc-environment.h"
#include "gnc-lot.h"
#include "gnc-numeric.h"
#include "gncCustomer.h"
#include "gncCustomerP.h"
#include "gncEmployee.h"
#include "gncVendor.h"
#include "gncVendorP.h"
#include "gncAddress.h"
#include "gncBillTerm.h"
#include "gncOwner.h"
#include "gncInvoice.h"
#include "gncInvoiceP.h"
#include "gncJob.h"
#include "gncEntry.h"
#include "gncTaxTable.h"
#include "gncIDSearch.h"
#include "gnc-pricedb.h"
#include "gnc-prefs-utils.h"
#include "cap-gains.h"
#include "Scrub3.h"


#include <stdint.h>		// Use the C99 official header


static const GncGUID * gncSplitGetGUID(Split *x)
{ return qof_instance_get_guid(QOF_INSTANCE(x)); }
static const GncGUID * gncTransGetGUID(Transaction *x)
{ return qof_instance_get_guid(QOF_INSTANCE(x)); }
static const GncGUID * gncAccountGetGUID(Account *x)
{ return qof_instance_get_guid(QOF_INSTANCE(x)); }


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


SWIGINTERNINLINE PyObject *
SWIG_FromCharPtrAndSize(const char* carray, size_t size)
{
  if (carray) {
    if (size > INT_MAX) {
      swig_type_info* pchar_descriptor = SWIG_pchar_descriptor();
      return pchar_descriptor ? 
	SWIG_InternalNewPointerObj((char *)(carray), pchar_descriptor, 0) : SWIG_Py_Void();
    } else {
#if PY_VERSION_HEX >= 0x03000000
#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
      return PyBytes_FromStringAndSize(carray, (Py_ssize_t)(size));
#else
      return PyUnicode_DecodeUTF8(carray, (Py_ssize_t)(size), "surrogateescape");
#endif
#else
      return PyString_FromStringAndSize(carray, (Py_ssize_t)(size));
#endif
    }
  } else {
    return SWIG_Py_Void();
  }
}


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


SWIGINTERN int
SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc)
{
#if PY_VERSION_HEX>=0x03000000
#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
  if (PyBytes_Check(obj))
#else
  if (PyUnicode_Check(obj))
#endif
#else  
  if (PyString_Check(obj))
#endif
  {
    char *cstr; Py_ssize_t len;
    int ret = SWIG_OK;
#if PY_VERSION_HEX>=0x03000000
#if !defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
    if (!alloc && cptr) {
        /* We can't allow converting without allocation, since the internal
           representation of string in Python 3 is UCS-2/UCS-4 but we require
           a UTF-8 representation.
           TODO(bhy) More detailed explanation */
        return SWIG_RuntimeError;
    }
    obj = PyUnicode_AsUTF8String(obj);
    if (!obj)
      return SWIG_TypeError;
    if (alloc)
      *alloc = SWIG_NEWOBJ;
#endif
    PyBytes_AsStringAndSize(obj, &cstr, &len);
#else
    PyString_AsStringAndSize(obj, &cstr, &len);
#endif
    if (cptr) {
      if (alloc) {
	if (*alloc == SWIG_NEWOBJ) {
	  *cptr = (char *)memcpy(malloc((len + 1)*sizeof(char)), cstr, sizeof(char)*(len + 1));
	  *alloc = SWIG_NEWOBJ;
	} else {
	  *cptr = cstr;
	  *alloc = SWIG_OLDOBJ;
	}
      } else {
#if PY_VERSION_HEX>=0x03000000
#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
	*cptr = PyBytes_AsString(obj);
#else
	assert(0); /* Should never reach here with Unicode strings in Python 3 */
#endif
#else
	*cptr = SWIG_Python_str_AsChar(obj);
        if (!*cptr)
          ret = SWIG_TypeError;
#endif
      }
    }
    if (psize) *psize = len + 1;
#if PY_VERSION_HEX>=0x03000000 && !defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
    Py_XDECREF(obj);
#endif
    return ret;
  } else {
#if defined(SWIG_PYTHON_2_UNICODE)
#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
#error "Cannot use both SWIG_PYTHON_2_UNICODE and SWIG_PYTHON_STRICT_BYTE_CHAR at once"
#endif
#if PY_VERSION_HEX<0x03000000
    if (PyUnicode_Check(obj)) {
      char *cstr; Py_ssize_t len;
      if (!alloc && cptr) {
        return SWIG_RuntimeError;
      }
      obj = PyUnicode_AsUTF8String(obj);
      if (!obj)
        return SWIG_TypeError;
      if (PyString_AsStringAndSize(obj, &cstr, &len) != -1) {
        if (cptr) {
          if (alloc) *alloc = SWIG_NEWOBJ;
          *cptr = (char *)memcpy(malloc((len + 1)*sizeof(char)), cstr, sizeof(char)*(len + 1));
        }
        if (psize) *psize = len + 1;

        Py_XDECREF(obj);
        return SWIG_OK;
      } else {
        Py_XDECREF(obj);
      }
    }
#endif
#endif

    swig_type_info* pchar_descriptor = SWIG_pchar_descriptor();
    if (pchar_descriptor) {
      void* vptr = 0;
      if (SWIG_ConvertPtr(obj, &vptr, pchar_descriptor, 0) == SWIG_OK) {
	if (cptr) *cptr = (char *) vptr;
	if (psize) *psize = vptr ? (strlen((char *)vptr) + 1) : 0;
	if (alloc) *alloc = SWIG_OLDOBJ;
	return SWIG_OK;
      }
    }
  }
  return SWIG_TypeError;
}





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


SWIGINTERN int
SWIG_AsCharArray(PyObject * 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)) {
    /* special case of single char conversion when we don't need space for NUL */
    if (size == 1 && csize == 2 && cptr && !cptr[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) {
	free((char*)cptr);
	res = SWIG_DelNewMask(res);
      }      
      return res;
    }
    if (alloc == SWIG_NEWOBJ) free((char*)cptr);
  }
  return SWIG_TypeError;
}


#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 (PyObject *obj, double *val)
{
  int res = SWIG_TypeError;
  if (PyFloat_Check(obj)) {
    if (val) *val = PyFloat_AsDouble(obj);
    return SWIG_OK;
#if PY_VERSION_HEX < 0x03000000
  } else if (PyInt_Check(obj)) {
    if (val) *val = (double) PyInt_AsLong(obj);
    return SWIG_OK;
#endif
  } else if (PyLong_Check(obj)) {
    double v = PyLong_AsDouble(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      PyErr_Clear();
    }
  }
#ifdef SWIG_PYTHON_CAST_MODE
  {
    int dispatch = 0;
    double d = PyFloat_AsDouble(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = d;
      return SWIG_AddCast(SWIG_OK);
    } else {
      PyErr_Clear();
    }
    if (!dispatch) {
      long v = PyLong_AsLong(obj);
      if (!PyErr_Occurred()) {
	if (val) *val = v;
	return SWIG_AddCast(SWIG_AddCast(SWIG_OK));
      } else {
	PyErr_Clear();
      }
    }
  }
#endif
  return res;
}


#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_long (PyObject *obj, long* val)
{
#if PY_VERSION_HEX < 0x03000000
  if (PyInt_Check(obj)) {
    if (val) *val = PyInt_AsLong(obj);
    return SWIG_OK;
  } else
#endif
  if (PyLong_Check(obj)) {
    long v = PyLong_AsLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      PyErr_Clear();
      return SWIG_OverflowError;
    }
  }
#ifdef SWIG_PYTHON_CAST_MODE
  {
    int dispatch = 0;
    long v = PyInt_AsLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_AddCast(SWIG_OK);
    } else {
      PyErr_Clear();
    }
    if (!dispatch) {
      double d;
      int res = SWIG_AddCast(SWIG_AsVal_double (obj,&d));
      if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, LONG_MIN, LONG_MAX)) {
	if (val) *val = (long)(d);
	return res;
      }
    }
  }
#endif
  return SWIG_TypeError;
}


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


SWIGINTERNINLINE PyObject*
  SWIG_From_int  (int value)
{
  return PyInt_FromLong((long) value);
}


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


#if defined(LLONG_MAX) && !defined(SWIG_LONG_LONG_AVAILABLE)
#  define SWIG_LONG_LONG_AVAILABLE
#endif


#ifdef SWIG_LONG_LONG_AVAILABLE
SWIGINTERNINLINE PyObject* 
SWIG_From_long_SS_long  (long long value)
{
  return ((value < LONG_MIN) || (value > LONG_MAX)) ?
    PyLong_FromLongLong(value) : PyInt_FromLong((long)(value));
}
#endif


#ifdef SWIG_LONG_LONG_AVAILABLE
SWIGINTERN int
SWIG_AsVal_long_SS_long (PyObject *obj, long long *val)
{
  int res = SWIG_TypeError;
  if (PyLong_Check(obj)) {
    long long v = PyLong_AsLongLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      PyErr_Clear();
      res = SWIG_OverflowError;
    }
  } else {
    long v;
    res = SWIG_AsVal_long (obj,&v);
    if (SWIG_IsOK(res)) {
      if (val) *val = v;
      return res;
    }
  }
#ifdef SWIG_PYTHON_CAST_MODE
  {
    const double mant_max = 1LL << DBL_MANT_DIG;
    const double mant_min = -mant_max;
    double d;
    res = SWIG_AsVal_double (obj,&d);
    if (SWIG_IsOK(res) && !SWIG_CanCastAsInteger(&d, mant_min, mant_max))
      return SWIG_OverflowError;
    if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, mant_min, mant_max)) {
      if (val) *val = (long long)(d);
      return SWIG_AddCast(res);
    }
    res = SWIG_TypeError;
  }
#endif
  return res;
}
#endif


SWIGINTERN int
SWIG_AsVal_short (PyObject * obj, short *val)
{
  long v;
  int res = SWIG_AsVal_long (obj, &v);
  if (SWIG_IsOK(res)) {
    if ((v < SHRT_MIN || v > SHRT_MAX)) {
      return SWIG_OverflowError;
    } else {
      if (val) *val = (short)(v);
    }
  }  
  return res;
}


SWIGINTERN int
SWIG_AsVal_unsigned_SS_long (PyObject *obj, unsigned long *val) 
{
#if PY_VERSION_HEX < 0x03000000
  if (PyInt_Check(obj)) {
    long v = PyInt_AsLong(obj);
    if (v >= 0) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      return SWIG_OverflowError;
    }
  } else
#endif
  if (PyLong_Check(obj)) {
    unsigned long v = PyLong_AsUnsignedLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      PyErr_Clear();
      return SWIG_OverflowError;
    }
  }
#ifdef SWIG_PYTHON_CAST_MODE
  {
    int dispatch = 0;
    unsigned long v = PyLong_AsUnsignedLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_AddCast(SWIG_OK);
    } else {
      PyErr_Clear();
    }
    if (!dispatch) {
      double d;
      int res = SWIG_AddCast(SWIG_AsVal_double (obj,&d));
      if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, 0, ULONG_MAX)) {
	if (val) *val = (unsigned long)(d);
	return res;
      }
    }
  }
#endif
  return SWIG_TypeError;
}


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


SWIGINTERNINLINE PyObject*
  SWIG_From_unsigned_SS_int  (unsigned int value)
{
  return PyInt_FromSize_t((size_t) value);
}


  #define SWIG_From_double   PyFloat_FromDouble 

#ifdef __cplusplus
extern "C" {
#endif
SWIGINTERN PyObject *_wrap_gncSplitGetGUID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncGUID *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncSplitGetGUID" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (GncGUID *)gncSplitGetGUID(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTransGetGUID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncGUID *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTransGetGUID" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (GncGUID *)gncTransGetGUID(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAccountGetGUID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncGUID *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAccountGetGUID" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (GncGUID *)gncAccountGetGUID(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_split_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_split_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_split_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitConvertAmount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitConvertAmount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitConvertAmount" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitConvertAmount" "', argument " "2"" of type '" "Account const *""'"); 
  }
  arg2 = (Account *)(argp2);
  result = xaccSplitConvertAmount((Split const *)arg1,(Account const *)arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccMallocSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Split *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccMallocSplit" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (Split *)xaccMallocSplit(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitReinit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitReinit" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  xaccSplitReinit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitDestroy" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitDestroy(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitCopyOnto(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitCopyOnto", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitCopyOnto" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitCopyOnto" "', argument " "2"" of type '" "Split *""'"); 
  }
  arg2 = (Split *)(argp2);
  xaccSplitCopyOnto((Split const *)arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetBook(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBook *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetBook" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (QofBook *)xaccSplitGetBook((Split const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofBook, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetAccount" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (Account *)xaccSplitGetAccount((Split const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetAccount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetAccount" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitSetAccount" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  xaccSplitSetAccount(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetParent(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Transaction *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetParent" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (Transaction *)xaccSplitGetParent((Split const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Transaction, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetParent(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Transaction *arg2 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetParent", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetParent" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitSetParent" "', argument " "2"" of type '" "Transaction *""'"); 
  }
  arg2 = (Transaction *)(argp2);
  xaccSplitSetParent(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCLot *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetLot" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (GNCLot *)xaccSplitGetLot((Split const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCLot, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  GNCLot *arg2 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetLot", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetLot" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitSetLot" "', argument " "2"" of type '" "GNCLot *""'"); 
  }
  arg2 = (GNCLot *)(argp2);
  xaccSplitSetLot(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetMemo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetMemo", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetMemo" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitSetMemo" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccSplitSetMemo(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetMemo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetMemo" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (char *)xaccSplitGetMemo((Split const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetAction(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetAction", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetAction" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitSetAction" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccSplitSetAction(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetAction(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetAction" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (char *)xaccSplitGetAction((Split const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetReconcile(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  char arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetReconcile", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetReconcile" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  ecode2 = SWIG_AsVal_char(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccSplitSetReconcile" "', argument " "2"" of type '" "char""'");
  } 
  arg2 = (char)(val2);
  xaccSplitSetReconcile(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetReconcile(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetReconcile" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (char)xaccSplitGetReconcile((Split const *)arg1);
  resultobj = SWIG_From_char((char)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetDateReconciledSecs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetDateReconciledSecs", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetDateReconciledSecs" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  xaccSplitSetDateReconciledSecs(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetDateReconciled(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetDateReconciled" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitGetDateReconciled((Split const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetAmount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetAmount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetAmount" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitSetAmount" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccSplitSetAmount" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  xaccSplitSetAmount(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetAmount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetAmount" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitGetAmount((Split const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetValue", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetValue" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitSetValue" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccSplitSetValue" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  xaccSplitSetValue(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetValue" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitGetValue((Split const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetSharePriceAndAmount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  gnc_numeric arg2 ;
  gnc_numeric arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetSharePriceAndAmount", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetSharePriceAndAmount" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitSetSharePriceAndAmount" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccSplitSetSharePriceAndAmount" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccSplitSetSharePriceAndAmount" "', argument " "3"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccSplitSetSharePriceAndAmount" "', argument " "3"" of type '" "gnc_numeric""'");
    } else {
      arg3 = *((gnc_numeric *)(argp3));
    }
  }
  xaccSplitSetSharePriceAndAmount(arg1,arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetSharePrice(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetSharePrice" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitGetSharePrice((Split const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetBaseValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  gnc_numeric arg2 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetBaseValue", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetBaseValue" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitSetBaseValue" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccSplitSetBaseValue" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccSplitSetBaseValue" "', argument " "3"" of type '" "gnc_commodity const *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  xaccSplitSetBaseValue(arg1,arg2,(gnc_commodity const *)arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetBaseValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitGetBaseValue", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetBaseValue" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitGetBaseValue" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  result = xaccSplitGetBaseValue((Split const *)arg1,(gnc_commodity const *)arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetBalance" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitGetBalance((Split const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetNoclosingBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetNoclosingBalance" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitGetNoclosingBalance((Split const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetClearedBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetClearedBalance" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitGetClearedBalance((Split const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetReconciledBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetReconciledBalance" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitGetReconciledBalance((Split const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  gboolean arg3 ;
  gboolean arg4 ;
  gboolean arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[5] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitEqual", 5, 5, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitEqual" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitEqual" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[4] == Py_True)
    arg5 = TRUE;
    else if (swig_obj[4] == Py_False)
    arg5 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccSplitEqual((Split const *)arg1,(Split const *)arg2,arg3,arg4,arg5);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitLookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Split *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitLookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitLookup" "', argument " "1"" of type '" "GncGUID const *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitLookup" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  result = (Split *)xaccSplitLookup((struct _gncGuid const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitListGetUniqueTransactions(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GList *arg1 = (GList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitListGetUniqueTransactions" "', argument " "1"" of type '" "GList const *""'"); 
  }
  arg1 = (GList *)(argp1);
  result = (GList *)xaccSplitListGetUniqueTransactions((GList const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitAddPeerSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  time64 arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitAddPeerSplit", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitAddPeerSplit" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitAddPeerSplit" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[2]) && !PyInt_Check(swig_obj[2])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[2])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[2]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[2]),
        PyDateTime_DATE_GET_HOUR(swig_obj[2]),
        PyDateTime_GET_DAY(swig_obj[2]),
        PyDateTime_GET_MONTH(swig_obj[2]) - 1,
        PyDateTime_GET_YEAR(swig_obj[2]) - 1900
      };
      arg3 = gnc_mktime(&time);
    } else {
      arg3 = PyInt_AsLong(swig_obj[2]);
    }
  }
  xaccSplitAddPeerSplit(arg1,(Split const *)arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitHasPeers(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitHasPeers" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitHasPeers((Split const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitIsPeerSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitIsPeerSplit", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitIsPeerSplit" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitIsPeerSplit" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  result = xaccSplitIsPeerSplit((Split const *)arg1,(Split const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitRemovePeerSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitRemovePeerSplit", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitRemovePeerSplit" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitRemovePeerSplit" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  xaccSplitRemovePeerSplit(arg1,(Split const *)arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitMergePeerSplits(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitMergePeerSplits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitMergePeerSplits" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitMergePeerSplits" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  xaccSplitMergePeerSplits(arg1,(Split const *)arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetOtherSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Split *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetOtherSplit" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (Split *)xaccSplitGetOtherSplit((Split const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetType" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (char *)xaccSplitGetType((Split const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitMakeStockSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitMakeStockSplit" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  xaccSplitMakeStockSplit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitOrder(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gint result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitOrder", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitOrder" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitOrder" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  result = xaccSplitOrder((Split const *)arg1,(Split const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitOrderDateOnly(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gint result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitOrderDateOnly", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitOrderDateOnly" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitOrderDateOnly" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  result = xaccSplitOrderDateOnly((Split const *)arg1,(Split const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitCompareAccountFullNames(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitCompareAccountFullNames", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitCompareAccountFullNames" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitCompareAccountFullNames" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  result = (int)xaccSplitCompareAccountFullNames((Split const *)arg1,(Split const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitCompareAccountCodes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitCompareAccountCodes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitCompareAccountCodes" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitCompareAccountCodes" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  result = (int)xaccSplitCompareAccountCodes((Split const *)arg1,(Split const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitCompareOtherAccountFullNames(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitCompareOtherAccountFullNames", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitCompareOtherAccountFullNames" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitCompareOtherAccountFullNames" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  result = (int)xaccSplitCompareOtherAccountFullNames((Split const *)arg1,(Split const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitCompareOtherAccountCodes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitCompareOtherAccountCodes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitCompareOtherAccountCodes" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitCompareOtherAccountCodes" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  result = (int)xaccSplitCompareOtherAccountCodes((Split const *)arg1,(Split const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetCorrAccountFullName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetCorrAccountFullName" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (char *)xaccSplitGetCorrAccountFullName((Split const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetCorrAccountName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetCorrAccountName" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (char *)xaccSplitGetCorrAccountName((Split const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetCorrAccountCode(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetCorrAccountCode" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (char *)xaccSplitGetCorrAccountCode((Split const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitSetSharePrice(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitSetSharePrice", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitSetSharePrice" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitSetSharePrice" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccSplitSetSharePrice" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  xaccSplitSetSharePrice(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitVoidFormerAmount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitVoidFormerAmount" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitVoidFormerAmount((Split const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitVoidFormerValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitVoidFormerValue" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitVoidFormerValue((Split const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_children(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  AccountList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_children" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (AccountList *)gnc_account_get_children((Account const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_AccountList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_children_sorted(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  AccountList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_children_sorted" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (AccountList *)gnc_account_get_children_sorted((Account const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_AccountList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_descendants(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  AccountList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_descendants" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (AccountList *)gnc_account_get_descendants((Account const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_AccountList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_descendants_sorted(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  AccountList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_descendants_sorted" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (AccountList *)gnc_account_get_descendants_sorted((Account const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_AccountList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_AccountClass_parent_class_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  AccountClass *arg1 = (AccountClass *) 0 ;
  QofInstanceClass arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "AccountClass_parent_class_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_AccountClass, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "AccountClass_parent_class_set" "', argument " "1"" of type '" "AccountClass *""'"); 
  }
  arg1 = (AccountClass *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_QofInstanceClass,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "AccountClass_parent_class_set" "', argument " "2"" of type '" "QofInstanceClass""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "AccountClass_parent_class_set" "', argument " "2"" of type '" "QofInstanceClass""'");
    } else {
      arg2 = *((QofInstanceClass *)(argp2));
    }
  }
  if (arg1) (arg1)->parent_class = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_AccountClass_parent_class_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  AccountClass *arg1 = (AccountClass *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofInstanceClass result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_AccountClass, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "AccountClass_parent_class_get" "', argument " "1"" of type '" "AccountClass *""'"); 
  }
  arg1 = (AccountClass *)(argp1);
  result =  ((arg1)->parent_class);
  resultobj = SWIG_NewPointerObj((QofInstanceClass *)memcpy((QofInstanceClass *)calloc(1,sizeof(QofInstanceClass)),&result,sizeof(QofInstanceClass)), SWIGTYPE_p_QofInstanceClass, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_AccountClass(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  AccountClass *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "new_AccountClass", 0, 0, 0)) SWIG_fail;
  result = (AccountClass *)calloc(1, sizeof(AccountClass));
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_AccountClass, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_AccountClass(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  AccountClass *arg1 = (AccountClass *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_AccountClass, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_AccountClass" "', argument " "1"" of type '" "AccountClass *""'"); 
  }
  arg1 = (AccountClass *)(argp1);
  free((char *) arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *AccountClass_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_AccountClass, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *AccountClass_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_GncImportMatchMap_acc_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncImportMatchMap *arg1 = (GncImportMatchMap *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "GncImportMatchMap_acc_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncImportMatchMap, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImportMatchMap_acc_set" "', argument " "1"" of type '" "GncImportMatchMap *""'"); 
  }
  arg1 = (GncImportMatchMap *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "GncImportMatchMap_acc_set" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  if (arg1) (arg1)->acc = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImportMatchMap_acc_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncImportMatchMap *arg1 = (GncImportMatchMap *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncImportMatchMap, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImportMatchMap_acc_get" "', argument " "1"" of type '" "GncImportMatchMap *""'"); 
  }
  arg1 = (GncImportMatchMap *)(argp1);
  result = (Account *) ((arg1)->acc);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImportMatchMap_book_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncImportMatchMap *arg1 = (GncImportMatchMap *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "GncImportMatchMap_book_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncImportMatchMap, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImportMatchMap_book_set" "', argument " "1"" of type '" "GncImportMatchMap *""'"); 
  }
  arg1 = (GncImportMatchMap *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "GncImportMatchMap_book_set" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  if (arg1) (arg1)->book = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImportMatchMap_book_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncImportMatchMap *arg1 = (GncImportMatchMap *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBook *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncImportMatchMap, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImportMatchMap_book_get" "', argument " "1"" of type '" "GncImportMatchMap *""'"); 
  }
  arg1 = (GncImportMatchMap *)(argp1);
  result = (QofBook *) ((arg1)->book);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofBook, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_GncImportMatchMap(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncImportMatchMap *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "new_GncImportMatchMap", 0, 0, 0)) SWIG_fail;
  result = (GncImportMatchMap *)calloc(1, sizeof(GncImportMatchMap));
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GncImportMatchMap, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_GncImportMatchMap(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncImportMatchMap *arg1 = (GncImportMatchMap *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncImportMatchMap, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_GncImportMatchMap" "', argument " "1"" of type '" "GncImportMatchMap *""'"); 
  }
  arg1 = (GncImportMatchMap *)(argp1);
  free((char *) arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *GncImportMatchMap_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_GncImportMatchMap, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *GncImportMatchMap_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_gnc_account_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_account_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccMallocAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccMallocAccount" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (Account *)xaccMallocAccount(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_create_root(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_create_root" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (Account *)gnc_account_create_root(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccCloneAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Account *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccCloneAccount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccCloneAccount" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccCloneAccount" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  result = (Account *)xaccCloneAccount((Account const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountBeginEdit" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  xaccAccountBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountCommitEdit" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  xaccAccountCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountDestroy" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  xaccAccountDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  Account *arg2 = (Account *) 0 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountEqual", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountEqual" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountEqual" "', argument " "2"" of type '" "Account const *""'"); 
  }
  arg2 = (Account *)(argp2);
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountEqual((Account const *)arg1,(Account const *)arg2,arg3);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountOrder(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountOrder", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountOrder" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountOrder" "', argument " "2"" of type '" "Account const *""'"); 
  }
  arg2 = (Account *)(argp2);
  result = (int)xaccAccountOrder((Account const *)arg1,(Account const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_get_account_separator_string(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gchar *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_get_account_separator_string", 0, 0, 0)) SWIG_fail;
  result = (gchar *)gnc_get_account_separator_string();
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_get_account_separator(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gunichar result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_get_account_separator", 0, 0, 0)) SWIG_fail;
  result = gnc_get_account_separator();
  resultobj = SWIG_NewPointerObj((gunichar *)memcpy((gunichar *)calloc(1,sizeof(gunichar)),&result,sizeof(gunichar)), SWIGTYPE_p_gunichar, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_set_account_separator(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gchar *arg1 = (gchar *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_set_account_separator" "', argument " "1"" of type '" "gchar const *""'");
  }
  arg1 = (gchar *)(buf1);
  gnc_set_account_separator((gchar const *)arg1);
  resultobj = SWIG_Py_Void();
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_book_get_root_account(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_book_get_root_account" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (Account *)gnc_book_get_root_account(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_book_set_root_account(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_book_set_root_account", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_book_set_root_account" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_book_set_root_account" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  gnc_book_set_root_account(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountLookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Account *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountLookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountLookup" "', argument " "1"" of type '" "GncGUID const *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountLookup" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  result = (Account *)xaccAccountLookup((struct _gncGuid const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_name_violations_errmsg(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gchar *arg1 = (gchar *) 0 ;
  GList *arg2 = (GList *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gchar *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_name_violations_errmsg", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_name_violations_errmsg" "', argument " "1"" of type '" "gchar const *""'");
  }
  arg1 = (gchar *)(buf1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_name_violations_errmsg" "', argument " "2"" of type '" "GList *""'"); 
  }
  arg2 = (GList *)(argp2);
  result = (gchar *)gnc_account_name_violations_errmsg((gchar const *)arg1,arg2);
  resultobj = SWIG_FromCharPtr((const char *)result);
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_list_name_violations(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  gchar *arg2 = (gchar *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  GList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_list_name_violations", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_list_name_violations" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_list_name_violations" "', argument " "2"" of type '" "gchar const *""'");
  }
  arg2 = (gchar *)(buf2);
  result = (GList *)gnc_account_list_name_violations(arg1,(gchar const *)arg2);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_book(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBook *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_book" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (QofBook *)gnc_account_get_book((Account const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofBook, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  GNCAccountType arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetType" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccAccountSetType" "', argument " "2"" of type '" "GNCAccountType""'");
  } 
  arg2 = (GNCAccountType)(val2);
  xaccAccountSetType(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetName" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetName" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccAccountSetName(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetCode(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetCode", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetCode" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetCode" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccAccountSetCode(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetDescription(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetDescription", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetDescription" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetDescription" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccAccountSetDescription(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetColor(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetColor", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetColor" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetColor" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccAccountSetColor(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetFilter(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetFilter", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetFilter" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetFilter" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccAccountSetFilter(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetSortOrder(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetSortOrder", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetSortOrder" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetSortOrder" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccAccountSetSortOrder(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetSortReversed(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetSortReversed", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetSortReversed" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  xaccAccountSetSortReversed(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetNotes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetNotes" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetNotes" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccAccountSetNotes(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetLastNum(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetLastNum", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetLastNum" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetLastNum" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccAccountSetLastNum(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_set_policy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  GNCPolicy *arg2 = (GNCPolicy *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_set_policy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_set_policy" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCPolicy, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_set_policy" "', argument " "2"" of type '" "GNCPolicy *""'"); 
  }
  arg2 = (GNCPolicy *)(argp2);
  gnc_account_set_policy(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCAccountType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetType" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (GNCAccountType)xaccAccountGetType((Account const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountIsPriced(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountIsPriced" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountIsPriced((Account const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_set_start_balance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_set_start_balance", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_set_start_balance" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_set_start_balance" "', argument " "2"" of type '" "gnc_numeric const""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_account_set_start_balance" "', argument " "2"" of type '" "gnc_numeric const""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gnc_account_set_start_balance(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_set_start_cleared_balance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_set_start_cleared_balance", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_set_start_cleared_balance" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_set_start_cleared_balance" "', argument " "2"" of type '" "gnc_numeric const""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_account_set_start_cleared_balance" "', argument " "2"" of type '" "gnc_numeric const""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gnc_account_set_start_cleared_balance(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_set_start_reconciled_balance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_set_start_reconciled_balance", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_set_start_reconciled_balance" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_set_start_reconciled_balance" "', argument " "2"" of type '" "gnc_numeric const""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_account_set_start_reconciled_balance" "', argument " "2"" of type '" "gnc_numeric const""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gnc_account_set_start_reconciled_balance(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_set_balance_dirty(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_set_balance_dirty" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  gnc_account_set_balance_dirty(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_set_sort_dirty(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_set_sort_dirty" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  gnc_account_set_sort_dirty(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_insert_split(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_insert_split", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_insert_split" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_insert_split" "', argument " "2"" of type '" "Split *""'"); 
  }
  arg2 = (Split *)(argp2);
  result = gnc_account_insert_split(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_remove_split(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_remove_split", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_remove_split" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_remove_split" "', argument " "2"" of type '" "Split *""'"); 
  }
  arg2 = (Split *)(argp2);
  result = gnc_account_remove_split(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetName" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)xaccAccountGetName((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetCode(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetCode" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)xaccAccountGetCode((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetDescription(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetDescription" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)xaccAccountGetDescription((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetColor(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetColor" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)xaccAccountGetColor((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetFilter(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetFilter" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)xaccAccountGetFilter((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetSortOrder(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetSortOrder" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)xaccAccountGetSortOrder((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetSortReversed(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetSortReversed" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetSortReversed((Account const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetNotes" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)xaccAccountGetNotes((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetLastNum(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetLastNum" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)xaccAccountGetLastNum((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_policy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCPolicy *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_policy" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (GNCPolicy *)gnc_account_get_policy(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPolicy, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountRecomputeBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountRecomputeBalance" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  xaccAccountRecomputeBalance(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSortSplits(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSortSplits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSortSplits" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  xaccAccountSortSplits(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_full_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gchar *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_full_name" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (gchar *)gnc_account_get_full_name((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGainsAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Account *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGainsAccount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGainsAccount" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountGainsAccount" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  result = (Account *)xaccAccountGainsAccount(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_dxaccAccountSetPriceSrc(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "dxaccAccountSetPriceSrc", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "dxaccAccountSetPriceSrc" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "dxaccAccountSetPriceSrc" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  dxaccAccountSetPriceSrc(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_dxaccAccountGetPriceSrc(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "dxaccAccountGetPriceSrc" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)dxaccAccountGetPriceSrc((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetAutoInterestXfer(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetAutoInterestXfer", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetAutoInterestXfer" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountGetAutoInterestXfer((Account const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetAutoInterestXfer(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetAutoInterestXfer", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetAutoInterestXfer" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  xaccAccountSetAutoInterestXfer(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetCommodity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetCommodity", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetCommodity" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetCommodity" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  xaccAccountSetCommodity(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetCommodity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetCommodity" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (gnc_commodity *)xaccAccountGetCommodity((Account const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_currency_or_parent(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_currency_or_parent" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (gnc_commodity *)gnc_account_get_currency_or_parent((Account const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetCommoditySCU(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  int result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetCommoditySCU" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (int)xaccAccountGetCommoditySCU((Account const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetCommoditySCUi(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  int result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetCommoditySCUi" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (int)xaccAccountGetCommoditySCUi((Account const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetCommoditySCU(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetCommoditySCU", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetCommoditySCU" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccAccountSetCommoditySCU" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  xaccAccountSetCommoditySCU(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetNonStdSCU(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetNonStdSCU", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetNonStdSCU" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  xaccAccountSetNonStdSCU(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetNonStdSCU(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetNonStdSCU" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetNonStdSCU((Account const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetBalance" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetBalance((Account const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetClearedBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetClearedBalance" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetClearedBalance((Account const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetReconciledBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetReconciledBalance" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetReconciledBalance((Account const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetPresentBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetPresentBalance" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetPresentBalance((Account const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetProjectedMinimumBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetProjectedMinimumBalance" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetProjectedMinimumBalance((Account const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetBalanceAsOfDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetBalanceAsOfDate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetBalanceAsOfDate" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  result = xaccAccountGetBalanceAsOfDate(arg1,arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetReconciledBalanceAsOfDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetReconciledBalanceAsOfDate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetReconciledBalanceAsOfDate" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  result = xaccAccountGetReconciledBalanceAsOfDate(arg1,arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountConvertBalanceToCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_numeric arg2 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  gnc_commodity *arg4 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountConvertBalanceToCurrency", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountConvertBalanceToCurrency" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountConvertBalanceToCurrency" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccAccountConvertBalanceToCurrency" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountConvertBalanceToCurrency" "', argument " "3"" of type '" "gnc_commodity const *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "xaccAccountConvertBalanceToCurrency" "', argument " "4"" of type '" "gnc_commodity const *""'"); 
  }
  arg4 = (gnc_commodity *)(argp4);
  result = xaccAccountConvertBalanceToCurrency((Account const *)arg1,arg2,(gnc_commodity const *)arg3,(gnc_commodity const *)arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountConvertBalanceToCurrencyAsOfDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_numeric arg2 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  gnc_commodity *arg4 = (gnc_commodity *) 0 ;
  time64 arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  PyObject *swig_obj[5] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountConvertBalanceToCurrencyAsOfDate", 5, 5, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountConvertBalanceToCurrencyAsOfDate" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountConvertBalanceToCurrencyAsOfDate" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccAccountConvertBalanceToCurrencyAsOfDate" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountConvertBalanceToCurrencyAsOfDate" "', argument " "3"" of type '" "gnc_commodity *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "xaccAccountConvertBalanceToCurrencyAsOfDate" "', argument " "4"" of type '" "gnc_commodity *""'"); 
  }
  arg4 = (gnc_commodity *)(argp4);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[4]) && !PyInt_Check(swig_obj[4])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[4])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[4]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[4]),
        PyDateTime_DATE_GET_HOUR(swig_obj[4]),
        PyDateTime_GET_DAY(swig_obj[4]),
        PyDateTime_GET_MONTH(swig_obj[4]) - 1,
        PyDateTime_GET_YEAR(swig_obj[4]) - 1900
      };
      arg5 = gnc_mktime(&time);
    } else {
      arg5 = PyInt_AsLong(swig_obj[4]);
    }
  }
  result = xaccAccountConvertBalanceToCurrencyAsOfDate((Account const *)arg1,arg2,arg3,arg4,arg5);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetBalanceInCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetBalanceInCurrency", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetBalanceInCurrency" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountGetBalanceInCurrency" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountGetBalanceInCurrency((Account const *)arg1,(gnc_commodity const *)arg2,arg3);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetClearedBalanceInCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetClearedBalanceInCurrency", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetClearedBalanceInCurrency" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountGetClearedBalanceInCurrency" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountGetClearedBalanceInCurrency((Account const *)arg1,(gnc_commodity const *)arg2,arg3);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetReconciledBalanceInCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetReconciledBalanceInCurrency", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetReconciledBalanceInCurrency" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountGetReconciledBalanceInCurrency" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountGetReconciledBalanceInCurrency((Account const *)arg1,(gnc_commodity const *)arg2,arg3);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetPresentBalanceInCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetPresentBalanceInCurrency", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetPresentBalanceInCurrency" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountGetPresentBalanceInCurrency" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountGetPresentBalanceInCurrency((Account const *)arg1,(gnc_commodity const *)arg2,arg3);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetProjectedMinimumBalanceInCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetProjectedMinimumBalanceInCurrency", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetProjectedMinimumBalanceInCurrency" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountGetProjectedMinimumBalanceInCurrency" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountGetProjectedMinimumBalanceInCurrency((Account const *)arg1,(gnc_commodity const *)arg2,arg3);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetNoclosingBalanceAsOfDateInCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  time64 arg2 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  gboolean arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetNoclosingBalanceAsOfDateInCurrency", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetNoclosingBalanceAsOfDateInCurrency" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountGetNoclosingBalanceAsOfDateInCurrency" "', argument " "3"" of type '" "gnc_commodity *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountGetNoclosingBalanceAsOfDateInCurrency(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetBalanceAsOfDateInCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  time64 arg2 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  gboolean arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetBalanceAsOfDateInCurrency", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetBalanceAsOfDateInCurrency" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountGetBalanceAsOfDateInCurrency" "', argument " "3"" of type '" "gnc_commodity *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountGetBalanceAsOfDateInCurrency(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetNoclosingBalanceChangeForPeriod(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  time64 arg2 ;
  time64 arg3 ;
  gboolean arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetNoclosingBalanceChangeForPeriod", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetNoclosingBalanceChangeForPeriod" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[2]) && !PyInt_Check(swig_obj[2])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[2])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[2]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[2]),
        PyDateTime_DATE_GET_HOUR(swig_obj[2]),
        PyDateTime_GET_DAY(swig_obj[2]),
        PyDateTime_GET_MONTH(swig_obj[2]) - 1,
        PyDateTime_GET_YEAR(swig_obj[2]) - 1900
      };
      arg3 = gnc_mktime(&time);
    } else {
      arg3 = PyInt_AsLong(swig_obj[2]);
    }
  }
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountGetNoclosingBalanceChangeForPeriod(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetBalanceChangeForPeriod(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  time64 arg2 ;
  time64 arg3 ;
  gboolean arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetBalanceChangeForPeriod", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetBalanceChangeForPeriod" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[2]) && !PyInt_Check(swig_obj[2])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[2])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[2]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[2]),
        PyDateTime_DATE_GET_HOUR(swig_obj[2]),
        PyDateTime_GET_DAY(swig_obj[2]),
        PyDateTime_GET_MONTH(swig_obj[2]) - 1,
        PyDateTime_GET_YEAR(swig_obj[2]) - 1900
      };
      arg3 = gnc_mktime(&time);
    } else {
      arg3 = PyInt_AsLong(swig_obj[2]);
    }
  }
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountGetBalanceChangeForPeriod(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_append_child(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_append_child", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_append_child" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_append_child" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  gnc_account_append_child(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_remove_child(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_remove_child", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_remove_child" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_remove_child" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  gnc_account_remove_child(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_parent(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_parent" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (Account *)gnc_account_get_parent((Account const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_root(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_root" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (Account *)gnc_account_get_root(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_is_root(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_is_root" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = gnc_account_is_root((Account const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_n_children(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_n_children" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = gnc_account_n_children((Account const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_child_index(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gint result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_child_index", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_child_index" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_child_index" "', argument " "2"" of type '" "Account const *""'"); 
  }
  arg2 = (Account *)(argp2);
  result = gnc_account_child_index((Account const *)arg1,(Account const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_nth_child(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gint arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Account *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_nth_child", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_nth_child" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gnc_account_nth_child" "', argument " "2"" of type '" "gint""'");
  } 
  arg2 = (gint)(val2);
  result = (Account *)gnc_account_nth_child((Account const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_n_descendants(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_n_descendants" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = gnc_account_n_descendants((Account const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_current_depth(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_current_depth" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = gnc_account_get_current_depth((Account const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_tree_depth(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_tree_depth" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = gnc_account_get_tree_depth((Account const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_foreach_child(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  AccountCb arg2 = (AccountCb) 0 ;
  gpointer arg3 = (gpointer) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_foreach_child", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_foreach_child" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[1], (void**)(&arg2), SWIGTYPE_p_f_p_Account_p_void__void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gnc_account_foreach_child" "', argument " "2"" of type '" "AccountCb""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2],SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_account_foreach_child" "', argument " "3"" of type '" "gpointer""'"); 
  }
  gnc_account_foreach_child((Account const *)arg1,arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_foreach_descendant(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  AccountCb arg2 = (AccountCb) 0 ;
  gpointer arg3 = (gpointer) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_foreach_descendant", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_foreach_descendant" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[1], (void**)(&arg2), SWIGTYPE_p_f_p_Account_p_void__void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gnc_account_foreach_descendant" "', argument " "2"" of type '" "AccountCb""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2],SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_account_foreach_descendant" "', argument " "3"" of type '" "gpointer""'"); 
  }
  gnc_account_foreach_descendant((Account const *)arg1,arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_foreach_descendant_until(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  AccountCb2 arg2 = (AccountCb2) 0 ;
  gpointer arg3 = (gpointer) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  PyObject *swig_obj[3] ;
  gpointer result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_foreach_descendant_until", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_foreach_descendant_until" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[1], (void**)(&arg2), SWIGTYPE_p_f_p_Account_p_void__p_void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gnc_account_foreach_descendant_until" "', argument " "2"" of type '" "AccountCb2""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2],SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_account_foreach_descendant_until" "', argument " "3"" of type '" "gpointer""'"); 
  }
  result = (gpointer)gnc_account_foreach_descendant_until((Account const *)arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_void, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_join_children(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_join_children", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_join_children" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_join_children" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  gnc_account_join_children(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_merge_children(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_merge_children" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  gnc_account_merge_children(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetReconcileChildrenStatus(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetReconcileChildrenStatus", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetReconcileChildrenStatus" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  xaccAccountSetReconcileChildrenStatus(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetReconcileChildrenStatus(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetReconcileChildrenStatus" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetReconcileChildrenStatus((Account const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountHasAncestor(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountHasAncestor", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountHasAncestor" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountHasAncestor" "', argument " "2"" of type '" "Account const *""'"); 
  }
  arg2 = (Account *)(argp2);
  result = xaccAccountHasAncestor((Account const *)arg1,(Account const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_lookup_by_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  Account *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_lookup_by_name", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_lookup_by_name" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_lookup_by_name" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (Account *)gnc_account_lookup_by_name((Account const *)arg1,(char const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_lookup_by_full_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gchar *arg2 = (gchar *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  Account *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_lookup_by_full_name", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_lookup_by_full_name" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_lookup_by_full_name" "', argument " "2"" of type '" "gchar const *""'");
  }
  arg2 = (gchar *)(buf2);
  result = (Account *)gnc_account_lookup_by_full_name((Account const *)arg1,(gchar const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_lookup_by_code(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  Account *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_lookup_by_code", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_lookup_by_code" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_lookup_by_code" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (Account *)gnc_account_lookup_by_code((Account const *)arg1,(char const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountTypeEnumAsString(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCAccountType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "xaccAccountTypeEnumAsString" "', argument " "1"" of type '" "GNCAccountType""'");
  } 
  arg1 = (GNCAccountType)(val1);
  result = (char *)xaccAccountTypeEnumAsString(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountStringToType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  GNCAccountType *arg2 = (GNCAccountType *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountStringToType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountStringToType" "', argument " "1"" of type '" "char const *""'");
  }
  arg1 = (char *)(buf1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCAccountType, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountStringToType" "', argument " "2"" of type '" "GNCAccountType *""'"); 
  }
  arg2 = (GNCAccountType *)(argp2);
  result = xaccAccountStringToType((char const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountStringToEnum(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCAccountType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountStringToEnum" "', argument " "1"" of type '" "char const *""'");
  }
  arg1 = (char *)(buf1);
  result = (GNCAccountType)xaccAccountStringToEnum((char const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetTypeStr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCAccountType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "xaccAccountGetTypeStr" "', argument " "1"" of type '" "GNCAccountType""'");
  } 
  arg1 = (GNCAccountType)(val1);
  result = (char *)xaccAccountGetTypeStr(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountTypesCompatibleWith(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCAccountType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  guint32 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "xaccAccountTypesCompatibleWith" "', argument " "1"" of type '" "GNCAccountType""'");
  } 
  arg1 = (GNCAccountType)(val1);
  result = xaccAccountTypesCompatibleWith(arg1);
  resultobj = SWIG_NewPointerObj((guint32 *)memcpy((guint32 *)calloc(1,sizeof(guint32)),&result,sizeof(guint32)), SWIGTYPE_p_guint32, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccParentAccountTypesCompatibleWith(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCAccountType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  guint32 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "xaccParentAccountTypesCompatibleWith" "', argument " "1"" of type '" "GNCAccountType""'");
  } 
  arg1 = (GNCAccountType)(val1);
  result = xaccParentAccountTypesCompatibleWith(arg1);
  resultobj = SWIG_NewPointerObj((guint32 *)memcpy((guint32 *)calloc(1,sizeof(guint32)),&result,sizeof(guint32)), SWIGTYPE_p_guint32, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountTypesCompatible(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCAccountType arg1 ;
  GNCAccountType arg2 ;
  int val1 ;
  int ecode1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountTypesCompatible", 2, 2, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "xaccAccountTypesCompatible" "', argument " "1"" of type '" "GNCAccountType""'");
  } 
  arg1 = (GNCAccountType)(val1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccAccountTypesCompatible" "', argument " "2"" of type '" "GNCAccountType""'");
  } 
  arg2 = (GNCAccountType)(val2);
  result = xaccAccountTypesCompatible(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountTypesValid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  guint32 result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountTypesValid", 0, 0, 0)) SWIG_fail;
  result = xaccAccountTypesValid();
  resultobj = SWIG_NewPointerObj((guint32 *)memcpy((guint32 *)calloc(1,sizeof(guint32)),&result,sizeof(guint32)), SWIGTYPE_p_guint32, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountIsAssetLiabType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCAccountType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "xaccAccountIsAssetLiabType" "', argument " "1"" of type '" "GNCAccountType""'");
  } 
  arg1 = (GNCAccountType)(val1);
  result = xaccAccountIsAssetLiabType(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountIsAPARType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCAccountType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "xaccAccountIsAPARType" "', argument " "1"" of type '" "GNCAccountType""'");
  } 
  arg1 = (GNCAccountType)(val1);
  result = xaccAccountIsAPARType(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountIsEquityType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCAccountType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "xaccAccountIsEquityType" "', argument " "1"" of type '" "GNCAccountType""'");
  } 
  arg1 = (GNCAccountType)(val1);
  result = xaccAccountIsEquityType(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetSplitList(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  SplitList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetSplitList" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (SplitList *)xaccAccountGetSplitList((Account const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_SplitList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountCountSplits(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  gint64 result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountCountSplits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountCountSplits" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccAccountCountSplits((Account const *)arg1,arg2);
  resultobj = SWIG_From_long_SS_long((long long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountMoveAllSplits(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountMoveAllSplits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountMoveAllSplits" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountMoveAllSplits" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  xaccAccountMoveAllSplits(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountForEachTransaction(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  TransactionCallback arg2 ;
  void *arg3 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  int res3 ;
  PyObject *swig_obj[3] ;
  gint result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountForEachTransaction", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountForEachTransaction" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_TransactionCallback,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountForEachTransaction" "', argument " "2"" of type '" "TransactionCallback""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccAccountForEachTransaction" "', argument " "2"" of type '" "TransactionCallback""'");
    } else {
      arg2 = *((TransactionCallback *)(argp2));
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2],SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountForEachTransaction" "', argument " "3"" of type '" "void *""'"); 
  }
  result = xaccAccountForEachTransaction((Account const *)arg1,arg2,arg3);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountFindTransByDesc(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  Transaction *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountFindTransByDesc", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountFindTransByDesc" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountFindTransByDesc" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (Transaction *)xaccAccountFindTransByDesc((Account const *)arg1,(char const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Transaction, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountFindSplitByDesc(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  Split *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountFindSplitByDesc", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountFindSplitByDesc" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountFindSplitByDesc" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (Split *)xaccAccountFindSplitByDesc((Account const *)arg1,(char const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountInsertLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  GNCLot *arg2 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountInsertLot", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountInsertLot" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountInsertLot" "', argument " "2"" of type '" "GNCLot *""'"); 
  }
  arg2 = (GNCLot *)(argp2);
  xaccAccountInsertLot(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountRemoveLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  GNCLot *arg2 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountRemoveLot", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountRemoveLot" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountRemoveLot" "', argument " "2"" of type '" "GNCLot *""'"); 
  }
  arg2 = (GNCLot *)(argp2);
  xaccAccountRemoveLot(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetLotList(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  LotList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetLotList" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (LotList *)xaccAccountGetLotList((Account const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_LotList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountForEachLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gpointer (*arg2)(GNCLot *,gpointer) = (gpointer (*)(GNCLot *,gpointer)) 0 ;
  gpointer arg3 = (gpointer) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  PyObject *swig_obj[3] ;
  gpointer result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountForEachLot", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountForEachLot" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[1], (void**)(&arg2), SWIGTYPE_p_f_p_GNCLot_p_void__p_void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "xaccAccountForEachLot" "', argument " "2"" of type '" "gpointer (*)(GNCLot *,gpointer)""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2],SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountForEachLot" "', argument " "3"" of type '" "gpointer""'"); 
  }
  result = (gpointer)xaccAccountForEachLot((Account const *)arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_void, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountFindOpenLots(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gboolean (*arg2)(GNCLot *,gpointer) = (gboolean (*)(GNCLot *,gpointer)) 0 ;
  gpointer arg3 = (gpointer) 0 ;
  GCompareFunc arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  void *argp4 ;
  int res4 = 0 ;
  PyObject *swig_obj[4] ;
  LotList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountFindOpenLots", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountFindOpenLots" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[1], (void**)(&arg2), SWIGTYPE_p_f_p_GNCLot_p_void__gboolean);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "xaccAccountFindOpenLots" "', argument " "2"" of type '" "gboolean (*)(GNCLot *,gpointer)""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2],SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountFindOpenLots" "', argument " "3"" of type '" "gpointer""'"); 
  }
  {
    res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_GCompareFunc,  0 );
    if (!SWIG_IsOK(res4)) {
      SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "xaccAccountFindOpenLots" "', argument " "4"" of type '" "GCompareFunc""'"); 
    }  
    if (!argp4) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccAccountFindOpenLots" "', argument " "4"" of type '" "GCompareFunc""'");
    } else {
      arg4 = *((GCompareFunc *)(argp4));
    }
  }
  result = (LotList *)xaccAccountFindOpenLots((Account const *)arg1,arg2,arg3,arg4);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_LotList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetReconcileLastDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  time64 *arg2 = (time64 *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  time64 secs2 ;
  time64 secs20 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  {
    arg2 = &secs2;
  }
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetReconcileLastDate" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetReconcileLastDate((Account const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  {
    PyDateTime_IMPORT;
    PyObject *tp;
    struct tm t;
    
    // directly access return value (result) of function
    // only return datetime if TRUE
    if(result) {
      gnc_localtime_r(arg2, &t);
      tp = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
      
      resultobj = SWIG_Python_AppendOutput(resultobj, tp);
    } else resultobj = SWIG_Python_AppendOutput(resultobj, Py_None);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetReconcileLastDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetReconcileLastDate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetReconcileLastDate" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  xaccAccountSetReconcileLastDate(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetReconcileLastInterval(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  int *arg2 = (int *) 0 ;
  int *arg3 = (int *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetReconcileLastInterval", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetReconcileLastInterval" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_int, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountGetReconcileLastInterval" "', argument " "2"" of type '" "int *""'"); 
  }
  arg2 = (int *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_int, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountGetReconcileLastInterval" "', argument " "3"" of type '" "int *""'"); 
  }
  arg3 = (int *)(argp3);
  result = xaccAccountGetReconcileLastInterval((Account const *)arg1,arg2,arg3);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetReconcileLastInterval(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  int arg2 ;
  int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetReconcileLastInterval", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetReconcileLastInterval" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccAccountSetReconcileLastInterval" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "xaccAccountSetReconcileLastInterval" "', argument " "3"" of type '" "int""'");
  } 
  arg3 = (int)(val3);
  xaccAccountSetReconcileLastInterval(arg1,arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetReconcilePostponeDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  time64 *arg2 = (time64 *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  time64 secs2 ;
  time64 secs20 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  {
    arg2 = &secs2;
  }
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetReconcilePostponeDate" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetReconcilePostponeDate((Account const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  {
    PyDateTime_IMPORT;
    PyObject *tp;
    struct tm t;
    
    // directly access return value (result) of function
    // only return datetime if TRUE
    if(result) {
      gnc_localtime_r(arg2, &t);
      tp = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
      
      resultobj = SWIG_Python_AppendOutput(resultobj, tp);
    } else resultobj = SWIG_Python_AppendOutput(resultobj, Py_None);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetReconcilePostponeDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetReconcilePostponeDate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetReconcilePostponeDate" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  xaccAccountSetReconcilePostponeDate(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetReconcilePostponeBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_numeric *arg2 = (gnc_numeric *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountGetReconcilePostponeBalance", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetReconcilePostponeBalance" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountGetReconcilePostponeBalance" "', argument " "2"" of type '" "gnc_numeric *""'"); 
  }
  arg2 = (gnc_numeric *)(argp2);
  result = xaccAccountGetReconcilePostponeBalance((Account const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetReconcilePostponeBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetReconcilePostponeBalance", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetReconcilePostponeBalance" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetReconcilePostponeBalance" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccAccountSetReconcilePostponeBalance" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  xaccAccountSetReconcilePostponeBalance(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountClearReconcilePostpone(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountClearReconcilePostpone" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  xaccAccountClearReconcilePostpone(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetPlaceholder(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetPlaceholder" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetPlaceholder((Account const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetPlaceholder(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetPlaceholder", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetPlaceholder" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  xaccAccountSetPlaceholder(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetDescendantPlaceholder(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCPlaceholderType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetDescendantPlaceholder" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (GNCPlaceholderType)xaccAccountGetDescendantPlaceholder((Account const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetHidden(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetHidden" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetHidden((Account const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetHidden(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetHidden", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetHidden" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  xaccAccountSetHidden(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountIsHidden(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountIsHidden" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountIsHidden((Account const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetTaxRelated(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetTaxRelated" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetTaxRelated((Account const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetTaxRelated(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetTaxRelated", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetTaxRelated" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  xaccAccountSetTaxRelated(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetTaxUSCode(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetTaxUSCode" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)xaccAccountGetTaxUSCode((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetTaxUSCode(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetTaxUSCode", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetTaxUSCode" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetTaxUSCode" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccAccountSetTaxUSCode(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetTaxUSPayerNameSource(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetTaxUSPayerNameSource" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)xaccAccountGetTaxUSPayerNameSource((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetTaxUSPayerNameSource(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetTaxUSPayerNameSource", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetTaxUSPayerNameSource" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountSetTaxUSPayerNameSource" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccAccountSetTaxUSPayerNameSource(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountGetTaxUSCopyNumber(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountGetTaxUSCopyNumber" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountGetTaxUSCopyNumber((Account const *)arg1);
  resultobj = SWIG_From_long_SS_long((long long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetTaxUSCopyNumber(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gint64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  long long val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetTaxUSCopyNumber", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetTaxUSCopyNumber" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  ecode2 = SWIG_AsVal_long_SS_long(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccAccountSetTaxUSCopyNumber" "', argument " "2"" of type '" "gint64""'");
  } 
  arg2 = (gint64)(val2);
  xaccAccountSetTaxUSCopyNumber(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountSetMark(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  short arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  short val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountSetMark", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountSetMark" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  ecode2 = SWIG_AsVal_short(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccAccountSetMark" "', argument " "2"" of type '" "short""'");
  } 
  arg2 = (short)(val2);
  xaccAccountSetMark(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccClearMark(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  short arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  short val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccClearMark", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccClearMark" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  ecode2 = SWIG_AsVal_short(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccClearMark" "', argument " "2"" of type '" "short""'");
  } 
  arg2 = (short)(val2);
  xaccClearMark(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccClearMarkDown(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  short arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  short val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccClearMarkDown", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccClearMarkDown" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  ecode2 = SWIG_AsVal_short(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccClearMarkDown" "', argument " "2"" of type '" "short""'");
  } 
  arg2 = (short)(val2);
  xaccClearMarkDown(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_tree_begin_staged_transaction_traversals(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_tree_begin_staged_transaction_traversals" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  gnc_account_tree_begin_staged_transaction_traversals(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitsBeginStagedTransactionTraversals(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  SplitList *arg1 = (SplitList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_SplitList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitsBeginStagedTransactionTraversals" "', argument " "1"" of type '" "SplitList *""'"); 
  }
  arg1 = (SplitList *)(argp1);
  xaccSplitsBeginStagedTransactionTraversals(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountBeginStagedTransactionTraversals(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountBeginStagedTransactionTraversals" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  xaccAccountBeginStagedTransactionTraversals((Account const *)arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransactionTraverse(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransactionTraverse", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransactionTraverse" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccTransactionTraverse" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  result = xaccTransactionTraverse(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountStagedTransactionTraversal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  unsigned int arg2 ;
  TransactionCallback arg3 ;
  void *arg4 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  int res4 ;
  PyObject *swig_obj[4] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountStagedTransactionTraversal", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountStagedTransactionTraversal" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccAccountStagedTransactionTraversal" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_TransactionCallback,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountStagedTransactionTraversal" "', argument " "3"" of type '" "TransactionCallback""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccAccountStagedTransactionTraversal" "', argument " "3"" of type '" "TransactionCallback""'");
    } else {
      arg3 = *((TransactionCallback *)(argp3));
    }
  }
  res4 = SWIG_ConvertPtr(swig_obj[3],SWIG_as_voidptrptr(&arg4), 0, 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "xaccAccountStagedTransactionTraversal" "', argument " "4"" of type '" "void *""'"); 
  }
  result = (int)xaccAccountStagedTransactionTraversal((Account const *)arg1,arg2,arg3,arg4);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_tree_staged_transaction_traversal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  unsigned int arg2 ;
  TransactionCallback arg3 ;
  void *arg4 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  unsigned int val2 ;
  int ecode2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  int res4 ;
  PyObject *swig_obj[4] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_tree_staged_transaction_traversal", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_tree_staged_transaction_traversal" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  ecode2 = SWIG_AsVal_unsigned_SS_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gnc_account_tree_staged_transaction_traversal" "', argument " "2"" of type '" "unsigned int""'");
  } 
  arg2 = (unsigned int)(val2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_TransactionCallback,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_account_tree_staged_transaction_traversal" "', argument " "3"" of type '" "TransactionCallback""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_account_tree_staged_transaction_traversal" "', argument " "3"" of type '" "TransactionCallback""'");
    } else {
      arg3 = *((TransactionCallback *)(argp3));
    }
  }
  res4 = SWIG_ConvertPtr(swig_obj[3],SWIG_as_voidptrptr(&arg4), 0, 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gnc_account_tree_staged_transaction_traversal" "', argument " "4"" of type '" "void *""'"); 
  }
  result = (int)gnc_account_tree_staged_transaction_traversal((Account const *)arg1,arg2,arg3,arg4);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountTreeForEachTransaction(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  TransactionCallback arg2 ;
  void *arg3 = (void *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  int res3 ;
  PyObject *swig_obj[3] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountTreeForEachTransaction", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountTreeForEachTransaction" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_TransactionCallback,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountTreeForEachTransaction" "', argument " "2"" of type '" "TransactionCallback""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccAccountTreeForEachTransaction" "', argument " "2"" of type '" "TransactionCallback""'");
    } else {
      arg2 = *((TransactionCallback *)(argp2));
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2],SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountTreeForEachTransaction" "', argument " "3"" of type '" "void *""'"); 
  }
  result = (int)xaccAccountTreeForEachTransaction(arg1,arg2,arg3);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_imap_create_imap(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncImportMatchMap *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_imap_create_imap" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (GncImportMatchMap *)gnc_account_imap_create_imap(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GncImportMatchMap, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_imap_find_account(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncImportMatchMap *arg1 = (GncImportMatchMap *) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  int res3 ;
  char *buf3 = 0 ;
  int alloc3 = 0 ;
  PyObject *swig_obj[3] ;
  Account *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_imap_find_account", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncImportMatchMap, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_imap_find_account" "', argument " "1"" of type '" "GncImportMatchMap *""'"); 
  }
  arg1 = (GncImportMatchMap *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_imap_find_account" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  res3 = SWIG_AsCharPtrAndSize(swig_obj[2], &buf3, NULL, &alloc3);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_account_imap_find_account" "', argument " "3"" of type '" "char const *""'");
  }
  arg3 = (char *)(buf3);
  result = (Account *)gnc_account_imap_find_account(arg1,(char const *)arg2,(char const *)arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_imap_add_account(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncImportMatchMap *arg1 = (GncImportMatchMap *) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  Account *arg4 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  int res3 ;
  char *buf3 = 0 ;
  int alloc3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  PyObject *swig_obj[4] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_imap_add_account", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncImportMatchMap, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_imap_add_account" "', argument " "1"" of type '" "GncImportMatchMap *""'"); 
  }
  arg1 = (GncImportMatchMap *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_imap_add_account" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  res3 = SWIG_AsCharPtrAndSize(swig_obj[2], &buf3, NULL, &alloc3);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_account_imap_add_account" "', argument " "3"" of type '" "char const *""'");
  }
  arg3 = (char *)(buf3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gnc_account_imap_add_account" "', argument " "4"" of type '" "Account *""'"); 
  }
  arg4 = (Account *)(argp4);
  gnc_account_imap_add_account(arg1,(char const *)arg2,(char const *)arg3,arg4);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_imap_delete_account(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncImportMatchMap *arg1 = (GncImportMatchMap *) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  int res3 ;
  char *buf3 = 0 ;
  int alloc3 = 0 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_imap_delete_account", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncImportMatchMap, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_imap_delete_account" "', argument " "1"" of type '" "GncImportMatchMap *""'"); 
  }
  arg1 = (GncImportMatchMap *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_imap_delete_account" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  res3 = SWIG_AsCharPtrAndSize(swig_obj[2], &buf3, NULL, &alloc3);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_account_imap_delete_account" "', argument " "3"" of type '" "char const *""'");
  }
  arg3 = (char *)(buf3);
  gnc_account_imap_delete_account(arg1,(char const *)arg2,(char const *)arg3);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_imap_find_account_bayes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncImportMatchMap *arg1 = (GncImportMatchMap *) 0 ;
  GList *arg2 = (GList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Account *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_imap_find_account_bayes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncImportMatchMap, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_imap_find_account_bayes" "', argument " "1"" of type '" "GncImportMatchMap *""'"); 
  }
  arg1 = (GncImportMatchMap *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_imap_find_account_bayes" "', argument " "2"" of type '" "GList *""'"); 
  }
  arg2 = (GList *)(argp2);
  result = (Account *)gnc_account_imap_find_account_bayes(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_imap_add_account_bayes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncImportMatchMap *arg1 = (GncImportMatchMap *) 0 ;
  GList *arg2 = (GList *) 0 ;
  Account *arg3 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_imap_add_account_bayes", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncImportMatchMap, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_imap_add_account_bayes" "', argument " "1"" of type '" "GncImportMatchMap *""'"); 
  }
  arg1 = (GncImportMatchMap *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_imap_add_account_bayes" "', argument " "2"" of type '" "GList *""'"); 
  }
  arg2 = (GList *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_account_imap_add_account_bayes" "', argument " "3"" of type '" "Account *""'"); 
  }
  arg3 = (Account *)(argp3);
  gnc_account_imap_add_account_bayes(arg1,arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_source_account_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "GncImapInfo_source_account_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_source_account_set" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "GncImapInfo_source_account_set" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  if (arg1) (arg1)->source_account = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_source_account_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_source_account_get" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  result = (Account *) ((arg1)->source_account);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_map_account_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "GncImapInfo_map_account_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_map_account_set" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "GncImapInfo_map_account_set" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  if (arg1) (arg1)->map_account = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_map_account_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_map_account_get" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  result = (Account *) ((arg1)->map_account);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_list_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  GList *arg2 = (GList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "GncImapInfo_list_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_list_set" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "GncImapInfo_list_set" "', argument " "2"" of type '" "GList *""'"); 
  }
  arg2 = (GList *)(argp2);
  if (arg1) (arg1)->list = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_list_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_list_get" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  result = (GList *) ((arg1)->list);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_head_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "GncImapInfo_head_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_head_set" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "GncImapInfo_head_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  if (arg1->head) free((char*)arg1->head);
  if (arg2) {
    size_t size = strlen((const char *)(arg2)) + 1;
    arg1->head = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
  } else {
    arg1->head = 0;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_head_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_head_get" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  result = (char *) ((arg1)->head);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_category_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "GncImapInfo_category_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_category_set" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "GncImapInfo_category_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  if (arg1->category) free((char*)arg1->category);
  if (arg2) {
    size_t size = strlen((const char *)(arg2)) + 1;
    arg1->category = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
  } else {
    arg1->category = 0;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_category_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_category_get" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  result = (char *) ((arg1)->category);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_match_string_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "GncImapInfo_match_string_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_match_string_set" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "GncImapInfo_match_string_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  if (arg1->match_string) free((char*)arg1->match_string);
  if (arg2) {
    size_t size = strlen((const char *)(arg2)) + 1;
    arg1->match_string = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
  } else {
    arg1->match_string = 0;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_match_string_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_match_string_get" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  result = (char *) ((arg1)->match_string);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_count_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "GncImapInfo_count_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_count_set" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "GncImapInfo_count_set" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  if (arg1->count) free((char*)arg1->count);
  if (arg2) {
    size_t size = strlen((const char *)(arg2)) + 1;
    arg1->count = (char *)(char *)memcpy(malloc((size)*sizeof(char)), (const char *)(arg2), sizeof(char)*(size));
  } else {
    arg1->count = 0;
  }
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncImapInfo_count_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncImapInfo_count_get" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  result = (char *) ((arg1)->count);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_GncImapInfo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "new_GncImapInfo", 0, 0, 0)) SWIG_fail;
  result = (struct imap_info *)calloc(1, sizeof(struct imap_info));
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_imap_info, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_GncImapInfo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct imap_info *arg1 = (struct imap_info *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_imap_info, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_GncImapInfo" "', argument " "1"" of type '" "struct imap_info *""'"); 
  }
  arg1 = (struct imap_info *)(argp1);
  free((char *) arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *GncImapInfo_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_imap_info, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *GncImapInfo_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_gnc_account_imap_get_info_bayes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_imap_get_info_bayes" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (GList *)gnc_account_imap_get_info_bayes(arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_imap_get_info(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  GList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_imap_get_info", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_imap_get_info" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_imap_get_info" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (GList *)gnc_account_imap_get_info(arg1,(char const *)arg2);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_get_map_entry(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  gchar *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_get_map_entry", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_get_map_entry" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_get_map_entry" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (gchar *)gnc_account_get_map_entry(arg1,(char const *)arg2);
  resultobj = SWIG_FromCharPtr((const char *)result);
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_delete_map_entry(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  char *arg4 = (char *) 0 ;
  gboolean arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  int res3 ;
  char *buf3 = 0 ;
  int alloc3 = 0 ;
  int res4 ;
  char *buf4 = 0 ;
  int alloc4 = 0 ;
  PyObject *swig_obj[5] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_account_delete_map_entry", 5, 5, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_delete_map_entry" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_account_delete_map_entry" "', argument " "2"" of type '" "char *""'");
  }
  arg2 = (char *)(buf2);
  res3 = SWIG_AsCharPtrAndSize(swig_obj[2], &buf3, NULL, &alloc3);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_account_delete_map_entry" "', argument " "3"" of type '" "char *""'");
  }
  arg3 = (char *)(buf3);
  res4 = SWIG_AsCharPtrAndSize(swig_obj[3], &buf4, NULL, &alloc4);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gnc_account_delete_map_entry" "', argument " "4"" of type '" "char *""'");
  }
  arg4 = (char *)(buf4);
  {
    if (swig_obj[4] == Py_True)
    arg5 = TRUE;
    else if (swig_obj[4] == Py_False)
    arg5 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gnc_account_delete_map_entry(arg1,arg2,arg3,arg4,arg5);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  if (alloc4 == SWIG_NEWOBJ) free((char*)buf4);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  if (alloc4 == SWIG_NEWOBJ) free((char*)buf4);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_account_delete_all_bayes_maps(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_account_delete_all_bayes_maps" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  gnc_account_delete_all_bayes_maps(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_DxaccAccountSetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "DxaccAccountSetCurrency", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "DxaccAccountSetCurrency" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "DxaccAccountSetCurrency" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  DxaccAccountSetCurrency(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_DxaccAccountGetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "DxaccAccountGetCurrency" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (gnc_commodity *)DxaccAccountGetCurrency((Account const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_dxaccAccountSetQuoteTZ(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "dxaccAccountSetQuoteTZ", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "dxaccAccountSetQuoteTZ" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "dxaccAccountSetQuoteTZ" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  dxaccAccountSetQuoteTZ(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_dxaccAccountGetQuoteTZ(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "dxaccAccountGetQuoteTZ" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (char *)dxaccAccountGetQuoteTZ((Account const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_transaction_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_transaction_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_transaction_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccMallocTransaction(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Transaction *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccMallocTransaction" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (Transaction *)xaccMallocTransaction(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Transaction, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransDestroy" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  xaccTransDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransClone(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Transaction *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransClone" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (Transaction *)xaccTransClone((Transaction const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Transaction, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransCloneNoKvp(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Transaction *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransCloneNoKvp" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (Transaction *)xaccTransCloneNoKvp((Transaction const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Transaction, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Transaction *arg2 = (Transaction *) 0 ;
  gboolean arg3 ;
  gboolean arg4 ;
  gboolean arg5 ;
  gboolean arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[6] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransEqual", 6, 6, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransEqual" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransEqual" "', argument " "2"" of type '" "Transaction const *""'"); 
  }
  arg2 = (Transaction *)(argp2);
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[4] == Py_True)
    arg5 = TRUE;
    else if (swig_obj[4] == Py_False)
    arg5 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[5] == Py_True)
    arg6 = TRUE;
    else if (swig_obj[5] == Py_False)
    arg6 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = xaccTransEqual((Transaction const *)arg1,(Transaction const *)arg2,arg3,arg4,arg5,arg6);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransBeginEdit" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  xaccTransBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransCommitEdit" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  xaccTransCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransRollbackEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransRollbackEdit" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  xaccTransRollbackEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransIsOpen(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransIsOpen" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransIsOpen((Transaction const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransLookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Transaction *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransLookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransLookup" "', argument " "1"" of type '" "GncGUID const *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransLookup" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  result = (Transaction *)xaccTransLookup((struct _gncGuid const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Transaction, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransCopyToClipBoard(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Transaction *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransCopyToClipBoard" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (Transaction *)xaccTransCopyToClipBoard((Transaction const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Transaction, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransCopyOnto(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Transaction *arg2 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransCopyOnto", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransCopyOnto" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransCopyOnto" "', argument " "2"" of type '" "Transaction *""'"); 
  }
  arg2 = (Transaction *)(argp2);
  xaccTransCopyOnto((Transaction const *)arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransCopyFromClipBoard(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Transaction *arg2 = (Transaction *) 0 ;
  Account *arg3 = (Account *) 0 ;
  Account *arg4 = (Account *) 0 ;
  gboolean arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  PyObject *swig_obj[5] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransCopyFromClipBoard", 5, 5, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransCopyFromClipBoard" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransCopyFromClipBoard" "', argument " "2"" of type '" "Transaction *""'"); 
  }
  arg2 = (Transaction *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccTransCopyFromClipBoard" "', argument " "3"" of type '" "Account const *""'"); 
  }
  arg3 = (Account *)(argp3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "xaccTransCopyFromClipBoard" "', argument " "4"" of type '" "Account *""'"); 
  }
  arg4 = (Account *)(argp4);
  {
    if (swig_obj[4] == Py_True)
    arg5 = TRUE;
    else if (swig_obj[4] == Py_False)
    arg5 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  xaccTransCopyFromClipBoard((Transaction const *)arg1,arg2,(Account const *)arg3,arg4,arg5);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransFindSplitByAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Split *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransFindSplitByAccount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransFindSplitByAccount" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransFindSplitByAccount" "', argument " "2"" of type '" "Account const *""'"); 
  }
  arg2 = (Account *)(argp2);
  result = (Split *)xaccTransFindSplitByAccount((Transaction const *)arg1,(Account const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransScrubGains(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransScrubGains", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransScrubGains" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransScrubGains" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  xaccTransScrubGains(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_book_count_transactions(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  guint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_book_count_transactions" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = gnc_book_count_transactions(arg1);
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransUseTradingAccounts(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransUseTradingAccounts" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransUseTradingAccounts((Transaction const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSortSplits(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSortSplits" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  xaccTransSortSplits(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetTxnType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  char arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetTxnType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetTxnType" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  ecode2 = SWIG_AsVal_char(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccTransSetTxnType" "', argument " "2"" of type '" "char""'");
  } 
  arg2 = (char)(val2);
  xaccTransSetTxnType(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetTxnType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetTxnType" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (char)xaccTransGetTxnType((Transaction const *)arg1);
  resultobj = SWIG_From_char((char)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetNum(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetNum", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetNum" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransSetNum" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccTransSetNum(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetDescription(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetDescription", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetDescription" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransSetDescription" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccTransSetDescription(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetAssociation(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetAssociation", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetAssociation" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransSetAssociation" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccTransSetAssociation(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetNotes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetNotes" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransSetNotes" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccTransSetNotes(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetNum(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetNum" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (char *)xaccTransGetNum((Transaction const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetDescription(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetDescription" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (char *)xaccTransGetDescription((Transaction const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetAssociation(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetAssociation" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (char *)xaccTransGetAssociation((Transaction const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetNotes" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (char *)xaccTransGetNotes((Transaction const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetIsClosingTxn(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetIsClosingTxn", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetIsClosingTxn" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  xaccTransSetIsClosingTxn(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetIsClosingTxn(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetIsClosingTxn" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransGetIsClosingTxn((Transaction const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Split *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransGetSplit", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetSplit" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccTransGetSplit" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  result = (Split *)xaccTransGetSplit((Transaction const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetSplitIndex(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransGetSplitIndex", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetSplitIndex" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransGetSplitIndex" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  result = (int)xaccTransGetSplitIndex((Transaction const *)arg1,(Split const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetSplitList(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  SplitList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetSplitList" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (SplitList *)xaccTransGetSplitList((Transaction const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_SplitList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetPaymentAcctSplitList(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  SplitList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetPaymentAcctSplitList" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (SplitList *)xaccTransGetPaymentAcctSplitList((Transaction const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_SplitList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetAPARAcctSplitList(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  SplitList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransGetAPARAcctSplitList", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetAPARAcctSplitList" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = (SplitList *)xaccTransGetAPARAcctSplitList((Transaction const *)arg1,arg2);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_SplitList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransStillHasSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransStillHasSplit", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransStillHasSplit" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransStillHasSplit" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  result = xaccTransStillHasSplit((Transaction const *)arg1,(Split const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetFirstPaymentAcctSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Split *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetFirstPaymentAcctSplit" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (Split *)xaccTransGetFirstPaymentAcctSplit((Transaction const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetFirstAPARAcctSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  Split *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransGetFirstAPARAcctSplit", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetFirstAPARAcctSplit" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = (Split *)xaccTransGetFirstAPARAcctSplit((Transaction const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetReadOnly(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetReadOnly", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetReadOnly" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransSetReadOnly" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccTransSetReadOnly(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransClearReadOnly(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransClearReadOnly" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  xaccTransClearReadOnly(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetReadOnly(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetReadOnly" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (char *)xaccTransGetReadOnly(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransIsReadonlyByPostedDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransIsReadonlyByPostedDate" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransIsReadonlyByPostedDate((Transaction const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransInFutureByPostedDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransInFutureByPostedDate" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransInFutureByPostedDate((Transaction const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransCountSplits(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  int result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransCountSplits" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (int)xaccTransCountSplits((Transaction const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransHasReconciledSplits(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransHasReconciledSplits" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransHasReconciledSplits((Transaction const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransHasReconciledSplitsByAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransHasReconciledSplitsByAccount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransHasReconciledSplitsByAccount" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransHasReconciledSplitsByAccount" "', argument " "2"" of type '" "Account const *""'"); 
  }
  arg2 = (Account *)(argp2);
  result = xaccTransHasReconciledSplitsByAccount((Transaction const *)arg1,(Account const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransHasSplitsInState(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  char arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransHasSplitsInState", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransHasSplitsInState" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  ecode2 = SWIG_AsVal_char(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccTransHasSplitsInState" "', argument " "2"" of type '" "char""'");
  } 
  arg2 = (char)(val2);
  result = xaccTransHasSplitsInState((Transaction const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransHasSplitsInStateByAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  char arg2 ;
  Account *arg3 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  char val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransHasSplitsInStateByAccount", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransHasSplitsInStateByAccount" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  ecode2 = SWIG_AsVal_char(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccTransHasSplitsInStateByAccount" "', argument " "2"" of type '" "char""'");
  } 
  arg2 = (char)(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccTransHasSplitsInStateByAccount" "', argument " "3"" of type '" "Account const *""'"); 
  }
  arg3 = (Account *)(argp3);
  result = xaccTransHasSplitsInStateByAccount((Transaction const *)arg1,arg2,(Account const *)arg3);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetCurrency" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (gnc_commodity *)xaccTransGetCurrency((Transaction const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetCurrency", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetCurrency" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransSetCurrency" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  xaccTransSetCurrency(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetImbalanceValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetImbalanceValue" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransGetImbalanceValue((Transaction const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetImbalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  MonetaryList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetImbalance" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (MonetaryList *)xaccTransGetImbalance((Transaction const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransIsBalanced(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransIsBalanced" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransIsBalanced((Transaction const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetAccountValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransGetAccountValue", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetAccountValue" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransGetAccountValue" "', argument " "2"" of type '" "Account const *""'"); 
  }
  arg2 = (Account *)(argp2);
  result = xaccTransGetAccountValue((Transaction const *)arg1,(Account const *)arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetAccountAmount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransGetAccountAmount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetAccountAmount" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransGetAccountAmount" "', argument " "2"" of type '" "Account const *""'"); 
  }
  arg2 = (Account *)(argp2);
  result = xaccTransGetAccountAmount((Transaction const *)arg1,(Account const *)arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetRateForCommodity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  Split *arg3 = (Split *) 0 ;
  gnc_numeric *arg4 = (gnc_numeric *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  PyObject *swig_obj[4] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransGetRateForCommodity", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetRateForCommodity" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransGetRateForCommodity" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccTransGetRateForCommodity" "', argument " "3"" of type '" "Split const *""'"); 
  }
  arg3 = (Split *)(argp3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "xaccTransGetRateForCommodity" "', argument " "4"" of type '" "gnc_numeric *""'"); 
  }
  arg4 = (gnc_numeric *)(argp4);
  result = xaccTransGetRateForCommodity((Transaction const *)arg1,(gnc_commodity const *)arg2,(Split const *)arg3,arg4);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetAccountConvRate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransGetAccountConvRate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetAccountConvRate" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransGetAccountConvRate" "', argument " "2"" of type '" "Account const *""'"); 
  }
  arg2 = (Account *)(argp2);
  result = xaccTransGetAccountConvRate((Transaction const *)arg1,(Account const *)arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetAccountBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransGetAccountBalance", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetAccountBalance" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransGetAccountBalance" "', argument " "2"" of type '" "Account const *""'"); 
  }
  arg2 = (Account *)(argp2);
  result = xaccTransGetAccountBalance((Transaction const *)arg1,(Account const *)arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransOrder(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  Transaction *arg2 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransOrder", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransOrder" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransOrder" "', argument " "2"" of type '" "Transaction const *""'"); 
  }
  arg2 = (Transaction *)(argp2);
  result = (int)xaccTransOrder((Transaction const *)arg1,(Transaction const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransOrder_num_action(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  char *arg2 = (char *) 0 ;
  Transaction *arg3 = (Transaction *) 0 ;
  char *arg4 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  int res4 ;
  char *buf4 = 0 ;
  int alloc4 = 0 ;
  PyObject *swig_obj[4] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransOrder_num_action", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransOrder_num_action" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransOrder_num_action" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccTransOrder_num_action" "', argument " "3"" of type '" "Transaction const *""'"); 
  }
  arg3 = (Transaction *)(argp3);
  res4 = SWIG_AsCharPtrAndSize(swig_obj[3], &buf4, NULL, &alloc4);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "xaccTransOrder_num_action" "', argument " "4"" of type '" "char const *""'");
  }
  arg4 = (char *)(buf4);
  result = (int)xaccTransOrder_num_action((Transaction const *)arg1,(char const *)arg2,(Transaction const *)arg3,(char const *)arg4);
  resultobj = SWIG_From_int((int)(result));
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc4 == SWIG_NEWOBJ) free((char*)buf4);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc4 == SWIG_NEWOBJ) free((char*)buf4);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  int arg2 ;
  int arg3 ;
  int arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetDate", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetDate" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "xaccTransSetDate" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "xaccTransSetDate" "', argument " "3"" of type '" "int""'");
  } 
  arg3 = (int)(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "xaccTransSetDate" "', argument " "4"" of type '" "int""'");
  } 
  arg4 = (int)(val4);
  xaccTransSetDate(arg1,arg2,arg3,arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetDatePostedGDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  GDate arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetDatePostedGDate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetDatePostedGDate" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_GDate,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransSetDatePostedGDate" "', argument " "2"" of type '" "GDate""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccTransSetDatePostedGDate" "', argument " "2"" of type '" "GDate""'");
    } else {
      arg2 = *((GDate *)(argp2));
    }
  }
  xaccTransSetDatePostedGDate(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetDatePostedSecs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetDatePostedSecs", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetDatePostedSecs" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  xaccTransSetDatePostedSecs(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetDatePostedSecsNormalized(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetDatePostedSecsNormalized", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetDatePostedSecsNormalized" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  xaccTransSetDatePostedSecsNormalized(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetDateEnteredSecs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetDateEnteredSecs", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetDateEnteredSecs" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  xaccTransSetDateEnteredSecs(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransSetDateDue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransSetDateDue", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransSetDateDue" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  xaccTransSetDateDue(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetDate" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransGetDate((Transaction const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransRetDatePosted(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransRetDatePosted" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransRetDatePosted((Transaction const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetDatePostedGDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GDate result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetDatePostedGDate" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransGetDatePostedGDate((Transaction const *)arg1);
  resultobj = SWIG_NewPointerObj((GDate *)memcpy((GDate *)calloc(1,sizeof(GDate)),&result,sizeof(GDate)), SWIGTYPE_p_GDate, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetDateEntered(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetDateEntered" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransGetDateEntered((Transaction const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransRetDateEntered(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransRetDateEntered" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransRetDateEntered((Transaction const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransRetDateDue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransRetDateDue" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransRetDateDue((Transaction const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransVoid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccTransVoid", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransVoid" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccTransVoid" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  xaccTransVoid(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransUnvoid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransUnvoid" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  xaccTransUnvoid(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransReverse(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Transaction *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransReverse" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (Transaction *)xaccTransReverse(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Transaction, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetReversedBy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Transaction *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetReversedBy" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (Transaction *)xaccTransGetReversedBy((Transaction const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Transaction, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetVoidStatus(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetVoidStatus" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransGetVoidStatus((Transaction const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetVoidReason(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetVoidReason" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (char *)xaccTransGetVoidReason((Transaction const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccTransGetVoidTime(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccTransGetVoidTime" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = xaccTransGetVoidTime((Transaction const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncLotClass_parent_class_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncLotClass *arg1 = (GncLotClass *) 0 ;
  QofInstanceClass arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "GncLotClass_parent_class_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncLotClass, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncLotClass_parent_class_set" "', argument " "1"" of type '" "GncLotClass *""'"); 
  }
  arg1 = (GncLotClass *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_QofInstanceClass,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "GncLotClass_parent_class_set" "', argument " "2"" of type '" "QofInstanceClass""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "GncLotClass_parent_class_set" "', argument " "2"" of type '" "QofInstanceClass""'");
    } else {
      arg2 = *((QofInstanceClass *)(argp2));
    }
  }
  if (arg1) (arg1)->parent_class = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncLotClass_parent_class_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncLotClass *arg1 = (GncLotClass *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofInstanceClass result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncLotClass, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncLotClass_parent_class_get" "', argument " "1"" of type '" "GncLotClass *""'"); 
  }
  arg1 = (GncLotClass *)(argp1);
  result =  ((arg1)->parent_class);
  resultobj = SWIG_NewPointerObj((QofInstanceClass *)memcpy((QofInstanceClass *)calloc(1,sizeof(QofInstanceClass)),&result,sizeof(QofInstanceClass)), SWIGTYPE_p_QofInstanceClass, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_GncLotClass(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncLotClass *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "new_GncLotClass", 0, 0, 0)) SWIG_fail;
  result = (GncLotClass *)calloc(1, sizeof(GncLotClass));
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GncLotClass, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_GncLotClass(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncLotClass *arg1 = (GncLotClass *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GncLotClass, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_GncLotClass" "', argument " "1"" of type '" "GncLotClass *""'"); 
  }
  arg1 = (GncLotClass *)(argp1);
  free((char *) arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *GncLotClass_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_GncLotClass, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *GncLotClass_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_gnc_lot_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_lot_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_lot_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_new(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCLot *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_new" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GNCLot *)gnc_lot_new(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCLot, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_destroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_destroy" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  gnc_lot_destroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_lookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GNCLot *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_lot_lookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_lookup" "', argument " "1"" of type '" "GncGUID const *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_lot_lookup" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  result = (GNCLot *)gnc_lot_lookup((struct _gncGuid const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCLot, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_get_book(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBook *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_get_book" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = (QofBook *)gnc_lot_get_book(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofBook, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_begin_edit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_begin_edit" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  gnc_lot_begin_edit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_commit_edit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_commit_edit" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  gnc_lot_commit_edit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_add_split(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_lot_add_split", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_add_split" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_lot_add_split" "', argument " "2"" of type '" "Split *""'"); 
  }
  arg2 = (Split *)(argp2);
  gnc_lot_add_split(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_remove_split(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  Split *arg2 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_lot_remove_split", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_remove_split" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_lot_remove_split" "', argument " "2"" of type '" "Split *""'"); 
  }
  arg2 = (Split *)(argp2);
  gnc_lot_remove_split(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_get_split_list(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  SplitList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_get_split_list" "', argument " "1"" of type '" "GNCLot const *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = (SplitList *)gnc_lot_get_split_list((GNCLot const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_SplitList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_count_splits(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_count_splits" "', argument " "1"" of type '" "GNCLot const *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = gnc_lot_count_splits((GNCLot const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_get_account(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_get_account" "', argument " "1"" of type '" "GNCLot const *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = (Account *)gnc_lot_get_account((GNCLot const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_set_account(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_lot_set_account", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_set_account" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_lot_set_account" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  gnc_lot_set_account(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_get_balance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_get_balance" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = gnc_lot_get_balance(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_get_balance_before(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  Split *arg2 = (Split *) 0 ;
  gnc_numeric *arg3 = (gnc_numeric *) 0 ;
  gnc_numeric *arg4 = (gnc_numeric *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  PyObject *swig_obj[4] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_lot_get_balance_before", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_get_balance_before" "', argument " "1"" of type '" "GNCLot const *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_lot_get_balance_before" "', argument " "2"" of type '" "Split const *""'"); 
  }
  arg2 = (Split *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_lot_get_balance_before" "', argument " "3"" of type '" "gnc_numeric *""'"); 
  }
  arg3 = (gnc_numeric *)(argp3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gnc_lot_get_balance_before" "', argument " "4"" of type '" "gnc_numeric *""'"); 
  }
  arg4 = (gnc_numeric *)(argp4);
  gnc_lot_get_balance_before((GNCLot const *)arg1,(Split const *)arg2,arg3,arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_is_closed(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_is_closed" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = gnc_lot_is_closed(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_get_earliest_split(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Split *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_get_earliest_split" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = (Split *)gnc_lot_get_earliest_split(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_get_latest_split(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Split *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_get_latest_split" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = (Split *)gnc_lot_get_latest_split(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_set_closed_unknown(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_set_closed_unknown" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  gnc_lot_set_closed_unknown(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_get_title(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_get_title" "', argument " "1"" of type '" "GNCLot const *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = (char *)gnc_lot_get_title((GNCLot const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_get_notes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_get_notes" "', argument " "1"" of type '" "GNCLot const *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = (char *)gnc_lot_get_notes((GNCLot const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_set_title(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_lot_set_title", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_set_title" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_lot_set_title" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gnc_lot_set_title(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_set_notes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_lot_set_notes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_set_notes" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_lot_set_notes" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gnc_lot_set_notes(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_lot_make_default(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCLot *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_lot_make_default" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = (GNCLot *)gnc_lot_make_default(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCLot, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_backend_get_error(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBackend *arg1 = (QofBackend *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBackendError result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBackend, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_backend_get_error" "', argument " "1"" of type '" "QofBackend *""'"); 
  }
  arg1 = (QofBackend *)(argp1);
  result = (QofBackendError)qof_backend_get_error(arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_backend_set_error(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBackend *arg1 = (QofBackend *) 0 ;
  QofBackendError arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_backend_set_error", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBackend, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_backend_set_error" "', argument " "1"" of type '" "QofBackend *""'"); 
  }
  arg1 = (QofBackend *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "qof_backend_set_error" "', argument " "2"" of type '" "QofBackendError""'");
  } 
  arg2 = (QofBackendError)(val2);
  qof_backend_set_error(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_backend_can_rollback(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBackend *arg1 = (QofBackend *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBackend, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_backend_can_rollback" "', argument " "1"" of type '" "QofBackend *""'"); 
  }
  arg1 = (QofBackend *)(argp1);
  result = qof_backend_can_rollback(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_backend_rollback_instance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBackend *arg1 = (QofBackend *) 0 ;
  QofInstance *arg2 = (QofInstance *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_backend_rollback_instance", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBackend, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_backend_rollback_instance" "', argument " "1"" of type '" "QofBackend *""'"); 
  }
  arg1 = (QofBackend *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofInstance, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_backend_rollback_instance" "', argument " "2"" of type '" "QofInstance *""'"); 
  }
  arg2 = (QofInstance *)(argp2);
  qof_backend_rollback_instance(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_load_backend_library(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gchar *arg1 = (gchar *) 0 ;
  gchar *arg2 = (gchar *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_load_backend_library", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_load_backend_library" "', argument " "1"" of type '" "gchar const *""'");
  }
  arg1 = (gchar *)(buf1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_load_backend_library" "', argument " "2"" of type '" "gchar const *""'");
  }
  arg2 = (gchar *)(buf2);
  result = qof_load_backend_library((gchar const *)arg1,(gchar const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_finalize_backend_libraries(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_finalize_backend_libraries", 0, 0, 0)) SWIG_fail;
  qof_finalize_backend_libraries();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_get_backend(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBackend *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_get_backend" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (QofBackend *)qof_book_get_backend((QofBook const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofBackend, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_set_backend(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  QofBackend *arg2 = (QofBackend *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_book_set_backend", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_set_backend" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBackend, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_book_set_backend" "', argument " "2"" of type '" "QofBackend *""'"); 
  }
  arg2 = (QofBackend *)(argp2);
  qof_book_set_backend(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_new(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_session_new", 0, 0, 0)) SWIG_fail;
  result = (QofSession *)qof_session_new();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_destroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_destroy" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  qof_session_destroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_swap_data(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  QofSession *arg2 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_session_swap_data", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_swap_data" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_session_swap_data" "', argument " "2"" of type '" "QofSession *""'"); 
  }
  arg2 = (QofSession *)(argp2);
  qof_session_swap_data(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_begin(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  char *arg2 = (char *) 0 ;
  gboolean arg3 ;
  gboolean arg4 ;
  gboolean arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[5] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_session_begin", 5, 5, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_begin" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_session_begin" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[4] == Py_True)
    arg5 = TRUE;
    else if (swig_obj[4] == Py_False)
    arg5 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  qof_session_begin(arg1,(char const *)arg2,arg3,arg4,arg5);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_load(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  QofPercentageFunc arg2 = (QofPercentageFunc) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_session_load", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_load" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[1], (void**)(&arg2), SWIGTYPE_p_f_p_q_const__char_double__void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "qof_session_load" "', argument " "2"" of type '" "QofPercentageFunc""'"); 
    }
  }
  qof_session_load(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_get_error(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBackendError result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_get_error" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  result = (QofBackendError)qof_session_get_error(arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_get_error_message(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_get_error_message" "', argument " "1"" of type '" "QofSession const *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  result = (char *)qof_session_get_error_message((struct QofSessionImpl const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_pop_error(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBackendError result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_pop_error" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  result = (QofBackendError)qof_session_pop_error(arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_get_book(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBook *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_get_book" "', argument " "1"" of type '" "QofSession const *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  result = (QofBook *)qof_session_get_book((struct QofSessionImpl const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofBook, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_get_file_path(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_get_file_path" "', argument " "1"" of type '" "QofSession const *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  result = (char *)qof_session_get_file_path((struct QofSessionImpl const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_get_url(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_get_url" "', argument " "1"" of type '" "QofSession const *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  result = (char *)qof_session_get_url((struct QofSessionImpl const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_save_in_progress(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_save_in_progress" "', argument " "1"" of type '" "QofSession const *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  result = qof_session_save_in_progress((struct QofSessionImpl const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_get_backend(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBackend *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_get_backend" "', argument " "1"" of type '" "QofSession const *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  result = (QofBackend *)qof_session_get_backend((struct QofSessionImpl const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofBackend, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_save(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  QofPercentageFunc arg2 = (QofPercentageFunc) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_session_save", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_save" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[1], (void**)(&arg2), SWIGTYPE_p_f_p_q_const__char_double__void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "qof_session_save" "', argument " "2"" of type '" "QofPercentageFunc""'"); 
    }
  }
  qof_session_save(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_safe_save(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  QofPercentageFunc arg2 = (QofPercentageFunc) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_session_safe_save", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_safe_save" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[1], (void**)(&arg2), SWIGTYPE_p_f_p_q_const__char_double__void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "qof_session_safe_save" "', argument " "2"" of type '" "QofPercentageFunc""'"); 
    }
  }
  qof_session_safe_save(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_end(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_end" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  qof_session_end(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_events_pending(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_events_pending" "', argument " "1"" of type '" "QofSession const *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  result = qof_session_events_pending((struct QofSessionImpl const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_process_events(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_process_events" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  result = qof_session_process_events(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_export(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  QofSession *arg2 = (QofSession *) 0 ;
  QofPercentageFunc arg3 = (QofPercentageFunc) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_session_export", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_export" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_session_export" "', argument " "2"" of type '" "QofSession *""'"); 
  }
  arg2 = (QofSession *)(argp2);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[2], (void**)(&arg3), SWIGTYPE_p_f_p_q_const__char_double__void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "qof_session_export" "', argument " "3"" of type '" "QofPercentageFunc""'"); 
    }
  }
  result = qof_session_export(arg1,arg2,arg3);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_backend_get_registered_access_method_list(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_backend_get_registered_access_method_list", 0, 0, 0)) SWIG_fail;
  result = (GList *)qof_backend_get_registered_access_method_list();
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_session_ensure_all_data_loaded(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofSession *arg1 = (QofSession *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofSessionImpl, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_session_ensure_all_data_loaded" "', argument " "1"" of type '" "QofSession *""'"); 
  }
  arg1 = (QofSession *)(argp1);
  qof_session_ensure_all_data_loaded(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_use_trading_accounts(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_use_trading_accounts" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = qof_book_use_trading_accounts((QofBook const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_get_book_currency_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gchar *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_get_book_currency_name" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (gchar *)qof_book_get_book_currency_name(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_get_default_gains_policy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gchar *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_get_default_gains_policy" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (gchar *)qof_book_get_default_gains_policy(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_get_default_gain_loss_acct_guid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncGUID *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_get_default_gain_loss_acct_guid" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GncGUID *)qof_book_get_default_gain_loss_acct_guid(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_uses_autoreadonly(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_uses_autoreadonly" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = qof_book_uses_autoreadonly((QofBook const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_get_num_days_autoreadonly(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_get_num_days_autoreadonly" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = qof_book_get_num_days_autoreadonly((QofBook const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_get_autoreadonly_gdate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GDate *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_get_autoreadonly_gdate" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GDate *)qof_book_get_autoreadonly_gdate((QofBook const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GDate, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_use_split_action_for_num_field(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_use_split_action_for_num_field" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = qof_book_use_split_action_for_num_field((QofBook const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_shutting_down(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_shutting_down" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = qof_book_shutting_down((QofBook const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_book_session_not_saved(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_book_session_not_saved" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = qof_book_session_not_saved((QofBook const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_new(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofIdType arg1 = (QofIdType) 0 ;
  PyObject *swig_obj[1] ;
  QofCollection *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    if (PyUnicode_Check(swig_obj[0])) {
      arg1 = PyUnicode_AsUTF8(swig_obj[0]);
    } else if (PyBytes_Check(swig_obj[0])) {
      arg1 = PyBytes_AsString(swig_obj[0]);
    } else {
      PyErr_SetString(PyExc_TypeError, "not a string or bytes object");
      return NULL;
    }
  }
  result = (QofCollection *)qof_collection_new((gchar const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofCollection_s, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_count(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCollection *arg1 = (QofCollection *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  guint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_collection_count" "', argument " "1"" of type '" "QofCollection const *""'"); 
  }
  arg1 = (QofCollection *)(argp1);
  result = qof_collection_count((struct QofCollection_s const *)arg1);
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_destroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCollection *arg1 = (QofCollection *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_collection_destroy" "', argument " "1"" of type '" "QofCollection *""'"); 
  }
  arg1 = (QofCollection *)(argp1);
  qof_collection_destroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCollection *arg1 = (QofCollection *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofIdType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_collection_get_type" "', argument " "1"" of type '" "QofCollection const *""'"); 
  }
  arg1 = (QofCollection *)(argp1);
  result = (QofIdType)qof_collection_get_type((struct QofCollection_s const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_lookup_entity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCollection *arg1 = (QofCollection *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  QofInstance *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_collection_lookup_entity", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_collection_lookup_entity" "', argument " "1"" of type '" "QofCollection const *""'"); 
  }
  arg1 = (QofCollection *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_collection_lookup_entity" "', argument " "2"" of type '" "GncGUID const *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = (QofInstance *)qof_collection_lookup_entity((struct QofCollection_s const *)arg1,(struct _gncGuid const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofInstance, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_foreach(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCollection *arg1 = (QofCollection *) 0 ;
  QofInstanceForeachCB arg2 = (QofInstanceForeachCB) 0 ;
  gpointer arg3 = (gpointer) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_collection_foreach", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_collection_foreach" "', argument " "1"" of type '" "QofCollection const *""'"); 
  }
  arg1 = (QofCollection *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[1], (void**)(&arg2), SWIGTYPE_p_f_p_QofInstance_p_void__void);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "qof_collection_foreach" "', argument " "2"" of type '" "QofInstanceForeachCB""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2],SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "qof_collection_foreach" "', argument " "3"" of type '" "gpointer""'"); 
  }
  qof_collection_foreach((struct QofCollection_s const *)arg1,arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_get_data(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCollection *arg1 = (QofCollection *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gpointer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_collection_get_data" "', argument " "1"" of type '" "QofCollection const *""'"); 
  }
  arg1 = (QofCollection *)(argp1);
  result = (gpointer)qof_collection_get_data((struct QofCollection_s const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_void, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_set_data(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCollection *arg1 = (QofCollection *) 0 ;
  gpointer arg2 = (gpointer) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_collection_set_data", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_collection_set_data" "', argument " "1"" of type '" "QofCollection *""'"); 
  }
  arg1 = (QofCollection *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1],SWIG_as_voidptrptr(&arg2), 0, 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_collection_set_data" "', argument " "2"" of type '" "gpointer""'"); 
  }
  qof_collection_set_data(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_is_dirty(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCollection *arg1 = (QofCollection *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_collection_is_dirty" "', argument " "1"" of type '" "QofCollection const *""'"); 
  }
  arg1 = (QofCollection *)(argp1);
  result = qof_collection_is_dirty((struct QofCollection_s const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_add_entity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCollection *arg1 = (QofCollection *) 0 ;
  QofInstance *arg2 = (QofInstance *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_collection_add_entity", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_collection_add_entity" "', argument " "1"" of type '" "QofCollection *""'"); 
  }
  arg1 = (QofCollection *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofInstance, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_collection_add_entity" "', argument " "2"" of type '" "QofInstance *""'"); 
  }
  arg2 = (QofInstance *)(argp2);
  result = qof_collection_add_entity(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_remove_entity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofInstance *arg1 = (QofInstance *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofInstance, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_collection_remove_entity" "', argument " "1"" of type '" "QofInstance *""'"); 
  }
  arg1 = (QofInstance *)(argp1);
  qof_collection_remove_entity(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_compare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCollection *arg1 = (QofCollection *) 0 ;
  QofCollection *arg2 = (QofCollection *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gint result;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_collection_compare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_collection_compare" "', argument " "1"" of type '" "QofCollection *""'"); 
  }
  arg1 = (QofCollection *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_collection_compare" "', argument " "2"" of type '" "QofCollection *""'"); 
  }
  arg2 = (QofCollection *)(argp2);
  result = qof_collection_compare(arg1,arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_collection_from_glist(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofIdType arg1 = (QofIdType) 0 ;
  GList *arg2 = (GList *) 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  QofCollection *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_collection_from_glist", 2, 2, swig_obj)) SWIG_fail;
  {
    if (PyUnicode_Check(swig_obj[0])) {
      arg1 = PyUnicode_AsUTF8(swig_obj[0]);
    } else if (PyBytes_Check(swig_obj[0])) {
      arg1 = PyBytes_AsString(swig_obj[0]);
    } else {
      PyErr_SetString(PyExc_TypeError, "not a string or bytes object");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_collection_from_glist" "', argument " "2"" of type '" "GList const *""'"); 
  }
  arg2 = (GList *)(argp2);
  result = (QofCollection *)qof_collection_from_glist((gchar const *)arg1,(GList const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofCollection_s, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_init(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_init", 0, 0, 0)) SWIG_fail;
  qof_query_init();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_shutdown(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_shutdown", 0, 0, 0)) SWIG_fail;
  qof_query_shutdown();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_build_param_list__varargs__(PyObject *SWIGUNUSEDPARM(self), PyObject *args, PyObject *varargs) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  void *arg2 = 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  PyObject * obj0 = 0 ;
  QofQueryParamList *result = 0 ;
  
  if (!PyArg_UnpackTuple(args, "qof_query_build_param_list", 1, 1, &obj0)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(obj0, &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_build_param_list" "', argument " "1"" of type '" "char const *""'");
  }
  arg1 = (char *)(buf1);
  result = (QofQueryParamList *)qof_query_build_param_list((char const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GSList, 0 |  0 );
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_build_param_list(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj;
  PyObject *varargs;
  PyObject *newargs;
  
  newargs = PyTuple_GetSlice(args,0,1);
  varargs = PyTuple_GetSlice(args,1,PyTuple_Size(args));
  resultobj = _wrap_qof_query_build_param_list__varargs__(NULL,newargs,varargs);
  Py_XDECREF(newargs);
  Py_XDECREF(varargs);
  return resultobj;
}


SWIGINTERN PyObject *_wrap_qof_query_create(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_create", 0, 0, 0)) SWIG_fail;
  result = (QofQuery *)qof_query_create();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQuery, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_create_for(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofIdTypeConst arg1 = (QofIdTypeConst) 0 ;
  PyObject *swig_obj[1] ;
  QofQuery *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    if (PyUnicode_Check(swig_obj[0])) {
      arg1 = PyUnicode_AsUTF8(swig_obj[0]);
    } else if (PyBytes_Check(swig_obj[0])) {
      arg1 = PyBytes_AsString(swig_obj[0]);
    } else {
      PyErr_SetString(PyExc_TypeError, "not a string or bytes object");
      return NULL;
    }
  }
  result = (QofQuery *)qof_query_create_for((gchar const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQuery, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_destroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_destroy" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  qof_query_destroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_search_for(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofIdTypeConst arg2 = (QofIdTypeConst) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_search_for", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_search_for" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  {
    if (PyUnicode_Check(swig_obj[1])) {
      arg2 = PyUnicode_AsUTF8(swig_obj[1]);
    } else if (PyBytes_Check(swig_obj[1])) {
      arg2 = PyBytes_AsString(swig_obj[1]);
    } else {
      PyErr_SetString(PyExc_TypeError, "not a string or bytes object");
      return NULL;
    }
  }
  qof_query_search_for(arg1,(gchar const *)arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_set_book(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_set_book", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_set_book" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_query_set_book" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  qof_query_set_book(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_add_term(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQueryParamList *arg2 = (QofQueryParamList *) 0 ;
  QofQueryPredData *arg3 = (QofQueryPredData *) 0 ;
  QofQueryOp arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_add_term", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_add_term" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  {
    arg2 = NULL;
    /* Check if is a list */
    if (PyList_Check(swig_obj[1])) {
      int i;
      int size = PyList_Size(swig_obj[1]);
      for (i = size-1; i >= 0; i--) {
        PyObject *o = PyList_GetItem(swig_obj[1], i);
        if (PyUnicode_Check(o)) {
          /* There's no way to preserve constness in GSList items. */
          arg2 = g_slist_prepend(arg2, (char*)PyUnicode_AsUTF8(PyList_GetItem(swig_obj[1], i)));
        } else {
          PyErr_SetString(PyExc_TypeError, "list must contain strings");
          g_slist_free(arg2);
          return NULL;
        }
      }
    } else {
      PyErr_SetString(PyExc_TypeError, "not a list");
      return NULL;
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "qof_query_add_term" "', argument " "3"" of type '" "QofQueryPredData *""'"); 
  }
  arg3 = (QofQueryPredData *)(argp3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "qof_query_add_term" "', argument " "4"" of type '" "QofQueryOp""'");
  } 
  arg4 = (QofQueryOp)(val4);
  qof_query_add_term(arg1,arg2,arg3,arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_add_guid_match(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQueryParamList *arg2 = (QofQueryParamList *) 0 ;
  GncGUID *arg3 = (GncGUID *) 0 ;
  QofQueryOp arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_add_guid_match", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_add_guid_match" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  {
    arg2 = NULL;
    /* Check if is a list */
    if (PyList_Check(swig_obj[1])) {
      int i;
      int size = PyList_Size(swig_obj[1]);
      for (i = size-1; i >= 0; i--) {
        PyObject *o = PyList_GetItem(swig_obj[1], i);
        if (PyUnicode_Check(o)) {
          /* There's no way to preserve constness in GSList items. */
          arg2 = g_slist_prepend(arg2, (char*)PyUnicode_AsUTF8(PyList_GetItem(swig_obj[1], i)));
        } else {
          PyErr_SetString(PyExc_TypeError, "list must contain strings");
          g_slist_free(arg2);
          return NULL;
        }
      }
    } else {
      PyErr_SetString(PyExc_TypeError, "not a list");
      return NULL;
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "qof_query_add_guid_match" "', argument " "3"" of type '" "GncGUID const *""'"); 
  }
  arg3 = (GncGUID *)(argp3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "qof_query_add_guid_match" "', argument " "4"" of type '" "QofQueryOp""'");
  } 
  arg4 = (QofQueryOp)(val4);
  qof_query_add_guid_match(arg1,arg2,(struct _gncGuid const *)arg3,arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_add_guid_list_match(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQueryParamList *arg2 = (QofQueryParamList *) 0 ;
  GList *arg3 = (GList *) 0 ;
  QofGuidMatch arg4 ;
  QofQueryOp arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  PyObject *swig_obj[5] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_add_guid_list_match", 5, 5, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_add_guid_list_match" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  {
    arg2 = NULL;
    /* Check if is a list */
    if (PyList_Check(swig_obj[1])) {
      int i;
      int size = PyList_Size(swig_obj[1]);
      for (i = size-1; i >= 0; i--) {
        PyObject *o = PyList_GetItem(swig_obj[1], i);
        if (PyUnicode_Check(o)) {
          /* There's no way to preserve constness in GSList items. */
          arg2 = g_slist_prepend(arg2, (char*)PyUnicode_AsUTF8(PyList_GetItem(swig_obj[1], i)));
        } else {
          PyErr_SetString(PyExc_TypeError, "list must contain strings");
          g_slist_free(arg2);
          return NULL;
        }
      }
    } else {
      PyErr_SetString(PyExc_TypeError, "not a list");
      return NULL;
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "qof_query_add_guid_list_match" "', argument " "3"" of type '" "GList *""'"); 
  }
  arg3 = (GList *)(argp3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "qof_query_add_guid_list_match" "', argument " "4"" of type '" "QofGuidMatch""'");
  } 
  arg4 = (QofGuidMatch)(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "qof_query_add_guid_list_match" "', argument " "5"" of type '" "QofQueryOp""'");
  } 
  arg5 = (QofQueryOp)(val5);
  qof_query_add_guid_list_match(arg1,arg2,arg3,arg4,arg5);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_add_boolean_match(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQueryParamList *arg2 = (QofQueryParamList *) 0 ;
  gboolean arg3 ;
  QofQueryOp arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_add_boolean_match", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_add_boolean_match" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  {
    arg2 = NULL;
    /* Check if is a list */
    if (PyList_Check(swig_obj[1])) {
      int i;
      int size = PyList_Size(swig_obj[1]);
      for (i = size-1; i >= 0; i--) {
        PyObject *o = PyList_GetItem(swig_obj[1], i);
        if (PyUnicode_Check(o)) {
          /* There's no way to preserve constness in GSList items. */
          arg2 = g_slist_prepend(arg2, (char*)PyUnicode_AsUTF8(PyList_GetItem(swig_obj[1], i)));
        } else {
          PyErr_SetString(PyExc_TypeError, "list must contain strings");
          g_slist_free(arg2);
          return NULL;
        }
      }
    } else {
      PyErr_SetString(PyExc_TypeError, "not a list");
      return NULL;
    }
  }
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "qof_query_add_boolean_match" "', argument " "4"" of type '" "QofQueryOp""'");
  } 
  arg4 = (QofQueryOp)(val4);
  qof_query_add_boolean_match(arg1,arg2,arg3,arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_run(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_run" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  result = (GList *)qof_query_run(arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_last_run(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_last_run" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  result = (GList *)qof_query_last_run(arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_run_subquery(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQuery *arg2 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_run_subquery", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_run_subquery" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_query_run_subquery" "', argument " "2"" of type '" "QofQuery const *""'"); 
  }
  arg2 = (QofQuery *)(argp2);
  result = (GList *)qof_query_run_subquery(arg1,(struct _QofQuery const *)arg2);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_clear(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_clear" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  qof_query_clear(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_purge_terms(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQueryParamList *arg2 = (QofQueryParamList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_purge_terms", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_purge_terms" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  {
    arg2 = NULL;
    /* Check if is a list */
    if (PyList_Check(swig_obj[1])) {
      int i;
      int size = PyList_Size(swig_obj[1]);
      for (i = size-1; i >= 0; i--) {
        PyObject *o = PyList_GetItem(swig_obj[1], i);
        if (PyUnicode_Check(o)) {
          /* There's no way to preserve constness in GSList items. */
          arg2 = g_slist_prepend(arg2, (char*)PyUnicode_AsUTF8(PyList_GetItem(swig_obj[1], i)));
        } else {
          PyErr_SetString(PyExc_TypeError, "list must contain strings");
          g_slist_free(arg2);
          return NULL;
        }
      }
    } else {
      PyErr_SetString(PyExc_TypeError, "not a list");
      return NULL;
    }
  }
  qof_query_purge_terms(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_has_terms(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  int result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_has_terms" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  result = (int)qof_query_has_terms(arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_num_terms(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  int result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_num_terms" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  result = (int)qof_query_num_terms(arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_has_term_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQueryParamList *arg2 = (QofQueryParamList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_has_term_type", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_has_term_type" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  {
    arg2 = NULL;
    /* Check if is a list */
    if (PyList_Check(swig_obj[1])) {
      int i;
      int size = PyList_Size(swig_obj[1]);
      for (i = size-1; i >= 0; i--) {
        PyObject *o = PyList_GetItem(swig_obj[1], i);
        if (PyUnicode_Check(o)) {
          /* There's no way to preserve constness in GSList items. */
          arg2 = g_slist_prepend(arg2, (char*)PyUnicode_AsUTF8(PyList_GetItem(swig_obj[1], i)));
        } else {
          PyErr_SetString(PyExc_TypeError, "list must contain strings");
          g_slist_free(arg2);
          return NULL;
        }
      }
    } else {
      PyErr_SetString(PyExc_TypeError, "not a list");
      return NULL;
    }
  }
  result = qof_query_has_term_type(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_get_term_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQueryParamList *arg2 = (QofQueryParamList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  GSList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_get_term_type", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_get_term_type" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  {
    arg2 = NULL;
    /* Check if is a list */
    if (PyList_Check(swig_obj[1])) {
      int i;
      int size = PyList_Size(swig_obj[1]);
      for (i = size-1; i >= 0; i--) {
        PyObject *o = PyList_GetItem(swig_obj[1], i);
        if (PyUnicode_Check(o)) {
          /* There's no way to preserve constness in GSList items. */
          arg2 = g_slist_prepend(arg2, (char*)PyUnicode_AsUTF8(PyList_GetItem(swig_obj[1], i)));
        } else {
          PyErr_SetString(PyExc_TypeError, "list must contain strings");
          g_slist_free(arg2);
          return NULL;
        }
      }
    } else {
      PyErr_SetString(PyExc_TypeError, "not a list");
      return NULL;
    }
  }
  result = (GSList *)qof_query_get_term_type(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GSList, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_copy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofQuery *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_copy" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  result = (QofQuery *)qof_query_copy(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQuery, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_invert(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofQuery *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_invert" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  result = (QofQuery *)qof_query_invert(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQuery, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_merge(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQuery *arg2 = (QofQuery *) 0 ;
  QofQueryOp arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  QofQuery *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_merge", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_merge" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_query_merge" "', argument " "2"" of type '" "QofQuery *""'"); 
  }
  arg2 = (QofQuery *)(argp2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "qof_query_merge" "', argument " "3"" of type '" "QofQueryOp""'");
  } 
  arg3 = (QofQueryOp)(val3);
  result = (QofQuery *)qof_query_merge(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQuery, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_merge_in_place(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQuery *arg2 = (QofQuery *) 0 ;
  QofQueryOp arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_merge_in_place", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_merge_in_place" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_query_merge_in_place" "', argument " "2"" of type '" "QofQuery *""'"); 
  }
  arg2 = (QofQuery *)(argp2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "qof_query_merge_in_place" "', argument " "3"" of type '" "QofQueryOp""'");
  } 
  arg3 = (QofQueryOp)(val3);
  qof_query_merge_in_place(arg1,arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_set_sort_order(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQueryParamList *arg2 = (QofQueryParamList *) 0 ;
  QofQueryParamList *arg3 = (QofQueryParamList *) 0 ;
  QofQueryParamList *arg4 = (QofQueryParamList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[4] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_set_sort_order", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_set_sort_order" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  {
    arg2 = NULL;
    /* Check if is a list */
    if (PyList_Check(swig_obj[1])) {
      int i;
      int size = PyList_Size(swig_obj[1]);
      for (i = size-1; i >= 0; i--) {
        PyObject *o = PyList_GetItem(swig_obj[1], i);
        if (PyUnicode_Check(o)) {
          /* There's no way to preserve constness in GSList items. */
          arg2 = g_slist_prepend(arg2, (char*)PyUnicode_AsUTF8(PyList_GetItem(swig_obj[1], i)));
        } else {
          PyErr_SetString(PyExc_TypeError, "list must contain strings");
          g_slist_free(arg2);
          return NULL;
        }
      }
    } else {
      PyErr_SetString(PyExc_TypeError, "not a list");
      return NULL;
    }
  }
  {
    arg3 = NULL;
    /* Check if is a list */
    if (PyList_Check(swig_obj[2])) {
      int i;
      int size = PyList_Size(swig_obj[2]);
      for (i = size-1; i >= 0; i--) {
        PyObject *o = PyList_GetItem(swig_obj[2], i);
        if (PyUnicode_Check(o)) {
          /* There's no way to preserve constness in GSList items. */
          arg3 = g_slist_prepend(arg3, (char*)PyUnicode_AsUTF8(PyList_GetItem(swig_obj[2], i)));
        } else {
          PyErr_SetString(PyExc_TypeError, "list must contain strings");
          g_slist_free(arg3);
          return NULL;
        }
      }
    } else {
      PyErr_SetString(PyExc_TypeError, "not a list");
      return NULL;
    }
  }
  {
    arg4 = NULL;
    /* Check if is a list */
    if (PyList_Check(swig_obj[3])) {
      int i;
      int size = PyList_Size(swig_obj[3]);
      for (i = size-1; i >= 0; i--) {
        PyObject *o = PyList_GetItem(swig_obj[3], i);
        if (PyUnicode_Check(o)) {
          /* There's no way to preserve constness in GSList items. */
          arg4 = g_slist_prepend(arg4, (char*)PyUnicode_AsUTF8(PyList_GetItem(swig_obj[3], i)));
        } else {
          PyErr_SetString(PyExc_TypeError, "list must contain strings");
          g_slist_free(arg4);
          return NULL;
        }
      }
    } else {
      PyErr_SetString(PyExc_TypeError, "not a list");
      return NULL;
    }
  }
  qof_query_set_sort_order(arg1,arg2,arg3,arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_set_sort_options(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  gint arg2 ;
  gint arg3 ;
  gint arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_set_sort_options", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_set_sort_options" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "qof_query_set_sort_options" "', argument " "2"" of type '" "gint""'");
  } 
  arg2 = (gint)(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "qof_query_set_sort_options" "', argument " "3"" of type '" "gint""'");
  } 
  arg3 = (gint)(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "qof_query_set_sort_options" "', argument " "4"" of type '" "gint""'");
  } 
  arg4 = (gint)(val4);
  qof_query_set_sort_options(arg1,arg2,arg3,arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_set_sort_increasing(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  gboolean arg2 ;
  gboolean arg3 ;
  gboolean arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[4] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_set_sort_increasing", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_set_sort_increasing" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  qof_query_set_sort_increasing(arg1,arg2,arg3,arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_set_max_results(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_set_max_results", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_set_max_results" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "qof_query_set_max_results" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  qof_query_set_max_results(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_equal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  QofQuery *arg2 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_equal", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_equal" "', argument " "1"" of type '" "QofQuery const *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_query_equal" "', argument " "2"" of type '" "QofQuery const *""'"); 
  }
  arg2 = (QofQuery *)(argp2);
  result = qof_query_equal((struct _QofQuery const *)arg1,(struct _QofQuery const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_print(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_print" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  qof_query_print(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_get_search_for(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofIdType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_get_search_for" "', argument " "1"" of type '" "QofQuery const *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  result = (QofIdType)qof_query_get_search_for((struct _QofQuery const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_get_books(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQuery *arg1 = (QofQuery *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQuery, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_get_books" "', argument " "1"" of type '" "QofQuery *""'"); 
  }
  arg1 = (QofQuery *)(argp1);
  result = (GList *)qof_query_get_books(arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__QofQueryPredData_type_name_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _QofQueryPredData *arg1 = (struct _QofQueryPredData *) 0 ;
  QofType arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "_QofQueryPredData_type_name_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_QofQueryPredData_type_name_set" "', argument " "1"" of type '" "struct _QofQueryPredData *""'"); 
  }
  arg1 = (struct _QofQueryPredData *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_QofType,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_QofQueryPredData_type_name_set" "', argument " "2"" of type '" "QofType""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "_QofQueryPredData_type_name_set" "', argument " "2"" of type '" "QofType""'");
    } else {
      arg2 = *((QofType *)(argp2));
    }
  }
  if (arg1) (arg1)->type_name = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__QofQueryPredData_type_name_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _QofQueryPredData *arg1 = (struct _QofQueryPredData *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_QofQueryPredData_type_name_get" "', argument " "1"" of type '" "struct _QofQueryPredData *""'"); 
  }
  arg1 = (struct _QofQueryPredData *)(argp1);
  result =  ((arg1)->type_name);
  resultobj = SWIG_NewPointerObj((QofType *)memcpy((QofType *)calloc(1,sizeof(QofType)),&result,sizeof(QofType)), SWIGTYPE_p_QofType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__QofQueryPredData_how_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _QofQueryPredData *arg1 = (struct _QofQueryPredData *) 0 ;
  QofQueryCompare arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "_QofQueryPredData_how_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_QofQueryPredData_how_set" "', argument " "1"" of type '" "struct _QofQueryPredData *""'"); 
  }
  arg1 = (struct _QofQueryPredData *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_QofQueryPredData_how_set" "', argument " "2"" of type '" "QofQueryCompare""'");
  } 
  arg2 = (QofQueryCompare)(val2);
  if (arg1) (arg1)->how = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__QofQueryPredData_how_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _QofQueryPredData *arg1 = (struct _QofQueryPredData *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofQueryCompare result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_QofQueryPredData_how_get" "', argument " "1"" of type '" "struct _QofQueryPredData *""'"); 
  }
  arg1 = (struct _QofQueryPredData *)(argp1);
  result = (QofQueryCompare) ((arg1)->how);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__QofQueryPredData(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "new__QofQueryPredData", 0, 0, 0)) SWIG_fail;
  result = (struct _QofQueryPredData *)calloc(1, sizeof(struct _QofQueryPredData));
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__QofQueryPredData(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _QofQueryPredData *arg1 = (struct _QofQueryPredData *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQueryPredData, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__QofQueryPredData" "', argument " "1"" of type '" "struct _QofQueryPredData *""'"); 
  }
  arg1 = (struct _QofQueryPredData *)(argp1);
  free((char *) arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_QofQueryPredData_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__QofQueryPredData, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_QofQueryPredData_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_qof_query_string_predicate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQueryCompare arg1 ;
  gchar *arg2 = (gchar *) 0 ;
  QofStringMatch arg3 ;
  gboolean arg4 ;
  int val1 ;
  int ecode1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[4] ;
  QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_string_predicate", 4, 4, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "qof_query_string_predicate" "', argument " "1"" of type '" "QofQueryCompare""'");
  } 
  arg1 = (QofQueryCompare)(val1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_query_string_predicate" "', argument " "2"" of type '" "gchar const *""'");
  }
  arg2 = (gchar *)(buf2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "qof_query_string_predicate" "', argument " "3"" of type '" "QofStringMatch""'");
  } 
  arg3 = (QofStringMatch)(val3);
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = (QofQueryPredData *)qof_query_string_predicate(arg1,(gchar const *)arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_date_predicate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQueryCompare arg1 ;
  QofDateMatch arg2 ;
  time64 arg3 ;
  int val1 ;
  int ecode1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[3] ;
  QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_date_predicate", 3, 3, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "qof_query_date_predicate" "', argument " "1"" of type '" "QofQueryCompare""'");
  } 
  arg1 = (QofQueryCompare)(val1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "qof_query_date_predicate" "', argument " "2"" of type '" "QofDateMatch""'");
  } 
  arg2 = (QofDateMatch)(val2);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[2]) && !PyInt_Check(swig_obj[2])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[2])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[2]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[2]),
        PyDateTime_DATE_GET_HOUR(swig_obj[2]),
        PyDateTime_GET_DAY(swig_obj[2]),
        PyDateTime_GET_MONTH(swig_obj[2]) - 1,
        PyDateTime_GET_YEAR(swig_obj[2]) - 1900
      };
      arg3 = gnc_mktime(&time);
    } else {
      arg3 = PyInt_AsLong(swig_obj[2]);
    }
  }
  result = (QofQueryPredData *)qof_query_date_predicate(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_numeric_predicate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQueryCompare arg1 ;
  QofNumericMatch arg2 ;
  gnc_numeric arg3 ;
  int val1 ;
  int ecode1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_numeric_predicate", 3, 3, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "qof_query_numeric_predicate" "', argument " "1"" of type '" "QofQueryCompare""'");
  } 
  arg1 = (QofQueryCompare)(val1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "qof_query_numeric_predicate" "', argument " "2"" of type '" "QofNumericMatch""'");
  } 
  arg2 = (QofNumericMatch)(val2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "qof_query_numeric_predicate" "', argument " "3"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "qof_query_numeric_predicate" "', argument " "3"" of type '" "gnc_numeric""'");
    } else {
      arg3 = *((gnc_numeric *)(argp3));
    }
  }
  result = (QofQueryPredData *)qof_query_numeric_predicate(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_guid_predicate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofGuidMatch arg1 ;
  GList *arg2 = (GList *) 0 ;
  int val1 ;
  int ecode1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_guid_predicate", 2, 2, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "qof_query_guid_predicate" "', argument " "1"" of type '" "QofGuidMatch""'");
  } 
  arg1 = (QofGuidMatch)(val1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_query_guid_predicate" "', argument " "2"" of type '" "GList *""'"); 
  }
  arg2 = (GList *)(argp2);
  result = (QofQueryPredData *)qof_query_guid_predicate(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_int32_predicate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQueryCompare arg1 ;
  gint32 arg2 ;
  int val1 ;
  int ecode1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_int32_predicate", 2, 2, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "qof_query_int32_predicate" "', argument " "1"" of type '" "QofQueryCompare""'");
  } 
  arg1 = (QofQueryCompare)(val1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "qof_query_int32_predicate" "', argument " "2"" of type '" "gint32""'");
  } 
  arg2 = (gint32)(val2);
  result = (QofQueryPredData *)qof_query_int32_predicate(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_int64_predicate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQueryCompare arg1 ;
  gint64 arg2 ;
  int val1 ;
  int ecode1 = 0 ;
  long long val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_int64_predicate", 2, 2, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "qof_query_int64_predicate" "', argument " "1"" of type '" "QofQueryCompare""'");
  } 
  arg1 = (QofQueryCompare)(val1);
  ecode2 = SWIG_AsVal_long_SS_long(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "qof_query_int64_predicate" "', argument " "2"" of type '" "gint64""'");
  } 
  arg2 = (gint64)(val2);
  result = (QofQueryPredData *)qof_query_int64_predicate(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_double_predicate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQueryCompare arg1 ;
  double arg2 ;
  int val1 ;
  int ecode1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_double_predicate", 2, 2, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "qof_query_double_predicate" "', argument " "1"" of type '" "QofQueryCompare""'");
  } 
  arg1 = (QofQueryCompare)(val1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "qof_query_double_predicate" "', argument " "2"" of type '" "double""'");
  } 
  arg2 = (double)(val2);
  result = (QofQueryPredData *)qof_query_double_predicate(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_boolean_predicate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQueryCompare arg1 ;
  gboolean arg2 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[2] ;
  QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_boolean_predicate", 2, 2, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "qof_query_boolean_predicate" "', argument " "1"" of type '" "QofQueryCompare""'");
  } 
  arg1 = (QofQueryCompare)(val1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = (QofQueryPredData *)qof_query_boolean_predicate(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_char_predicate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCharMatch arg1 ;
  gchar *arg2 = (gchar *) 0 ;
  int val1 ;
  int ecode1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_char_predicate", 2, 2, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "qof_query_char_predicate" "', argument " "1"" of type '" "QofCharMatch""'");
  } 
  arg1 = (QofCharMatch)(val1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_query_char_predicate" "', argument " "2"" of type '" "gchar const *""'");
  }
  arg2 = (gchar *)(buf2);
  result = (QofQueryPredData *)qof_query_char_predicate(arg1,(gchar const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_collect_predicate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofGuidMatch arg1 ;
  QofCollection *arg2 = (QofCollection *) 0 ;
  int val1 ;
  int ecode1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_collect_predicate", 2, 2, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "qof_query_collect_predicate" "', argument " "1"" of type '" "QofGuidMatch""'");
  } 
  arg1 = (QofGuidMatch)(val1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_query_collect_predicate" "', argument " "2"" of type '" "QofCollection *""'"); 
  }
  arg2 = (QofCollection *)(argp2);
  result = (QofQueryPredData *)qof_query_collect_predicate(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_choice_predicate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofGuidMatch arg1 ;
  GList *arg2 = (GList *) 0 ;
  int val1 ;
  int ecode1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  QofQueryPredData *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_choice_predicate", 2, 2, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "qof_query_choice_predicate" "', argument " "1"" of type '" "QofGuidMatch""'");
  } 
  arg1 = (QofGuidMatch)(val1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_query_choice_predicate" "', argument " "2"" of type '" "GList *""'"); 
  }
  arg2 = (GList *)(argp2);
  result = (QofQueryPredData *)qof_query_choice_predicate(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_core_predicate_copy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQueryPredData *arg1 = (QofQueryPredData *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofQueryPredData *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_core_predicate_copy" "', argument " "1"" of type '" "QofQueryPredData const *""'"); 
  }
  arg1 = (QofQueryPredData *)(argp1);
  result = (QofQueryPredData *)qof_query_core_predicate_copy((struct _QofQueryPredData const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_core_predicate_free(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQueryPredData *arg1 = (QofQueryPredData *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_core_predicate_free" "', argument " "1"" of type '" "QofQueryPredData *""'"); 
  }
  arg1 = (QofQueryPredData *)(argp1);
  qof_query_core_predicate_free(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_date_predicate_get_date(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofQueryPredData *arg1 = (QofQueryPredData *) 0 ;
  time64 *arg2 = (time64 *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  time64 secs2 ;
  time64 secs20 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  {
    arg2 = &secs2;
  }
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__QofQueryPredData, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_date_predicate_get_date" "', argument " "1"" of type '" "QofQueryPredData const *""'"); 
  }
  arg1 = (QofQueryPredData *)(argp1);
  result = qof_query_date_predicate_get_date((struct _QofQueryPredData const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  {
    PyDateTime_IMPORT;
    PyObject *tp;
    struct tm t;
    
    // directly access return value (result) of function
    // only return datetime if TRUE
    if(result) {
      gnc_localtime_r(arg2, &t);
      tp = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
      
      resultobj = SWIG_Python_AppendOutput(resultobj, tp);
    } else resultobj = SWIG_Python_AppendOutput(resultobj, Py_None);
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_query_core_to_string(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofType arg1 ;
  gpointer arg2 = (gpointer) 0 ;
  QofParam *arg3 = (QofParam *) 0 ;
  void *argp1 ;
  int res1 = 0 ;
  int res2 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  char *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_query_core_to_string", 3, 3, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_QofType,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_query_core_to_string" "', argument " "1"" of type '" "QofType""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "qof_query_core_to_string" "', argument " "1"" of type '" "QofType""'");
    } else {
      arg1 = *((QofType *)(argp1));
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1],SWIG_as_voidptrptr(&arg2), 0, 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_query_core_to_string" "', argument " "2"" of type '" "gpointer""'"); 
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_QofParam, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "qof_query_core_to_string" "', argument " "3"" of type '" "QofParam *""'"); 
  }
  arg3 = (QofParam *)(argp3);
  result = (char *)qof_query_core_to_string(arg1,arg2,arg3);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qof_string_number_compare_func(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gpointer arg1 = (gpointer) 0 ;
  gpointer arg2 = (gpointer) 0 ;
  gint arg3 ;
  QofParam *arg4 = (QofParam *) 0 ;
  int res1 ;
  int res2 ;
  int val3 ;
  int ecode3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  PyObject *swig_obj[4] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "qof_string_number_compare_func", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0],SWIG_as_voidptrptr(&arg1), 0, 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qof_string_number_compare_func" "', argument " "1"" of type '" "gpointer""'"); 
  }
  res2 = SWIG_ConvertPtr(swig_obj[1],SWIG_as_voidptrptr(&arg2), 0, 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qof_string_number_compare_func" "', argument " "2"" of type '" "gpointer""'"); 
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "qof_string_number_compare_func" "', argument " "3"" of type '" "gint""'");
  } 
  arg3 = (gint)(val3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p_QofParam, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "qof_string_number_compare_func" "', argument " "4"" of type '" "QofParam *""'"); 
  }
  arg4 = (QofParam *)(argp4);
  result = (int)qof_string_number_compare_func(arg1,arg2,arg3,arg4);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncGUID_reserved_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gncGuid *arg1 = (struct _gncGuid *) 0 ;
  unsigned char *arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "GncGUID_reserved_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncGUID_reserved_set" "', argument " "1"" of type '" "struct _gncGuid *""'"); 
  }
  arg1 = (struct _gncGuid *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_unsigned_char, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "GncGUID_reserved_set" "', argument " "2"" of type '" "unsigned char [16]""'"); 
  } 
  arg2 = (unsigned char *)(argp2);
  {
    if (arg2) {
      size_t ii = 0;
      for (; ii < (size_t)16; ++ii) *(unsigned char *)&arg1->reserved[ii] = *((unsigned char *)arg2 + ii);
    } else {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in variable '""reserved""' of type '""unsigned char [16]""'");
    }
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_GncGUID_reserved_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gncGuid *arg1 = (struct _gncGuid *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  unsigned char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GncGUID_reserved_get" "', argument " "1"" of type '" "struct _gncGuid *""'"); 
  }
  arg1 = (struct _gncGuid *)(argp1);
  result = (unsigned char *)(unsigned char *) ((arg1)->reserved);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_unsigned_char, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_GncGUID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gncGuid *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "new_GncGUID", 0, 0, 0)) SWIG_fail;
  result = (struct _gncGuid *)calloc(1, sizeof(struct _gncGuid));
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_GncGUID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gncGuid *arg1 = (struct _gncGuid *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_GncGUID" "', argument " "1"" of type '" "struct _gncGuid *""'"); 
  }
  arg1 = (struct _gncGuid *)(argp1);
  free((char *) arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *GncGUID_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gncGuid, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *GncGUID_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_gnc_guid_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_guid_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_guid_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_value_get_guid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GValue *arg1 = (GValue *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncGUID *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_value_get_guid" "', argument " "1"" of type '" "GValue const *""'"); 
  }
  arg1 = (GValue *)(argp1);
  result = (GncGUID *)gnc_value_get_guid((GValue const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_replace(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "guid_replace" "', argument " "1"" of type '" "GncGUID *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  guid_replace(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_new_return(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID result;
  
  if (!SWIG_Python_UnpackTuple(args, "guid_new_return", 0, 0, 0)) SWIG_fail;
  result = guid_new_return();
  resultobj = SWIG_NewPointerObj((GncGUID *)memcpy((GncGUID *)calloc(1,sizeof(GncGUID)),&result,sizeof(GncGUID)), SWIGTYPE_p__gncGuid, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_null(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "guid_null", 0, 0, 0)) SWIG_fail;
  result = (GncGUID *)guid_null();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_malloc(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "guid_malloc", 0, 0, 0)) SWIG_fail;
  result = (GncGUID *)guid_malloc();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_new(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "guid_new", 0, 0, 0)) SWIG_fail;
  result = (GncGUID *)guid_new();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_free(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "guid_free" "', argument " "1"" of type '" "GncGUID *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  guid_free(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_copy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncGUID *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "guid_copy" "', argument " "1"" of type '" "GncGUID const *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  result = (GncGUID *)guid_copy((struct _gncGuid const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_to_string(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gchar *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "guid_to_string" "', argument " "1"" of type '" "GncGUID const *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  result = (gchar *)guid_to_string((struct _gncGuid const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_to_string_buff(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  gchar *arg2 = (gchar *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  gchar *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "guid_to_string_buff", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "guid_to_string_buff" "', argument " "1"" of type '" "GncGUID const *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "guid_to_string_buff" "', argument " "2"" of type '" "gchar *""'");
  }
  arg2 = (gchar *)(buf2);
  result = (gchar *)guid_to_string_buff((struct _gncGuid const *)arg1,arg2);
  resultobj = SWIG_FromCharPtr((const char *)result);
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_string_to_guid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gchar *arg1 = (gchar *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "string_to_guid", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "string_to_guid" "', argument " "1"" of type '" "gchar const *""'");
  }
  arg1 = (gchar *)(buf1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "string_to_guid" "', argument " "2"" of type '" "GncGUID *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = string_to_guid((gchar const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_equal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "guid_equal", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "guid_equal" "', argument " "1"" of type '" "GncGUID const *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "guid_equal" "', argument " "2"" of type '" "GncGUID const *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = guid_equal((struct _gncGuid const *)arg1,(struct _gncGuid const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_compare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gint result;
  
  if (!SWIG_Python_UnpackTuple(args, "guid_compare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "guid_compare" "', argument " "1"" of type '" "GncGUID const *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "guid_compare" "', argument " "2"" of type '" "GncGUID const *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = guid_compare((struct _gncGuid const *)arg1,(struct _gncGuid const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_hash_to_guint(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gconstpointer arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  guint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_gconstpointer,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "guid_hash_to_guint" "', argument " "1"" of type '" "gconstpointer""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "guid_hash_to_guint" "', argument " "1"" of type '" "gconstpointer""'");
    } else {
      arg1 = *((gconstpointer *)(argp1));
    }
  }
  result = guid_hash_to_guint(arg1);
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_g_hash_table_equal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gconstpointer arg1 ;
  gconstpointer arg2 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gint result;
  
  if (!SWIG_Python_UnpackTuple(args, "guid_g_hash_table_equal", 2, 2, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_gconstpointer,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "guid_g_hash_table_equal" "', argument " "1"" of type '" "gconstpointer""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "guid_g_hash_table_equal" "', argument " "1"" of type '" "gconstpointer""'");
    } else {
      arg1 = *((gconstpointer *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_gconstpointer,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "guid_g_hash_table_equal" "', argument " "2"" of type '" "gconstpointer""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "guid_g_hash_table_equal" "', argument " "2"" of type '" "gconstpointer""'");
    } else {
      arg2 = *((gconstpointer *)(argp2));
    }
  }
  result = guid_g_hash_table_equal(arg1,arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_guid_hash_table_new(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GHashTable *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "guid_hash_table_new", 0, 0, 0)) SWIG_fail;
  result = (GHashTable *)guid_hash_table_new();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GHashTable, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gnc_numeric_num_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_numeric *arg1 = (struct _gnc_numeric *) 0 ;
  gint64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  long long val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "_gnc_numeric_num_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gnc_numeric_num_set" "', argument " "1"" of type '" "struct _gnc_numeric *""'"); 
  }
  arg1 = (struct _gnc_numeric *)(argp1);
  ecode2 = SWIG_AsVal_long_SS_long(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gnc_numeric_num_set" "', argument " "2"" of type '" "gint64""'");
  } 
  arg2 = (gint64)(val2);
  if (arg1) (arg1)->num = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gnc_numeric_num_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_numeric *arg1 = (struct _gnc_numeric *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gnc_numeric_num_get" "', argument " "1"" of type '" "struct _gnc_numeric *""'"); 
  }
  arg1 = (struct _gnc_numeric *)(argp1);
  result =  ((arg1)->num);
  resultobj = SWIG_From_long_SS_long((long long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gnc_numeric_denom_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_numeric *arg1 = (struct _gnc_numeric *) 0 ;
  gint64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  long long val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "_gnc_numeric_denom_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gnc_numeric_denom_set" "', argument " "1"" of type '" "struct _gnc_numeric *""'"); 
  }
  arg1 = (struct _gnc_numeric *)(argp1);
  ecode2 = SWIG_AsVal_long_SS_long(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "_gnc_numeric_denom_set" "', argument " "2"" of type '" "gint64""'");
  } 
  arg2 = (gint64)(val2);
  if (arg1) (arg1)->denom = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gnc_numeric_denom_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_numeric *arg1 = (struct _gnc_numeric *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gnc_numeric_denom_get" "', argument " "1"" of type '" "struct _gnc_numeric *""'"); 
  }
  arg1 = (struct _gnc_numeric *)(argp1);
  result =  ((arg1)->denom);
  resultobj = SWIG_From_long_SS_long((long long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gnc_numeric(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_numeric *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "new__gnc_numeric", 0, 0, 0)) SWIG_fail;
  result = (struct _gnc_numeric *)calloc(1, sizeof(struct _gnc_numeric));
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gnc_numeric(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_numeric *arg1 = (struct _gnc_numeric *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gnc_numeric, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gnc_numeric" "', argument " "1"" of type '" "struct _gnc_numeric *""'"); 
  }
  arg1 = (struct _gnc_numeric *)(argp1);
  free((char *) arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gnc_numeric_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gnc_numeric, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_gnc_numeric_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_gnc_numeric_create(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gint64 arg1 ;
  gint64 arg2 ;
  long long val1 ;
  int ecode1 = 0 ;
  long long val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_create", 2, 2, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_long_SS_long(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gnc_numeric_create" "', argument " "1"" of type '" "gint64""'");
  } 
  arg1 = (gint64)(val1);
  ecode2 = SWIG_AsVal_long_SS_long(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gnc_numeric_create" "', argument " "2"" of type '" "gint64""'");
  } 
  arg2 = (gint64)(val2);
  result = gnc_numeric_create(arg1,arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_zero(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_zero", 0, 0, 0)) SWIG_fail;
  result = gnc_numeric_zero();
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_double_to_gnc_numeric(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  double arg1 ;
  gint64 arg2 ;
  gint arg3 ;
  double val1 ;
  int ecode1 = 0 ;
  long long val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "double_to_gnc_numeric", 3, 3, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_double(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "double_to_gnc_numeric" "', argument " "1"" of type '" "double""'");
  } 
  arg1 = (double)(val1);
  ecode2 = SWIG_AsVal_long_SS_long(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "double_to_gnc_numeric" "', argument " "2"" of type '" "gint64""'");
  } 
  arg2 = (gint64)(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "double_to_gnc_numeric" "', argument " "3"" of type '" "gint""'");
  } 
  arg3 = (gint)(val3);
  result = double_to_gnc_numeric(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_string_to_gnc_numeric(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gchar *arg1 = (gchar *) 0 ;
  gnc_numeric *arg2 = (gnc_numeric *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "string_to_gnc_numeric", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "string_to_gnc_numeric" "', argument " "1"" of type '" "gchar const *""'");
  }
  arg1 = (gchar *)(buf1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "string_to_gnc_numeric" "', argument " "2"" of type '" "gnc_numeric *""'"); 
  }
  arg2 = (gnc_numeric *)(argp2);
  result = string_to_gnc_numeric((gchar const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_error(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCNumericErrorCode arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gnc_numeric_error" "', argument " "1"" of type '" "GNCNumericErrorCode""'");
  } 
  arg1 = (GNCNumericErrorCode)(val1);
  result = gnc_numeric_error(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_errorCode_to_string(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCNumericErrorCode arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gnc_numeric_errorCode_to_string" "', argument " "1"" of type '" "GNCNumericErrorCode""'");
  } 
  arg1 = (GNCNumericErrorCode)(val1);
  result = (char *)gnc_numeric_errorCode_to_string(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_num(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_num" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_num" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = gnc_numeric_num(arg1);
  resultobj = SWIG_From_long_SS_long((long long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_denom(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_denom" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_denom" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = gnc_numeric_denom(arg1);
  resultobj = SWIG_From_long_SS_long((long long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_to_double(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gdouble result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_to_double" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_to_double" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = gnc_numeric_to_double(arg1);
  resultobj = SWIG_From_double((double)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_to_string(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gchar *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_to_string" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_to_string" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = (gchar *)gnc_numeric_to_string(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_num_dbg_to_string(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gchar *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_num_dbg_to_string" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_num_dbg_to_string" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = (gchar *)gnc_num_dbg_to_string(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_check(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCNumericErrorCode result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_check" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_check" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = (GNCNumericErrorCode)gnc_numeric_check(arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_compare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gnc_numeric arg2 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gint result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_compare", 2, 2, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_compare" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_compare" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_numeric_compare" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_compare" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  result = gnc_numeric_compare(arg1,arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_zero_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_zero_p" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_zero_p" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = gnc_numeric_zero_p(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_negative_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_negative_p" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_negative_p" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = gnc_numeric_negative_p(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_positive_p(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_positive_p" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_positive_p" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = gnc_numeric_positive_p(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_eq(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gnc_numeric arg2 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_eq", 2, 2, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_eq" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_eq" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_numeric_eq" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_eq" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  result = gnc_numeric_eq(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_equal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gnc_numeric arg2 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_equal", 2, 2, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_equal" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_equal" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_numeric_equal" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_equal" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  result = gnc_numeric_equal(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_same(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gnc_numeric arg2 ;
  gint64 arg3 ;
  gint arg4 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  long long val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  gint result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_same", 4, 4, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_same" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_same" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_numeric_same" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_same" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  ecode3 = SWIG_AsVal_long_SS_long(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gnc_numeric_same" "', argument " "3"" of type '" "gint64""'");
  } 
  arg3 = (gint64)(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gnc_numeric_same" "', argument " "4"" of type '" "gint""'");
  } 
  arg4 = (gint)(val4);
  result = gnc_numeric_same(arg1,arg2,arg3,arg4);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_add(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gnc_numeric arg2 ;
  gint64 arg3 ;
  gint arg4 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  long long val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_add", 4, 4, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_add" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_add" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_numeric_add" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_add" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  ecode3 = SWIG_AsVal_long_SS_long(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gnc_numeric_add" "', argument " "3"" of type '" "gint64""'");
  } 
  arg3 = (gint64)(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gnc_numeric_add" "', argument " "4"" of type '" "gint""'");
  } 
  arg4 = (gint)(val4);
  result = gnc_numeric_add(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_sub(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gnc_numeric arg2 ;
  gint64 arg3 ;
  gint arg4 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  long long val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_sub", 4, 4, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_sub" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_sub" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_numeric_sub" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_sub" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  ecode3 = SWIG_AsVal_long_SS_long(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gnc_numeric_sub" "', argument " "3"" of type '" "gint64""'");
  } 
  arg3 = (gint64)(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gnc_numeric_sub" "', argument " "4"" of type '" "gint""'");
  } 
  arg4 = (gint)(val4);
  result = gnc_numeric_sub(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_mul(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gnc_numeric arg2 ;
  gint64 arg3 ;
  gint arg4 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  long long val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_mul", 4, 4, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_mul" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_mul" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_numeric_mul" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_mul" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  ecode3 = SWIG_AsVal_long_SS_long(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gnc_numeric_mul" "', argument " "3"" of type '" "gint64""'");
  } 
  arg3 = (gint64)(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gnc_numeric_mul" "', argument " "4"" of type '" "gint""'");
  } 
  arg4 = (gint)(val4);
  result = gnc_numeric_mul(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_div(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gnc_numeric arg2 ;
  gint64 arg3 ;
  gint arg4 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  long long val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_div", 4, 4, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_div" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_div" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_numeric_div" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_div" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  ecode3 = SWIG_AsVal_long_SS_long(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gnc_numeric_div" "', argument " "3"" of type '" "gint64""'");
  } 
  arg3 = (gint64)(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "gnc_numeric_div" "', argument " "4"" of type '" "gint""'");
  } 
  arg4 = (gint)(val4);
  result = gnc_numeric_div(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_neg(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_neg" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_neg" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = gnc_numeric_neg(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_abs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_abs" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_abs" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = gnc_numeric_abs(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_add_fixed(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gnc_numeric arg2 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_add_fixed", 2, 2, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_add_fixed" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_add_fixed" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_numeric_add_fixed" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_add_fixed" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  result = gnc_numeric_add_fixed(arg1,arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_sub_fixed(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gnc_numeric arg2 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_sub_fixed", 2, 2, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_sub_fixed" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_sub_fixed" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_numeric_sub_fixed" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_sub_fixed" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  result = gnc_numeric_sub_fixed(arg1,arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_convert(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gint64 arg2 ;
  gint arg3 ;
  void *argp1 ;
  int res1 = 0 ;
  long long val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_convert", 3, 3, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_convert" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_convert" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  ecode2 = SWIG_AsVal_long_SS_long(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gnc_numeric_convert" "', argument " "2"" of type '" "gint64""'");
  } 
  arg2 = (gint64)(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gnc_numeric_convert" "', argument " "3"" of type '" "gint""'");
  } 
  arg3 = (gint)(val3);
  result = gnc_numeric_convert(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_reduce(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_reduce" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_reduce" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = gnc_numeric_reduce(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_to_decimal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric *arg1 = (gnc_numeric *) 0 ;
  guint8 *arg2 = (guint8 *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_to_decimal", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_to_decimal" "', argument " "1"" of type '" "gnc_numeric *""'"); 
  }
  arg1 = (gnc_numeric *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_guint8, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_numeric_to_decimal" "', argument " "2"" of type '" "guint8 *""'"); 
  }
  arg2 = (guint8 *)(argp2);
  result = gnc_numeric_to_decimal(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_invert(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_numeric_invert" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_numeric_invert" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  result = gnc_numeric_invert(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_numeric_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_numeric_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_numeric_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_commodity_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_namespace_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_namespace_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_commodity_namespace_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_fq_installed(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_quote_source_fq_installed", 0, 0, 0)) SWIG_fail;
  result = gnc_quote_source_fq_installed();
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_fq_version(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_quote_source_fq_version", 0, 0, 0)) SWIG_fail;
  result = (char *)gnc_quote_source_fq_version();
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_set_fq_installed(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  GList *arg2 = (GList *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_quote_source_set_fq_installed", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_quote_source_set_fq_installed" "', argument " "1"" of type '" "char const *""'");
  }
  arg1 = (char *)(buf1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_quote_source_set_fq_installed" "', argument " "2"" of type '" "GList const *""'"); 
  }
  arg2 = (GList *)(argp2);
  gnc_quote_source_set_fq_installed((char const *)arg1,(GList const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_num_entries(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QuoteSourceType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  gint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gnc_quote_source_num_entries" "', argument " "1"" of type '" "QuoteSourceType""'");
  } 
  arg1 = (QuoteSourceType)(val1);
  result = gnc_quote_source_num_entries(arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_add_new(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  gboolean arg2 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_quote_source *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_quote_source_add_new", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_quote_source_add_new" "', argument " "1"" of type '" "char const *""'");
  }
  arg1 = (char *)(buf1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = (gnc_quote_source *)gnc_quote_source_add_new((char const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_quote_source, 0 |  0 );
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_lookup_by_internal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_quote_source *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_quote_source_lookup_by_internal" "', argument " "1"" of type '" "char const *""'");
  }
  arg1 = (char *)(buf1);
  result = (gnc_quote_source *)gnc_quote_source_lookup_by_internal((char const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_quote_source, 0 |  0 );
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_lookup_by_ti(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QuoteSourceType arg1 ;
  gint arg2 ;
  int val1 ;
  int ecode1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_quote_source *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_quote_source_lookup_by_ti", 2, 2, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gnc_quote_source_lookup_by_ti" "', argument " "1"" of type '" "QuoteSourceType""'");
  } 
  arg1 = (QuoteSourceType)(val1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gnc_quote_source_lookup_by_ti" "', argument " "2"" of type '" "gint""'");
  } 
  arg2 = (gint)(val2);
  result = (gnc_quote_source *)gnc_quote_source_lookup_by_ti(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_quote_source, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_get_supported(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_quote_source *arg1 = (gnc_quote_source *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_quote_source, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_quote_source_get_supported" "', argument " "1"" of type '" "gnc_quote_source const *""'"); 
  }
  arg1 = (gnc_quote_source *)(argp1);
  result = gnc_quote_source_get_supported((gnc_quote_source const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_quote_source *arg1 = (gnc_quote_source *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QuoteSourceType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_quote_source, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_quote_source_get_type" "', argument " "1"" of type '" "gnc_quote_source const *""'"); 
  }
  arg1 = (gnc_quote_source *)(argp1);
  result = (QuoteSourceType)gnc_quote_source_get_type((gnc_quote_source const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_get_index(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_quote_source *arg1 = (gnc_quote_source *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_quote_source, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_quote_source_get_index" "', argument " "1"" of type '" "gnc_quote_source const *""'"); 
  }
  arg1 = (gnc_quote_source *)(argp1);
  result = gnc_quote_source_get_index((gnc_quote_source const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_get_user_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_quote_source *arg1 = (gnc_quote_source *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_quote_source, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_quote_source_get_user_name" "', argument " "1"" of type '" "gnc_quote_source const *""'"); 
  }
  arg1 = (gnc_quote_source *)(argp1);
  result = (char *)gnc_quote_source_get_user_name((gnc_quote_source const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_quote_source_get_internal_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_quote_source *arg1 = (gnc_quote_source *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_quote_source, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_quote_source_get_internal_name" "', argument " "1"" of type '" "gnc_quote_source const *""'"); 
  }
  arg1 = (gnc_quote_source *)(argp1);
  result = (char *)gnc_quote_source_get_internal_name((gnc_quote_source const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_new(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  char *arg4 = (char *) 0 ;
  char *arg5 = (char *) 0 ;
  int arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  int res3 ;
  char *buf3 = 0 ;
  int alloc3 = 0 ;
  int res4 ;
  char *buf4 = 0 ;
  int alloc4 = 0 ;
  int res5 ;
  char *buf5 = 0 ;
  int alloc5 = 0 ;
  int val6 ;
  int ecode6 = 0 ;
  PyObject *swig_obj[6] ;
  gnc_commodity *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_new", 6, 6, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_new" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_new" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  res3 = SWIG_AsCharPtrAndSize(swig_obj[2], &buf3, NULL, &alloc3);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_commodity_new" "', argument " "3"" of type '" "char const *""'");
  }
  arg3 = (char *)(buf3);
  res4 = SWIG_AsCharPtrAndSize(swig_obj[3], &buf4, NULL, &alloc4);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gnc_commodity_new" "', argument " "4"" of type '" "char const *""'");
  }
  arg4 = (char *)(buf4);
  res5 = SWIG_AsCharPtrAndSize(swig_obj[4], &buf5, NULL, &alloc5);
  if (!SWIG_IsOK(res5)) {
    SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "gnc_commodity_new" "', argument " "5"" of type '" "char const *""'");
  }
  arg5 = (char *)(buf5);
  ecode6 = SWIG_AsVal_int(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "gnc_commodity_new" "', argument " "6"" of type '" "int""'");
  } 
  arg6 = (int)(val6);
  result = (gnc_commodity *)gnc_commodity_new(arg1,(char const *)arg2,(char const *)arg3,(char const *)arg4,(char const *)arg5,arg6);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  if (alloc4 == SWIG_NEWOBJ) free((char*)buf4);
  if (alloc5 == SWIG_NEWOBJ) free((char*)buf5);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  if (alloc4 == SWIG_NEWOBJ) free((char*)buf4);
  if (alloc5 == SWIG_NEWOBJ) free((char*)buf5);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_destroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_destroy" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  gnc_commodity_destroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_copy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_copy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_copy" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_copy" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  gnc_commodity_copy(arg1,(gnc_commodity const *)arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_clone(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_commodity *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_clone", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_clone" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_clone" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  result = (gnc_commodity *)gnc_commodity_clone((gnc_commodity const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_mnemonic(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_mnemonic" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (char *)gnc_commodity_get_mnemonic((gnc_commodity const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_namespace(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_namespace" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (char *)gnc_commodity_get_namespace((gnc_commodity const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_namespace_ds(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity_namespace *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_namespace_ds" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (gnc_commodity_namespace *)gnc_commodity_get_namespace_ds((gnc_commodity const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity_namespace, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_fullname(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_fullname" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (char *)gnc_commodity_get_fullname((gnc_commodity const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_printname(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_printname" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (char *)gnc_commodity_get_printname((gnc_commodity const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_cusip(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_cusip" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (char *)gnc_commodity_get_cusip((gnc_commodity const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_unique_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_unique_name" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (char *)gnc_commodity_get_unique_name((gnc_commodity const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_fraction(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  int result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_fraction" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (int)gnc_commodity_get_fraction((gnc_commodity const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_quote_flag(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_quote_flag" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = gnc_commodity_get_quote_flag((gnc_commodity const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_quote_source(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_quote_source *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_quote_source" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (gnc_quote_source *)gnc_commodity_get_quote_source((gnc_commodity const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_quote_source, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_default_quote_source(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_quote_source *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_default_quote_source" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (gnc_quote_source *)gnc_commodity_get_default_quote_source((gnc_commodity const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_quote_source, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_quote_tz(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_quote_tz" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (char *)gnc_commodity_get_quote_tz((gnc_commodity const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_user_symbol(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_user_symbol" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (char *)gnc_commodity_get_user_symbol((gnc_commodity const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_default_symbol(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_default_symbol" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (char *)gnc_commodity_get_default_symbol((gnc_commodity const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_get_nice_symbol(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_get_nice_symbol" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = (char *)gnc_commodity_get_nice_symbol((gnc_commodity const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_set_mnemonic(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_set_mnemonic", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_set_mnemonic" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_set_mnemonic" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gnc_commodity_set_mnemonic(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_set_namespace(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_set_namespace", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_set_namespace" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_set_namespace" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gnc_commodity_set_namespace(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_set_fullname(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_set_fullname", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_set_fullname" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_set_fullname" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gnc_commodity_set_fullname(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_set_cusip(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_set_cusip", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_set_cusip" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_set_cusip" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gnc_commodity_set_cusip(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_set_fraction(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  int arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_set_fraction", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_set_fraction" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gnc_commodity_set_fraction" "', argument " "2"" of type '" "int""'");
  } 
  arg2 = (int)(val2);
  gnc_commodity_set_fraction(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_user_set_quote_flag(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_user_set_quote_flag", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_user_set_quote_flag" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gnc_commodity_user_set_quote_flag(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_set_quote_flag(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_set_quote_flag", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_set_quote_flag" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gnc_commodity_set_quote_flag(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_set_quote_source(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  gnc_quote_source *arg2 = (gnc_quote_source *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_set_quote_source", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_set_quote_source" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_quote_source, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_set_quote_source" "', argument " "2"" of type '" "gnc_quote_source *""'"); 
  }
  arg2 = (gnc_quote_source *)(argp2);
  gnc_commodity_set_quote_source(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_set_quote_tz(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_set_quote_tz", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_set_quote_tz" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_set_quote_tz" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gnc_commodity_set_quote_tz(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_set_user_symbol(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_set_user_symbol", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_set_user_symbol" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_set_user_symbol" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gnc_commodity_set_user_symbol(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_increment_usage_count(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_increment_usage_count" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  gnc_commodity_increment_usage_count(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_decrement_usage_count(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_decrement_usage_count" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  gnc_commodity_decrement_usage_count(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_equiv(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_equiv", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_equiv" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_equiv" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  result = gnc_commodity_equiv((gnc_commodity const *)arg1,(gnc_commodity const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_equal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_equal", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_equal" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_equal" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  result = gnc_commodity_equal((gnc_commodity const *)arg1,(gnc_commodity const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_compare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_compare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_compare" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_compare" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  result = (int)gnc_commodity_compare((gnc_commodity const *)arg1,(gnc_commodity const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_compare_void(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  void *arg1 = (void *) 0 ;
  void *arg2 = (void *) 0 ;
  int res1 ;
  int res2 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_compare_void", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0],SWIG_as_voidptrptr(&arg1), 0, 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_compare_void" "', argument " "1"" of type '" "void const *""'"); 
  }
  res2 = SWIG_ConvertPtr(swig_obj[1],SWIG_as_voidptrptr(&arg2), 0, 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_compare_void" "', argument " "2"" of type '" "void const *""'"); 
  }
  result = (int)gnc_commodity_compare_void((void const *)arg1,(void const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_namespace_is_iso(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_namespace_is_iso" "', argument " "1"" of type '" "char const *""'");
  }
  arg1 = (char *)(buf1);
  result = gnc_commodity_namespace_is_iso((char const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_is_iso(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_is_iso" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = gnc_commodity_is_iso((gnc_commodity const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_is_currency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_is_currency" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  result = gnc_commodity_is_currency((gnc_commodity const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_get_table(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity_table *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_get_table" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (gnc_commodity_table *)gnc_commodity_table_get_table(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_lookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  int res3 ;
  char *buf3 = 0 ;
  int alloc3 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_commodity *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_lookup", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_lookup" "', argument " "1"" of type '" "gnc_commodity_table const *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_table_lookup" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  res3 = SWIG_AsCharPtrAndSize(swig_obj[2], &buf3, NULL, &alloc3);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_commodity_table_lookup" "', argument " "3"" of type '" "char const *""'");
  }
  arg3 = (char *)(buf3);
  result = (gnc_commodity *)gnc_commodity_table_lookup((gnc_commodity_table const *)arg1,(char const *)arg2,(char const *)arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_lookup_unique(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_commodity *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_lookup_unique", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_lookup_unique" "', argument " "1"" of type '" "gnc_commodity_table const *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_table_lookup_unique" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (gnc_commodity *)gnc_commodity_table_lookup_unique((gnc_commodity_table const *)arg1,(char const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_find_full(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  int res3 ;
  char *buf3 = 0 ;
  int alloc3 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_commodity *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_find_full", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_find_full" "', argument " "1"" of type '" "gnc_commodity_table const *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_table_find_full" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  res3 = SWIG_AsCharPtrAndSize(swig_obj[2], &buf3, NULL, &alloc3);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_commodity_table_find_full" "', argument " "3"" of type '" "char const *""'");
  }
  arg3 = (char *)(buf3);
  result = (gnc_commodity *)gnc_commodity_table_find_full((gnc_commodity_table const *)arg1,(char const *)arg2,(char const *)arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  if (alloc3 == SWIG_NEWOBJ) free((char*)buf3);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_find_commodity_by_guid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_commodity *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_find_commodity_by_guid", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_find_commodity_by_guid" "', argument " "1"" of type '" "GncGUID const *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_find_commodity_by_guid" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  result = (gnc_commodity *)gnc_commodity_find_commodity_by_guid((struct _gncGuid const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_insert(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_commodity *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_insert", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_insert" "', argument " "1"" of type '" "gnc_commodity_table *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_table_insert" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  result = (gnc_commodity *)gnc_commodity_table_insert(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_remove(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_remove", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_remove" "', argument " "1"" of type '" "gnc_commodity_table *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_table_remove" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  gnc_commodity_table_remove(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_add_default_data(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_add_default_data", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_add_default_data" "', argument " "1"" of type '" "gnc_commodity_table *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_table_add_default_data" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  result = gnc_commodity_table_add_default_data(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_namespace_get_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_namespace *arg1 = (gnc_commodity_namespace *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_namespace, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_namespace_get_name" "', argument " "1"" of type '" "gnc_commodity_namespace const *""'"); 
  }
  arg1 = (gnc_commodity_namespace *)(argp1);
  result = (char *)gnc_commodity_namespace_get_name((gnc_commodity_namespace const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_namespace_get_gui_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_namespace *arg1 = (gnc_commodity_namespace *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_namespace, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_namespace_get_gui_name" "', argument " "1"" of type '" "gnc_commodity_namespace const *""'"); 
  }
  arg1 = (gnc_commodity_namespace *)(argp1);
  result = (char *)gnc_commodity_namespace_get_gui_name((gnc_commodity_namespace const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_namespace_get_commodity_list(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_namespace *arg1 = (gnc_commodity_namespace *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_namespace, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_namespace_get_commodity_list" "', argument " "1"" of type '" "gnc_commodity_namespace const *""'"); 
  }
  arg1 = (gnc_commodity_namespace *)(argp1);
  result = (GList *)gnc_commodity_namespace_get_commodity_list((gnc_commodity_namespace const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_has_namespace(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_has_namespace", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_has_namespace" "', argument " "1"" of type '" "gnc_commodity_table const *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_table_has_namespace" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (int)gnc_commodity_table_has_namespace((gnc_commodity_table const *)arg1,(char const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_get_namespaces(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_get_namespaces" "', argument " "1"" of type '" "gnc_commodity_table const *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  result = (GList *)gnc_commodity_table_get_namespaces((gnc_commodity_table const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_get_namespaces_list(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_get_namespaces_list" "', argument " "1"" of type '" "gnc_commodity_table const *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  result = (GList *)gnc_commodity_table_get_namespaces_list((gnc_commodity_table const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_add_namespace(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  char *arg2 = (char *) 0 ;
  QofBook *arg3 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_commodity_namespace *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_add_namespace", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_add_namespace" "', argument " "1"" of type '" "gnc_commodity_table *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_table_add_namespace" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_commodity_table_add_namespace" "', argument " "3"" of type '" "QofBook *""'"); 
  }
  arg3 = (QofBook *)(argp3);
  result = (gnc_commodity_namespace *)gnc_commodity_table_add_namespace(arg1,(char const *)arg2,arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity_namespace, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_find_namespace(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_commodity_namespace *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_find_namespace", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_find_namespace" "', argument " "1"" of type '" "gnc_commodity_table const *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_table_find_namespace" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (gnc_commodity_namespace *)gnc_commodity_table_find_namespace((gnc_commodity_table const *)arg1,(char const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity_namespace, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_delete_namespace(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_delete_namespace", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_delete_namespace" "', argument " "1"" of type '" "gnc_commodity_table *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_table_delete_namespace" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gnc_commodity_table_delete_namespace(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_get_size(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  guint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_get_size" "', argument " "1"" of type '" "gnc_commodity_table const *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  result = gnc_commodity_table_get_size((gnc_commodity_table const *)arg1);
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_get_commodities(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  CommodityList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_get_commodities", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_get_commodities" "', argument " "1"" of type '" "gnc_commodity_table const *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_table_get_commodities" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (CommodityList *)gnc_commodity_table_get_commodities((gnc_commodity_table const *)arg1,(char const *)arg2);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_get_quotable_commodities(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  CommodityList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_get_quotable_commodities" "', argument " "1"" of type '" "gnc_commodity_table const *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  result = (CommodityList *)gnc_commodity_table_get_quotable_commodities((gnc_commodity_table const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_foreach_commodity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  gboolean (*arg2)(gnc_commodity *,gpointer) = (gboolean (*)(gnc_commodity *,gpointer)) 0 ;
  gpointer arg3 = (gpointer) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  PyObject *swig_obj[3] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_foreach_commodity", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_foreach_commodity" "', argument " "1"" of type '" "gnc_commodity_table const *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[1], (void**)(&arg2), SWIGTYPE_p_f_p_gnc_commodity_p_void__gboolean);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gnc_commodity_table_foreach_commodity" "', argument " "2"" of type '" "gboolean (*)(gnc_commodity *,gpointer)""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2],SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_commodity_table_foreach_commodity" "', argument " "3"" of type '" "gpointer""'"); 
  }
  result = gnc_commodity_table_foreach_commodity((gnc_commodity_table const *)arg1,arg2,arg3);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_new(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_new", 0, 0, 0)) SWIG_fail;
  result = (gnc_commodity_table *)gnc_commodity_table_new();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_destroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity_table *arg1 = (gnc_commodity_table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity_table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_table_destroy" "', argument " "1"" of type '" "gnc_commodity_table *""'"); 
  }
  arg1 = (gnc_commodity_table *)(argp1);
  gnc_commodity_table_destroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_obtain_twin(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_commodity *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_obtain_twin", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_obtain_twin" "', argument " "1"" of type '" "gnc_commodity const *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_commodity_obtain_twin" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  result = (gnc_commodity *)gnc_commodity_obtain_twin((gnc_commodity const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_table_register(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_commodity_table_register", 0, 0, 0)) SWIG_fail;
  result = gnc_commodity_table_register();
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_begin_edit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_begin_edit" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  gnc_commodity_begin_edit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_commodity_commit_edit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_commodity_commit_edit" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  gnc_commodity_commit_edit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gnc_monetary_commodity_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_monetary *arg1 = (struct _gnc_monetary *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "_gnc_monetary_commodity_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gnc_monetary, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gnc_monetary_commodity_set" "', argument " "1"" of type '" "struct _gnc_monetary *""'"); 
  }
  arg1 = (struct _gnc_monetary *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gnc_monetary_commodity_set" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  if (arg1) (arg1)->commodity = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gnc_monetary_commodity_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_monetary *arg1 = (struct _gnc_monetary *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gnc_monetary, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gnc_monetary_commodity_get" "', argument " "1"" of type '" "struct _gnc_monetary *""'"); 
  }
  arg1 = (struct _gnc_monetary *)(argp1);
  result = (gnc_commodity *) ((arg1)->commodity);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gnc_monetary_value_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_monetary *arg1 = (struct _gnc_monetary *) 0 ;
  gnc_numeric *arg2 = (gnc_numeric *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "_gnc_monetary_value_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gnc_monetary, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gnc_monetary_value_set" "', argument " "1"" of type '" "struct _gnc_monetary *""'"); 
  }
  arg1 = (struct _gnc_monetary *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gnc_monetary_value_set" "', argument " "2"" of type '" "gnc_numeric *""'"); 
  }
  arg2 = (gnc_numeric *)(argp2);
  if (arg1) (arg1)->value = *arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gnc_monetary_value_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_monetary *arg1 = (struct _gnc_monetary *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gnc_monetary, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gnc_monetary_value_get" "', argument " "1"" of type '" "struct _gnc_monetary *""'"); 
  }
  arg1 = (struct _gnc_monetary *)(argp1);
  result = (gnc_numeric *)& ((arg1)->value);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gnc_numeric, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gnc_monetary(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_monetary *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "new__gnc_monetary", 0, 0, 0)) SWIG_fail;
  result = (struct _gnc_monetary *)calloc(1, sizeof(struct _gnc_monetary));
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gnc_monetary, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gnc_monetary(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gnc_monetary *arg1 = (struct _gnc_monetary *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gnc_monetary, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gnc_monetary" "', argument " "1"" of type '" "struct _gnc_monetary *""'"); 
  }
  arg1 = (struct _gnc_monetary *)(argp1);
  free((char *) arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gnc_monetary_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gnc_monetary, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_gnc_monetary_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_gnc_monetary_create(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_commodity *arg1 = (gnc_commodity *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_monetary result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_monetary_create", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_monetary_create" "', argument " "1"" of type '" "gnc_commodity *""'"); 
  }
  arg1 = (gnc_commodity *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_monetary_create" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_monetary_create" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  result = gnc_monetary_create(arg1,arg2);
  resultobj = SWIG_NewPointerObj((gnc_monetary *)memcpy((gnc_monetary *)calloc(1,sizeof(gnc_monetary)),&result,sizeof(gnc_monetary)), SWIGTYPE_p__gnc_monetary, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_monetary_commodity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_monetary arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_monetary,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_monetary_commodity" "', argument " "1"" of type '" "gnc_monetary""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_monetary_commodity" "', argument " "1"" of type '" "gnc_monetary""'");
    } else {
      arg1 = *((gnc_monetary *)(argp1));
    }
  }
  result = (gnc_commodity *)gnc_monetary_commodity(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_monetary_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_monetary arg1 ;
  void *argp1 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_monetary,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_monetary_value" "', argument " "1"" of type '" "gnc_monetary""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_monetary_value" "', argument " "1"" of type '" "gnc_monetary""'");
    } else {
      arg1 = *((gnc_monetary *)(argp1));
    }
  }
  result = gnc_monetary_value(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_monetary_list_add_monetary(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  MonetaryList *arg1 = (MonetaryList *) 0 ;
  gnc_monetary arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  MonetaryList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_monetary_list_add_monetary", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_monetary_list_add_monetary" "', argument " "1"" of type '" "MonetaryList *""'"); 
  }
  arg1 = (MonetaryList *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_monetary,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_monetary_list_add_monetary" "', argument " "2"" of type '" "gnc_monetary""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_monetary_list_add_monetary" "', argument " "2"" of type '" "gnc_monetary""'");
    } else {
      arg2 = *((gnc_monetary *)(argp2));
    }
  }
  result = (MonetaryList *)gnc_monetary_list_add_monetary(arg1,arg2);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_monetary_list_add_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  MonetaryList *arg1 = (MonetaryList *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gnc_numeric arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  MonetaryList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_monetary_list_add_value", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_monetary_list_add_value" "', argument " "1"" of type '" "MonetaryList *""'"); 
  }
  arg1 = (MonetaryList *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_monetary_list_add_value" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_monetary_list_add_value" "', argument " "3"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_monetary_list_add_value" "', argument " "3"" of type '" "gnc_numeric""'");
    } else {
      arg3 = *((gnc_numeric *)(argp3));
    }
  }
  result = (MonetaryList *)gnc_monetary_list_add_value(arg1,arg2,arg3);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_monetary_list_delete_zeros(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  MonetaryList *arg1 = (MonetaryList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  MonetaryList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_monetary_list_delete_zeros" "', argument " "1"" of type '" "MonetaryList *""'"); 
  }
  arg1 = (MonetaryList *)(argp1);
  result = (MonetaryList *)gnc_monetary_list_delete_zeros(arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_monetary_list_free(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  MonetaryList *arg1 = (MonetaryList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_monetary_list_free" "', argument " "1"" of type '" "MonetaryList *""'"); 
  }
  arg1 = (MonetaryList *)(argp1);
  gnc_monetary_list_free(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetGUID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncGUID *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetGUID" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (GncGUID *)gncEntryGetGUID(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qofOwnerGetType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  QofIdTypeConst result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (QofIdTypeConst)qofOwnerGetType((struct _gncOwner const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetTypeString(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (char *)gncOwnerGetTypeString((struct _gncOwner const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_qofOwnerGetOwner(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  QofInstance *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (QofInstance *)qofOwnerGetOwner((struct _gncOwner const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofInstance, 0 |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_qofOwnerSetEntity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  QofInstance *arg2 = (QofInstance *) 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qofOwnerSetEntity", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofInstance, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qofOwnerSetEntity" "', argument " "2"" of type '" "QofInstance *""'"); 
  }
  arg2 = (QofInstance *)(argp2);
  qofOwnerSetEntity(arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_GNC_IS_OWNER(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofInstance *arg1 = (QofInstance *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofInstance, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "GNC_IS_OWNER" "', argument " "1"" of type '" "QofInstance *""'"); 
  }
  arg1 = (QofInstance *)(argp1);
  result = GNC_IS_OWNER(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerTypeToQofIdType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwnerType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  QofIdTypeConst result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gncOwnerTypeToQofIdType" "', argument " "1"" of type '" "GncOwnerType""'");
  } 
  arg1 = (GncOwnerType)(val1);
  result = (QofIdTypeConst)gncOwnerTypeToQofIdType(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerRegister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerRegister", 0, 0, 0)) SWIG_fail;
  result = gncOwnerRegister();
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerInitUndefined(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  gpointer arg2 = (gpointer) 0 ;
  int res2 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerInitUndefined", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1],SWIG_as_voidptrptr(&arg2), 0, 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerInitUndefined" "', argument " "2"" of type '" "gpointer""'"); 
  }
  gncOwnerInitUndefined(arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerInitCustomer(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  GncCustomer *arg2 = (GncCustomer *) 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerInitCustomer", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerInitCustomer" "', argument " "2"" of type '" "GncCustomer *""'"); 
  }
  arg2 = (GncCustomer *)(argp2);
  gncOwnerInitCustomer(arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerInitJob(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  GncJob *arg2 = (GncJob *) 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerInitJob", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerInitJob" "', argument " "2"" of type '" "GncJob *""'"); 
  }
  arg2 = (GncJob *)(argp2);
  gncOwnerInitJob(arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerInitVendor(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  GncVendor *arg2 = (GncVendor *) 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerInitVendor", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerInitVendor" "', argument " "2"" of type '" "GncVendor *""'"); 
  }
  arg2 = (GncVendor *)(argp2);
  gncOwnerInitVendor(arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerInitEmployee(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  GncEmployee *arg2 = (GncEmployee *) 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerInitEmployee", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerInitEmployee" "', argument " "2"" of type '" "GncEmployee *""'"); 
  }
  arg2 = (GncEmployee *)(argp2);
  gncOwnerInitEmployee(arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GncOwnerType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (GncOwnerType)gncOwnerGetType((struct _gncOwner const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerIsValid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = gncOwnerIsValid((struct _gncOwner const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetUndefined(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  gpointer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (gpointer)gncOwnerGetUndefined((struct _gncOwner const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_void, 0 |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetCustomer(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GncCustomer *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (GncCustomer *)gncOwnerGetCustomer((struct _gncOwner const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncCustomer, 0 |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetJob(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GncJob *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (GncJob *)gncOwnerGetJob((struct _gncOwner const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncJob, 0 |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetVendor(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GncVendor *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (GncVendor *)gncOwnerGetVendor((struct _gncOwner const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncVendor, 0 |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetEmployee(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GncEmployee *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (GncEmployee *)gncOwnerGetEmployee((struct _gncOwner const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncEmployee, 0 |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (char *)gncOwnerGetID((struct _gncOwner const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (char *)gncOwnerGetName((struct _gncOwner const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetAddr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GncAddress *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (GncAddress *)gncOwnerGetAddr((struct _gncOwner const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncAddress, 0 |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = gncOwnerGetActive((struct _gncOwner const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (gnc_commodity *)gncOwnerGetCurrency((struct _gncOwner const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerSetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  gboolean arg2 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerSetActive", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncOwnerSetActive((struct _gncOwner const *)arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerCopy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerCopy", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  gncOwnerCopy((struct _gncOwner const *)arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerEqual", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = gncOwnerEqual((struct _gncOwner const *)arg1,(struct _gncOwner const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  {
    gncOwnerFree(arg1);
  }
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGCompareFunc(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerGCompareFunc", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (int)gncOwnerGCompareFunc((struct _gncOwner const *)arg1,(struct _gncOwner const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  {
    gncOwnerFree(arg1);
  }
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerCompare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerCompare", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (int)gncOwnerCompare((struct _gncOwner const *)arg1,(struct _gncOwner const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  {
    gncOwnerFree(arg1);
  }
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetGUID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GncGUID *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (GncGUID *)gncOwnerGetGUID((struct _gncOwner const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerRetGUID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GncGUID result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = gncOwnerRetGUID(arg1);
  resultobj = SWIG_NewPointerObj((GncGUID *)memcpy((GncGUID *)calloc(1,sizeof(GncGUID)),&result,sizeof(GncGUID)), SWIGTYPE_p__gncGuid, SWIG_POINTER_OWN |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetEndOwner(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GncOwner *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (GncOwner *)gncOwnerGetEndOwner((struct _gncOwner const *)arg1);
  {
    GncOwnerType owner_type = gncOwnerGetType(result);
    PyObject * owner_tuple = PyTuple_New(2);
    PyTuple_SetItem(owner_tuple, 0, PyInt_FromLong( (long) owner_type ) );
    PyObject * swig_wrapper_object;
    if (owner_type == GNC_OWNER_CUSTOMER ){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetCustomer(result), SWIGTYPE_p__gncCustomer, 0);
    }
    else if (owner_type == GNC_OWNER_JOB){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetJob(result), SWIGTYPE_p__gncJob, 0);
    }
    else if (owner_type == GNC_OWNER_VENDOR){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetVendor(result), SWIGTYPE_p__gncVendor, 0);
    }
    else if (owner_type == GNC_OWNER_EMPLOYEE){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetEmployee(result), SWIGTYPE_p__gncEmployee, 0);
    }
    else {
      swig_wrapper_object = Py_None;
      Py_INCREF(Py_None);
    }
    PyTuple_SetItem(owner_tuple, 1, swig_wrapper_object);
    resultobj = owner_tuple;
  }
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetEndGUID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GncGUID *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (GncGUID *)gncOwnerGetEndGUID((struct _gncOwner const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncGuid, 0 |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerAttachToLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  GNCLot *arg2 = (GNCLot *) 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerAttachToLot", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerAttachToLot" "', argument " "2"" of type '" "GNCLot *""'"); 
  }
  arg2 = (GNCLot *)(argp2);
  gncOwnerAttachToLot((struct _gncOwner const *)arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerLotMatchOwnerFunc(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  gpointer arg2 = (gpointer) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerLotMatchOwnerFunc", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncOwnerLotMatchOwnerFunc" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1],SWIG_as_voidptrptr(&arg2), 0, 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerLotMatchOwnerFunc" "', argument " "2"" of type '" "gpointer""'"); 
  }
  result = gncOwnerLotMatchOwnerFunc(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerLotsSortFunc(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  GNCLot *arg2 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gint result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerLotsSortFunc", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncOwnerLotsSortFunc" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerLotsSortFunc" "', argument " "2"" of type '" "GNCLot *""'"); 
  }
  arg2 = (GNCLot *)(argp2);
  result = gncOwnerLotsSortFunc(arg1,arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetOwnerFromLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerGetOwnerFromLot", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncOwnerGetOwnerFromLot" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = gncOwnerGetOwnerFromLot(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetOwnerFromTxn(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerGetOwnerFromTxn", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncOwnerGetOwnerFromTxn" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = gncOwnerGetOwnerFromTxn(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetOwnerFromTypeGuid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  QofIdType arg3 = (QofIdType) 0 ;
  GncGUID *arg4 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  PyObject *swig_obj[4] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerGetOwnerFromTypeGuid", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncOwnerGetOwnerFromTypeGuid" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  {
    if (PyUnicode_Check(swig_obj[2])) {
      arg3 = PyUnicode_AsUTF8(swig_obj[2]);
    } else if (PyBytes_Check(swig_obj[2])) {
      arg3 = PyBytes_AsString(swig_obj[2]);
    } else {
      PyErr_SetString(PyExc_TypeError, "not a string or bytes object");
      return NULL;
    }
  }
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gncOwnerGetOwnerFromTypeGuid" "', argument " "4"" of type '" "GncGUID *""'"); 
  }
  arg4 = (GncGUID *)(argp4);
  result = gncOwnerGetOwnerFromTypeGuid(arg1,arg2,(gchar const *)arg3,arg4);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerCreatePaymentLotSecs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  Transaction **arg2 = (Transaction **) 0 ;
  Account *arg3 = (Account *) 0 ;
  Account *arg4 = (Account *) 0 ;
  gnc_numeric arg5 ;
  gnc_numeric arg6 ;
  time64 arg7 ;
  char *arg8 = (char *) 0 ;
  char *arg9 = (char *) 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  void *argp5 ;
  int res5 = 0 ;
  void *argp6 ;
  int res6 = 0 ;
  int res8 ;
  char *buf8 = 0 ;
  int alloc8 = 0 ;
  int res9 ;
  char *buf9 = 0 ;
  int alloc9 = 0 ;
  PyObject *swig_obj[9] ;
  GNCLot *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerCreatePaymentLotSecs", 9, 9, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerCreatePaymentLotSecs" "', argument " "2"" of type '" "Transaction **""'"); 
  }
  arg2 = (Transaction **)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gncOwnerCreatePaymentLotSecs" "', argument " "3"" of type '" "Account *""'"); 
  }
  arg3 = (Account *)(argp3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gncOwnerCreatePaymentLotSecs" "', argument " "4"" of type '" "Account *""'"); 
  }
  arg4 = (Account *)(argp4);
  {
    res5 = SWIG_ConvertPtr(swig_obj[4], &argp5, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res5)) {
      SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "gncOwnerCreatePaymentLotSecs" "', argument " "5"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp5) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncOwnerCreatePaymentLotSecs" "', argument " "5"" of type '" "gnc_numeric""'");
    } else {
      arg5 = *((gnc_numeric *)(argp5));
    }
  }
  {
    res6 = SWIG_ConvertPtr(swig_obj[5], &argp6, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res6)) {
      SWIG_exception_fail(SWIG_ArgError(res6), "in method '" "gncOwnerCreatePaymentLotSecs" "', argument " "6"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp6) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncOwnerCreatePaymentLotSecs" "', argument " "6"" of type '" "gnc_numeric""'");
    } else {
      arg6 = *((gnc_numeric *)(argp6));
    }
  }
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[6]) && !PyInt_Check(swig_obj[6])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[6])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[6]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[6]),
        PyDateTime_DATE_GET_HOUR(swig_obj[6]),
        PyDateTime_GET_DAY(swig_obj[6]),
        PyDateTime_GET_MONTH(swig_obj[6]) - 1,
        PyDateTime_GET_YEAR(swig_obj[6]) - 1900
      };
      arg7 = gnc_mktime(&time);
    } else {
      arg7 = PyInt_AsLong(swig_obj[6]);
    }
  }
  res8 = SWIG_AsCharPtrAndSize(swig_obj[7], &buf8, NULL, &alloc8);
  if (!SWIG_IsOK(res8)) {
    SWIG_exception_fail(SWIG_ArgError(res8), "in method '" "gncOwnerCreatePaymentLotSecs" "', argument " "8"" of type '" "char const *""'");
  }
  arg8 = (char *)(buf8);
  res9 = SWIG_AsCharPtrAndSize(swig_obj[8], &buf9, NULL, &alloc9);
  if (!SWIG_IsOK(res9)) {
    SWIG_exception_fail(SWIG_ArgError(res9), "in method '" "gncOwnerCreatePaymentLotSecs" "', argument " "9"" of type '" "char const *""'");
  }
  arg9 = (char *)(buf9);
  result = (GNCLot *)gncOwnerCreatePaymentLotSecs((struct _gncOwner const *)arg1,arg2,arg3,arg4,arg5,arg6,arg7,(char const *)arg8,(char const *)arg9);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCLot, 0 |  0 );
  {
    gncOwnerFree(arg1);
  }
  if (alloc8 == SWIG_NEWOBJ) free((char*)buf8);
  if (alloc9 == SWIG_NEWOBJ) free((char*)buf9);
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  if (alloc8 == SWIG_NEWOBJ) free((char*)buf8);
  if (alloc9 == SWIG_NEWOBJ) free((char*)buf9);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerAutoApplyPaymentsWithLots(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  GList *arg2 = (GList *) 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerAutoApplyPaymentsWithLots", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerAutoApplyPaymentsWithLots" "', argument " "2"" of type '" "GList *""'"); 
  }
  arg2 = (GList *)(argp2);
  gncOwnerAutoApplyPaymentsWithLots((struct _gncOwner const *)arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerApplyPaymentSecs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  Transaction **arg2 = (Transaction **) 0 ;
  GList *arg3 = (GList *) 0 ;
  Account *arg4 = (Account *) 0 ;
  Account *arg5 = (Account *) 0 ;
  gnc_numeric arg6 ;
  gnc_numeric arg7 ;
  time64 arg8 ;
  char *arg9 = (char *) 0 ;
  char *arg10 = (char *) 0 ;
  gboolean arg11 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  void *argp5 = 0 ;
  int res5 = 0 ;
  void *argp6 ;
  int res6 = 0 ;
  void *argp7 ;
  int res7 = 0 ;
  int res9 ;
  char *buf9 = 0 ;
  int alloc9 = 0 ;
  int res10 ;
  char *buf10 = 0 ;
  int alloc10 = 0 ;
  PyObject *swig_obj[11] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerApplyPaymentSecs", 11, 11, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerApplyPaymentSecs" "', argument " "2"" of type '" "Transaction **""'"); 
  }
  arg2 = (Transaction **)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gncOwnerApplyPaymentSecs" "', argument " "3"" of type '" "GList *""'"); 
  }
  arg3 = (GList *)(argp3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gncOwnerApplyPaymentSecs" "', argument " "4"" of type '" "Account *""'"); 
  }
  arg4 = (Account *)(argp4);
  res5 = SWIG_ConvertPtr(swig_obj[4], &argp5,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res5)) {
    SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "gncOwnerApplyPaymentSecs" "', argument " "5"" of type '" "Account *""'"); 
  }
  arg5 = (Account *)(argp5);
  {
    res6 = SWIG_ConvertPtr(swig_obj[5], &argp6, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res6)) {
      SWIG_exception_fail(SWIG_ArgError(res6), "in method '" "gncOwnerApplyPaymentSecs" "', argument " "6"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp6) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncOwnerApplyPaymentSecs" "', argument " "6"" of type '" "gnc_numeric""'");
    } else {
      arg6 = *((gnc_numeric *)(argp6));
    }
  }
  {
    res7 = SWIG_ConvertPtr(swig_obj[6], &argp7, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res7)) {
      SWIG_exception_fail(SWIG_ArgError(res7), "in method '" "gncOwnerApplyPaymentSecs" "', argument " "7"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp7) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncOwnerApplyPaymentSecs" "', argument " "7"" of type '" "gnc_numeric""'");
    } else {
      arg7 = *((gnc_numeric *)(argp7));
    }
  }
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[7]) && !PyInt_Check(swig_obj[7])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[7])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[7]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[7]),
        PyDateTime_DATE_GET_HOUR(swig_obj[7]),
        PyDateTime_GET_DAY(swig_obj[7]),
        PyDateTime_GET_MONTH(swig_obj[7]) - 1,
        PyDateTime_GET_YEAR(swig_obj[7]) - 1900
      };
      arg8 = gnc_mktime(&time);
    } else {
      arg8 = PyInt_AsLong(swig_obj[7]);
    }
  }
  res9 = SWIG_AsCharPtrAndSize(swig_obj[8], &buf9, NULL, &alloc9);
  if (!SWIG_IsOK(res9)) {
    SWIG_exception_fail(SWIG_ArgError(res9), "in method '" "gncOwnerApplyPaymentSecs" "', argument " "9"" of type '" "char const *""'");
  }
  arg9 = (char *)(buf9);
  res10 = SWIG_AsCharPtrAndSize(swig_obj[9], &buf10, NULL, &alloc10);
  if (!SWIG_IsOK(res10)) {
    SWIG_exception_fail(SWIG_ArgError(res10), "in method '" "gncOwnerApplyPaymentSecs" "', argument " "10"" of type '" "char const *""'");
  }
  arg10 = (char *)(buf10);
  {
    if (swig_obj[10] == Py_True)
    arg11 = TRUE;
    else if (swig_obj[10] == Py_False)
    arg11 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncOwnerApplyPaymentSecs((struct _gncOwner const *)arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,(char const *)arg9,(char const *)arg10,arg11);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  if (alloc9 == SWIG_NEWOBJ) free((char*)buf9);
  if (alloc10 == SWIG_NEWOBJ) free((char*)buf10);
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  if (alloc9 == SWIG_NEWOBJ) free((char*)buf9);
  if (alloc10 == SWIG_NEWOBJ) free((char*)buf10);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerFindOffsettingSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Split *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerFindOffsettingSplit", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncOwnerFindOffsettingSplit" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerFindOffsettingSplit" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncOwnerFindOffsettingSplit" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  result = (Split *)gncOwnerFindOffsettingSplit(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerReduceSplitTo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerReduceSplitTo", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncOwnerReduceSplitTo" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerReduceSplitTo" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncOwnerReduceSplitTo" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  result = gncOwnerReduceSplitTo(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerSetLotLinkMemo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncOwnerSetLotLinkMemo" "', argument " "1"" of type '" "Transaction *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  gncOwnerSetLotLinkMemo(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetAccountTypesList(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (GList *)gncOwnerGetAccountTypesList((struct _gncOwner const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetCommoditiesList(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (GList *)gncOwnerGetCommoditiesList((struct _gncOwner const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerGetBalanceInCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerGetBalanceInCurrency", 2, 2, swig_obj)) SWIG_fail;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncOwnerGetBalanceInCurrency" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  result = gncOwnerGetBalanceInCurrency((struct _gncOwner const *)arg1,(gnc_commodity const *)arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerNew(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncOwnerNew", 0, 0, 0)) SWIG_fail;
  result = (GncOwner *)gncOwnerNew();
  {
    GncOwnerType owner_type = gncOwnerGetType(result);
    PyObject * owner_tuple = PyTuple_New(2);
    PyTuple_SetItem(owner_tuple, 0, PyInt_FromLong( (long) owner_type ) );
    PyObject * swig_wrapper_object;
    if (owner_type == GNC_OWNER_CUSTOMER ){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetCustomer(result), SWIGTYPE_p__gncCustomer, 0);
    }
    else if (owner_type == GNC_OWNER_JOB){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetJob(result), SWIGTYPE_p__gncJob, 0);
    }
    else if (owner_type == GNC_OWNER_VENDOR){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetVendor(result), SWIGTYPE_p__gncVendor, 0);
    }
    else if (owner_type == GNC_OWNER_EMPLOYEE){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetEmployee(result), SWIGTYPE_p__gncEmployee, 0);
    }
    else {
      swig_wrapper_object = Py_None;
      Py_INCREF(Py_None);
    }
    PyTuple_SetItem(owner_tuple, 1, swig_wrapper_object);
    resultobj = owner_tuple;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerFree(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  gncOwnerFree(arg1);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  gncOwnerBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  gncOwnerCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncOwnerDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwner *arg1 = (GncOwner *) 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[0], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg1 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  gncOwnerDestroy(arg1);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg1);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg1);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_customer_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_customer_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_customer_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerCreate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncCustomer *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerCreate" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GncCustomer *)gncCustomerCreate(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncCustomer, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerDestroy" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  gncCustomerDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerBeginEdit" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  gncCustomerBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerCommitEdit" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  gncCustomerCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetID", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetID" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerSetID" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncCustomerSetID(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetName" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerSetName" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncCustomerSetName(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetNotes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetNotes" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerSetNotes" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncCustomerSetNotes(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetTerms(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  GncBillTerm *arg2 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetTerms", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetTerms" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerSetTerms" "', argument " "2"" of type '" "GncBillTerm *""'"); 
  }
  arg2 = (GncBillTerm *)(argp2);
  gncCustomerSetTerms(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetTaxIncluded(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  GncTaxIncluded arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetTaxIncluded", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetTaxIncluded" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncCustomerSetTaxIncluded" "', argument " "2"" of type '" "GncTaxIncluded""'");
  } 
  arg2 = (GncTaxIncluded)(val2);
  gncCustomerSetTaxIncluded(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetActive", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetActive" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncCustomerSetActive(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetDiscount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetDiscount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetDiscount" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerSetDiscount" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncCustomerSetDiscount" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncCustomerSetDiscount(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetCredit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetCredit", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetCredit" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerSetCredit" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncCustomerSetCredit" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncCustomerSetCredit(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetCurrency", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetCurrency" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerSetCurrency" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  gncCustomerSetCurrency(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetTaxTableOverride(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetTaxTableOverride", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetTaxTableOverride" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncCustomerSetTaxTableOverride(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetTaxTable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  GncTaxTable *arg2 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetTaxTable", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetTaxTable" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerSetTaxTable" "', argument " "2"" of type '" "GncTaxTable *""'"); 
  }
  arg2 = (GncTaxTable *)(argp2);
  gncCustomerSetTaxTable(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerAddJob(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  GncJob *arg2 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerAddJob", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerAddJob" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerAddJob" "', argument " "2"" of type '" "GncJob *""'"); 
  }
  arg2 = (GncJob *)(argp2);
  gncCustomerAddJob(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerRemoveJob(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  GncJob *arg2 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerRemoveJob", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerRemoveJob" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerRemoveJob" "', argument " "2"" of type '" "GncJob *""'"); 
  }
  arg2 = (GncJob *)(argp2);
  gncCustomerRemoveJob(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerLookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GncCustomer *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerLookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerLookup" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerLookup" "', argument " "2"" of type '" "GncGUID const *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = (GncCustomer *)gncCustomerLookup((QofBook const *)arg1,(struct _gncGuid const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncCustomer, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetID" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = (char *)gncCustomerGetID((struct _gncCustomer const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetName" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = (char *)gncCustomerGetName((struct _gncCustomer const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetAddr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncAddress *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetAddr" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = (GncAddress *)gncCustomerGetAddr((struct _gncCustomer const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncAddress, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetShipAddr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncAddress *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetShipAddr" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = (GncAddress *)gncCustomerGetShipAddr((struct _gncCustomer const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncAddress, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetNotes" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = (char *)gncCustomerGetNotes((struct _gncCustomer const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetTerms(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncBillTerm *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetTerms" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = (GncBillTerm *)gncCustomerGetTerms((struct _gncCustomer const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncBillTerm, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetTaxIncluded(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncTaxIncluded result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetTaxIncluded" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = (GncTaxIncluded)gncCustomerGetTaxIncluded((struct _gncCustomer const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetActive" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = gncCustomerGetActive((struct _gncCustomer const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetDiscount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetDiscount" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = gncCustomerGetDiscount((struct _gncCustomer const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetCredit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetCredit" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = gncCustomerGetCredit((struct _gncCustomer const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetCurrency" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = (gnc_commodity *)gncCustomerGetCurrency((struct _gncCustomer const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetTaxTableOverride(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetTaxTableOverride" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = gncCustomerGetTaxTableOverride((struct _gncCustomer const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetTaxTable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncTaxTable *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetTaxTable" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = (GncTaxTable *)gncCustomerGetTaxTable((struct _gncCustomer const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncTaxTable, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerCompare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  GncCustomer *arg2 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerCompare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerCompare" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerCompare" "', argument " "2"" of type '" "GncCustomer const *""'"); 
  }
  arg2 = (GncCustomer *)(argp2);
  result = (int)gncCustomerCompare((struct _gncCustomer const *)arg1,(struct _gncCustomer const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  GncCustomer *arg2 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerEqual", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerEqual" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerEqual" "', argument " "2"" of type '" "GncCustomer const *""'"); 
  }
  arg2 = (GncCustomer *)(argp2);
  result = gncCustomerEqual((struct _gncCustomer const *)arg1,(struct _gncCustomer const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetJoblist(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  GList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerGetJoblist", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetJoblist" "', argument " "1"" of type '" "GncCustomer const *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = (GList *)gncCustomerGetJoblist((struct _gncCustomer const *)arg1,arg2);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerIsDirty(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerIsDirty" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = gncCustomerIsDirty(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerRegister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerRegister", 0, 0, 0)) SWIG_fail;
  result = gncCustomerRegister();
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerNextID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gchar *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerNextID" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (gchar *)gncCustomerNextID(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerGetCachedBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerGetCachedBalance" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  result = (gnc_numeric *)gncCustomerGetCachedBalance(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gnc_numeric, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncCustomerSetCachedBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncCustomer *arg1 = (GncCustomer *) 0 ;
  gnc_numeric *arg2 = (gnc_numeric *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncCustomerSetCachedBalance", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncCustomerSetCachedBalance" "', argument " "1"" of type '" "GncCustomer *""'"); 
  }
  arg1 = (GncCustomer *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncCustomerSetCachedBalance" "', argument " "2"" of type '" "gnc_numeric const *""'"); 
  }
  arg2 = (gnc_numeric *)(argp2);
  gncCustomerSetCachedBalance(arg1,(struct _gnc_numeric const *)arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_employee_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_employee_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_employee_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeCreate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncEmployee *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeCreate" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GncEmployee *)gncEmployeeCreate(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncEmployee, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeDestroy" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  gncEmployeeDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeBeginEdit" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  gncEmployeeBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeCommitEdit" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  gncEmployeeCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeCompare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  GncEmployee *arg2 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeCompare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeCompare" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeCompare" "', argument " "2"" of type '" "GncEmployee const *""'"); 
  }
  arg2 = (GncEmployee *)(argp2);
  result = (int)gncEmployeeCompare((struct _gncEmployee const *)arg1,(struct _gncEmployee const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeSetID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeSetID", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeSetID" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeSetID" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncEmployeeSetID(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeSetUsername(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeSetUsername", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeSetUsername" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeSetUsername" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncEmployeeSetUsername(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeSetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeSetName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeSetName" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeSetName" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncEmployeeSetName(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeSetLanguage(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeSetLanguage", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeSetLanguage" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeSetLanguage" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncEmployeeSetLanguage(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeSetAcl(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeSetAcl", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeSetAcl" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeSetAcl" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncEmployeeSetAcl(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeSetWorkday(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeSetWorkday", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeSetWorkday" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeSetWorkday" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncEmployeeSetWorkday" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncEmployeeSetWorkday(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeSetRate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeSetRate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeSetRate" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeSetRate" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncEmployeeSetRate" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncEmployeeSetRate(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeSetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeSetCurrency", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeSetCurrency" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeSetCurrency" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  gncEmployeeSetCurrency(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeSetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeSetActive", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeSetActive" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncEmployeeSetActive(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeSetCCard(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeSetCCard", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeSetCCard" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeSetCCard" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  gncEmployeeSetCCard(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qofEmployeeSetAddr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  QofInstance *arg2 = (QofInstance *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qofEmployeeSetAddr", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qofEmployeeSetAddr" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofInstance, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qofEmployeeSetAddr" "', argument " "2"" of type '" "QofInstance *""'"); 
  }
  arg2 = (QofInstance *)(argp2);
  qofEmployeeSetAddr(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetBook(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBook *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetBook" "', argument " "1"" of type '" "GncEmployee *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = (QofBook *)gncEmployeeGetBook(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofBook, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetID" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = (char *)gncEmployeeGetID((struct _gncEmployee const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetUsername(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetUsername" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = (char *)gncEmployeeGetUsername((struct _gncEmployee const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetName" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = (char *)gncEmployeeGetName((struct _gncEmployee const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetAddr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncAddress *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetAddr" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = (GncAddress *)gncEmployeeGetAddr((struct _gncEmployee const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncAddress, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetLanguage(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetLanguage" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = (char *)gncEmployeeGetLanguage((struct _gncEmployee const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetAcl(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetAcl" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = (char *)gncEmployeeGetAcl((struct _gncEmployee const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetWorkday(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetWorkday" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = gncEmployeeGetWorkday((struct _gncEmployee const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetRate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetRate" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = gncEmployeeGetRate((struct _gncEmployee const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetCurrency" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = (gnc_commodity *)gncEmployeeGetCurrency((struct _gncEmployee const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetActive" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = gncEmployeeGetActive((struct _gncEmployee const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeGetCCard(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeGetCCard" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = (Account *)gncEmployeeGetCCard((struct _gncEmployee const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeLookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GncEmployee *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeLookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeLookup" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeLookup" "', argument " "2"" of type '" "GncGUID const *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = (GncEmployee *)gncEmployeeLookup((QofBook const *)arg1,(struct _gncGuid const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncEmployee, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  GncEmployee *arg2 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEmployeeEqual", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeEqual" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEmployeeEqual" "', argument " "2"" of type '" "GncEmployee const *""'"); 
  }
  arg2 = (GncEmployee *)(argp2);
  result = gncEmployeeEqual((struct _gncEmployee const *)arg1,(struct _gncEmployee const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEmployeeIsDirty(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEmployee *arg1 = (GncEmployee *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEmployee, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEmployeeIsDirty" "', argument " "1"" of type '" "GncEmployee const *""'"); 
  }
  arg1 = (GncEmployee *)(argp1);
  result = gncEmployeeIsDirty((struct _gncEmployee const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_vendor_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_vendor_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_vendor_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorCreate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncVendor *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorCreate" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GncVendor *)gncVendorCreate(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncVendor, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorDestroy" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  gncVendorDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorSetID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorSetID", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorSetID" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorSetID" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncVendorSetID(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorSetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorSetName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorSetName" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorSetName" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncVendorSetName(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorSetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorSetNotes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorSetNotes" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorSetNotes" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncVendorSetNotes(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorSetTerms(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  GncBillTerm *arg2 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorSetTerms", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorSetTerms" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorSetTerms" "', argument " "2"" of type '" "GncBillTerm *""'"); 
  }
  arg2 = (GncBillTerm *)(argp2);
  gncVendorSetTerms(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorSetTaxIncluded(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  GncTaxIncluded arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorSetTaxIncluded", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorSetTaxIncluded" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncVendorSetTaxIncluded" "', argument " "2"" of type '" "GncTaxIncluded""'");
  } 
  arg2 = (GncTaxIncluded)(val2);
  gncVendorSetTaxIncluded(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorSetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorSetCurrency", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorSetCurrency" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorSetCurrency" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  gncVendorSetCurrency(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorSetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorSetActive", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorSetActive" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncVendorSetActive(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorSetTaxTableOverride(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorSetTaxTableOverride", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorSetTaxTableOverride" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncVendorSetTaxTableOverride(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorSetTaxTable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  GncTaxTable *arg2 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorSetTaxTable", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorSetTaxTable" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorSetTaxTable" "', argument " "2"" of type '" "GncTaxTable *""'"); 
  }
  arg2 = (GncTaxTable *)(argp2);
  gncVendorSetTaxTable(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorAddJob(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  GncJob *arg2 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorAddJob", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorAddJob" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorAddJob" "', argument " "2"" of type '" "GncJob *""'"); 
  }
  arg2 = (GncJob *)(argp2);
  gncVendorAddJob(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorRemoveJob(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  GncJob *arg2 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorRemoveJob", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorRemoveJob" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorRemoveJob" "', argument " "2"" of type '" "GncJob *""'"); 
  }
  arg2 = (GncJob *)(argp2);
  gncVendorRemoveJob(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorBeginEdit" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  gncVendorBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorCommitEdit" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  gncVendorCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorGetID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorGetID" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = (char *)gncVendorGetID((struct _gncVendor const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorGetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorGetName" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = (char *)gncVendorGetName((struct _gncVendor const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorGetAddr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncAddress *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorGetAddr" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = (GncAddress *)gncVendorGetAddr((struct _gncVendor const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncAddress, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorGetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorGetNotes" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = (char *)gncVendorGetNotes((struct _gncVendor const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorGetTerms(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncBillTerm *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorGetTerms" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = (GncBillTerm *)gncVendorGetTerms((struct _gncVendor const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncBillTerm, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorGetTaxIncluded(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncTaxIncluded result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorGetTaxIncluded" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = (GncTaxIncluded)gncVendorGetTaxIncluded((struct _gncVendor const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorGetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorGetCurrency" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = (gnc_commodity *)gncVendorGetCurrency((struct _gncVendor const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorGetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorGetActive" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = gncVendorGetActive((struct _gncVendor const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorGetTaxTableOverride(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorGetTaxTableOverride" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = gncVendorGetTaxTableOverride((struct _gncVendor const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorGetTaxTable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncTaxTable *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorGetTaxTable" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = (GncTaxTable *)gncVendorGetTaxTable((struct _gncVendor const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncTaxTable, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorCompare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  GncVendor *arg2 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorCompare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorCompare" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorCompare" "', argument " "2"" of type '" "GncVendor const *""'"); 
  }
  arg2 = (GncVendor *)(argp2);
  result = (int)gncVendorCompare((struct _gncVendor const *)arg1,(struct _gncVendor const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorLookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GncVendor *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorLookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorLookup" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorLookup" "', argument " "2"" of type '" "GncGUID const *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = (GncVendor *)gncVendorLookup((QofBook const *)arg1,(struct _gncGuid const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncVendor, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  GncVendor *arg2 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorEqual", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorEqual" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorEqual" "', argument " "2"" of type '" "GncVendor const *""'"); 
  }
  arg2 = (GncVendor *)(argp2);
  result = gncVendorEqual((struct _gncVendor const *)arg1,(struct _gncVendor const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorIsDirty(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorIsDirty" "', argument " "1"" of type '" "GncVendor const *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = gncVendorIsDirty((struct _gncVendor const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorRegister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorRegister", 0, 0, 0)) SWIG_fail;
  result = gncVendorRegister();
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorNextID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gchar *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorNextID" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (gchar *)gncVendorNextID(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorGetCachedBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorGetCachedBalance" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  result = (gnc_numeric *)gncVendorGetCachedBalance(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gnc_numeric, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncVendorSetCachedBalance(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncVendor *arg1 = (GncVendor *) 0 ;
  gnc_numeric *arg2 = (gnc_numeric *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncVendorSetCachedBalance", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncVendor, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncVendorSetCachedBalance" "', argument " "1"" of type '" "GncVendor *""'"); 
  }
  arg1 = (GncVendor *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncVendorSetCachedBalance" "', argument " "2"" of type '" "gnc_numeric const *""'"); 
  }
  arg2 = (gnc_numeric *)(argp2);
  gncVendorSetCachedBalance(arg1,(struct _gnc_numeric const *)arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_address_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_address_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_address_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressCreate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  QofInstance *arg2 = (QofInstance *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GncAddress *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAddressCreate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressCreate" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofInstance, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAddressCreate" "', argument " "2"" of type '" "QofInstance *""'"); 
  }
  arg2 = (QofInstance *)(argp2);
  result = (GncAddress *)gncAddressCreate(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncAddress, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressDestroy" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  gncAddressDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressBeginEdit" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  gncAddressBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressCommitEdit" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  gncAddressCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressSetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAddressSetName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressSetName" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAddressSetName" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncAddressSetName(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressSetAddr1(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAddressSetAddr1", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressSetAddr1" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAddressSetAddr1" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncAddressSetAddr1(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressSetAddr2(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAddressSetAddr2", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressSetAddr2" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAddressSetAddr2" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncAddressSetAddr2(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressSetAddr3(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAddressSetAddr3", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressSetAddr3" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAddressSetAddr3" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncAddressSetAddr3(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressSetAddr4(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAddressSetAddr4", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressSetAddr4" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAddressSetAddr4" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncAddressSetAddr4(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressSetPhone(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAddressSetPhone", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressSetPhone" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAddressSetPhone" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncAddressSetPhone(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressSetFax(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAddressSetFax", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressSetFax" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAddressSetFax" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncAddressSetFax(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressSetEmail(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAddressSetEmail", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressSetEmail" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAddressSetEmail" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncAddressSetEmail(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressClearDirty(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressClearDirty" "', argument " "1"" of type '" "GncAddress *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  gncAddressClearDirty(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressGetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressGetName" "', argument " "1"" of type '" "GncAddress const *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  result = (char *)gncAddressGetName((struct _gncAddress const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressGetAddr1(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressGetAddr1" "', argument " "1"" of type '" "GncAddress const *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  result = (char *)gncAddressGetAddr1((struct _gncAddress const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressGetAddr2(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressGetAddr2" "', argument " "1"" of type '" "GncAddress const *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  result = (char *)gncAddressGetAddr2((struct _gncAddress const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressGetAddr3(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressGetAddr3" "', argument " "1"" of type '" "GncAddress const *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  result = (char *)gncAddressGetAddr3((struct _gncAddress const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressGetAddr4(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressGetAddr4" "', argument " "1"" of type '" "GncAddress const *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  result = (char *)gncAddressGetAddr4((struct _gncAddress const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressGetPhone(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressGetPhone" "', argument " "1"" of type '" "GncAddress const *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  result = (char *)gncAddressGetPhone((struct _gncAddress const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressGetFax(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressGetFax" "', argument " "1"" of type '" "GncAddress const *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  result = (char *)gncAddressGetFax((struct _gncAddress const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressGetEmail(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressGetEmail" "', argument " "1"" of type '" "GncAddress const *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  result = (char *)gncAddressGetEmail((struct _gncAddress const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressIsDirty(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressIsDirty" "', argument " "1"" of type '" "GncAddress const *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  result = gncAddressIsDirty((struct _gncAddress const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressCompare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  GncAddress *arg2 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAddressCompare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressCompare" "', argument " "1"" of type '" "GncAddress const *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAddressCompare" "', argument " "2"" of type '" "GncAddress const *""'"); 
  }
  arg2 = (GncAddress *)(argp2);
  result = (int)gncAddressCompare((struct _gncAddress const *)arg1,(struct _gncAddress const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAddressEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAddress *arg1 = (GncAddress *) 0 ;
  GncAddress *arg2 = (GncAddress *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAddressEqual", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAddressEqual" "', argument " "1"" of type '" "GncAddress const *""'"); 
  }
  arg1 = (GncAddress *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncAddress, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAddressEqual" "', argument " "2"" of type '" "GncAddress const *""'"); 
  }
  arg2 = (GncAddress *)(argp2);
  result = gncAddressEqual((struct _gncAddress const *)arg1,(struct _gncAddress const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_billterm_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_billterm_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_billterm_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermCreate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncBillTerm *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermCreate" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GncBillTerm *)gncBillTermCreate(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncBillTerm, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermDestroy" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  gncBillTermDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermIncRef(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermIncRef" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  gncBillTermIncRef(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermDecRef(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermDecRef" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  gncBillTermDecRef(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermChanged(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermChanged" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  gncBillTermChanged(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermBeginEdit" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  gncBillTermBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermCommitEdit" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  gncBillTermCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermSetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermSetName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermSetName" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncBillTermSetName" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncBillTermSetName(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermSetDescription(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermSetDescription", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermSetDescription" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncBillTermSetDescription" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncBillTermSetDescription(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermSetType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  GncBillTermType arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermSetType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermSetType" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncBillTermSetType" "', argument " "2"" of type '" "GncBillTermType""'");
  } 
  arg2 = (GncBillTermType)(val2);
  gncBillTermSetType(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermSetDueDays(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  gint arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermSetDueDays", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermSetDueDays" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncBillTermSetDueDays" "', argument " "2"" of type '" "gint""'");
  } 
  arg2 = (gint)(val2);
  gncBillTermSetDueDays(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermSetDiscountDays(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  gint arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermSetDiscountDays", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermSetDiscountDays" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncBillTermSetDiscountDays" "', argument " "2"" of type '" "gint""'");
  } 
  arg2 = (gint)(val2);
  gncBillTermSetDiscountDays(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermSetDiscount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermSetDiscount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermSetDiscount" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncBillTermSetDiscount" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncBillTermSetDiscount" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncBillTermSetDiscount(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermSetCutoff(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  gint arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermSetCutoff", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermSetCutoff" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncBillTermSetCutoff" "', argument " "2"" of type '" "gint""'");
  } 
  arg2 = (gint)(val2);
  gncBillTermSetCutoff(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermLookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GncBillTerm *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermLookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermLookup" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncBillTermLookup" "', argument " "2"" of type '" "GncGUID const *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = (GncBillTerm *)gncBillTermLookup((QofBook const *)arg1,(struct _gncGuid const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncBillTerm, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermLookupByName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  GncBillTerm *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermLookupByName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermLookupByName" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncBillTermLookupByName" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (GncBillTerm *)gncBillTermLookupByName(arg1,(char const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermGetTerms(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermGetTerms" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GList *)gncBillTermGetTerms(arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermGetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermGetName" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  result = (char *)gncBillTermGetName((struct _gncBillTerm const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermGetDescription(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermGetDescription" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  result = (char *)gncBillTermGetDescription((struct _gncBillTerm const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermGetType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncBillTermType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermGetType" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  result = (GncBillTermType)gncBillTermGetType((struct _gncBillTerm const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermGetDueDays(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermGetDueDays" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  result = gncBillTermGetDueDays((struct _gncBillTerm const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermGetDiscountDays(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermGetDiscountDays" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  result = gncBillTermGetDiscountDays((struct _gncBillTerm const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermGetDiscount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermGetDiscount" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  result = gncBillTermGetDiscount((struct _gncBillTerm const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermGetCutoff(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermGetCutoff" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  result = gncBillTermGetCutoff((struct _gncBillTerm const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermIsDirty(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermIsDirty" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  result = gncBillTermIsDirty((struct _gncBillTerm const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermGetParent(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncBillTerm *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermGetParent" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  result = (GncBillTerm *)gncBillTermGetParent((struct _gncBillTerm const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncBillTerm, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermReturnChild(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  GncBillTerm *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermReturnChild", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermReturnChild" "', argument " "1"" of type '" "GncBillTerm *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = (GncBillTerm *)gncBillTermReturnChild(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncBillTerm, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermGetRefcount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermGetRefcount" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  result = gncBillTermGetRefcount((struct _gncBillTerm const *)arg1);
  resultobj = SWIG_From_long_SS_long((long long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermCompare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  GncBillTerm *arg2 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermCompare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermCompare" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncBillTermCompare" "', argument " "2"" of type '" "GncBillTerm const *""'"); 
  }
  arg2 = (GncBillTerm *)(argp2);
  result = (int)gncBillTermCompare((struct _gncBillTerm const *)arg1,(struct _gncBillTerm const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  GncBillTerm *arg2 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermEqual", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermEqual" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncBillTermEqual" "', argument " "2"" of type '" "GncBillTerm const *""'"); 
  }
  arg2 = (GncBillTerm *)(argp2);
  result = gncBillTermEqual((struct _gncBillTerm const *)arg1,(struct _gncBillTerm const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermIsFamily(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  GncBillTerm *arg2 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermIsFamily", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermIsFamily" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncBillTermIsFamily" "', argument " "2"" of type '" "GncBillTerm const *""'"); 
  }
  arg2 = (GncBillTerm *)(argp2);
  result = gncBillTermIsFamily((struct _gncBillTerm const *)arg1,(struct _gncBillTerm const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillTermComputeDueDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncBillTerm *arg1 = (GncBillTerm *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  time64 result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillTermComputeDueDate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillTermComputeDueDate" "', argument " "1"" of type '" "GncBillTerm const *""'"); 
  }
  arg1 = (GncBillTerm *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  result = gncBillTermComputeDueDate((struct _gncBillTerm const *)arg1,arg2);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_invoice_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_invoice_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_invoice_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceCreate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncInvoice *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceCreate" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GncInvoice *)gncInvoiceCreate(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncInvoice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceDestroy" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  gncInvoiceDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceCopy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncInvoice *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceCopy" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (GncInvoice *)gncInvoiceCopy((struct _gncInvoice const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncInvoice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetID", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetID" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceSetID" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncInvoiceSetID(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetOwner(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetOwner", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetOwner" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  gncInvoiceSetOwner(arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetDateOpenedGDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GDate *arg2 = (GDate *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetDateOpenedGDate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetDateOpenedGDate" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GDate, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceSetDateOpenedGDate" "', argument " "2"" of type '" "GDate const *""'"); 
  }
  arg2 = (GDate *)(argp2);
  gncInvoiceSetDateOpenedGDate(arg1,(GDate const *)arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetDateOpened(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetDateOpened", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetDateOpened" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  gncInvoiceSetDateOpened(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetDatePosted(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetDatePosted", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetDatePosted" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  gncInvoiceSetDatePosted(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetTerms(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GncBillTerm *arg2 = (GncBillTerm *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetTerms", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetTerms" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncBillTerm, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceSetTerms" "', argument " "2"" of type '" "GncBillTerm *""'"); 
  }
  arg2 = (GncBillTerm *)(argp2);
  gncInvoiceSetTerms(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetBillingID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetBillingID", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetBillingID" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceSetBillingID" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncInvoiceSetBillingID(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetNotes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetNotes" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceSetNotes" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncInvoiceSetNotes(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetCurrency", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetCurrency" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceSetCurrency" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  gncInvoiceSetCurrency(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetActive", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetActive" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncInvoiceSetActive(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetIsCreditNote(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetIsCreditNote", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetIsCreditNote" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncInvoiceSetIsCreditNote(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetBillTo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetBillTo", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetBillTo" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  gncInvoiceSetBillTo(arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetToChargeAmount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetToChargeAmount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetToChargeAmount" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceSetToChargeAmount" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncInvoiceSetToChargeAmount" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncInvoiceSetToChargeAmount(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceAddEntry(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GncEntry *arg2 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceAddEntry", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceAddEntry" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceAddEntry" "', argument " "2"" of type '" "GncEntry *""'"); 
  }
  arg2 = (GncEntry *)(argp2);
  gncInvoiceAddEntry(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceRemoveEntry(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GncEntry *arg2 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceRemoveEntry", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceRemoveEntry" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceRemoveEntry" "', argument " "2"" of type '" "GncEntry *""'"); 
  }
  arg2 = (GncEntry *)(argp2);
  gncInvoiceRemoveEntry(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceAddPrice(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GNCPrice *arg2 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceAddPrice", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceAddPrice" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceAddPrice" "', argument " "2"" of type '" "GNCPrice *""'"); 
  }
  arg2 = (GNCPrice *)(argp2);
  gncInvoiceAddPrice(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillAddEntry(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GncEntry *arg2 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillAddEntry", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillAddEntry" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncBillAddEntry" "', argument " "2"" of type '" "GncEntry *""'"); 
  }
  arg2 = (GncEntry *)(argp2);
  gncBillAddEntry(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncBillRemoveEntry(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GncEntry *arg2 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncBillRemoveEntry", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncBillRemoveEntry" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncBillRemoveEntry" "', argument " "2"" of type '" "GncEntry *""'"); 
  }
  arg2 = (GncEntry *)(argp2);
  gncBillRemoveEntry(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSortEntries(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSortEntries" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  gncInvoiceSortEntries(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceRemoveEntries(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceRemoveEntries" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  gncInvoiceRemoveEntries(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetID" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (char *)gncInvoiceGetID((struct _gncInvoice const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetOwner(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncOwner *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetOwner" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (GncOwner *)gncInvoiceGetOwner((struct _gncInvoice const *)arg1);
  {
    GncOwnerType owner_type = gncOwnerGetType(result);
    PyObject * owner_tuple = PyTuple_New(2);
    PyTuple_SetItem(owner_tuple, 0, PyInt_FromLong( (long) owner_type ) );
    PyObject * swig_wrapper_object;
    if (owner_type == GNC_OWNER_CUSTOMER ){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetCustomer(result), SWIGTYPE_p__gncCustomer, 0);
    }
    else if (owner_type == GNC_OWNER_JOB){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetJob(result), SWIGTYPE_p__gncJob, 0);
    }
    else if (owner_type == GNC_OWNER_VENDOR){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetVendor(result), SWIGTYPE_p__gncVendor, 0);
    }
    else if (owner_type == GNC_OWNER_EMPLOYEE){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetEmployee(result), SWIGTYPE_p__gncEmployee, 0);
    }
    else {
      swig_wrapper_object = Py_None;
      Py_INCREF(Py_None);
    }
    PyTuple_SetItem(owner_tuple, 1, swig_wrapper_object);
    resultobj = owner_tuple;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetDateOpened(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetDateOpened" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceGetDateOpened((struct _gncInvoice const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetDatePosted(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetDatePosted" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceGetDatePosted((struct _gncInvoice const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetDateDue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetDateDue" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceGetDateDue((struct _gncInvoice const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetTerms(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncBillTerm *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetTerms" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (GncBillTerm *)gncInvoiceGetTerms((struct _gncInvoice const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncBillTerm, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetBillingID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetBillingID" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (char *)gncInvoiceGetBillingID((struct _gncInvoice const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetNotes" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (char *)gncInvoiceGetNotes((struct _gncInvoice const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetOwnerType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncOwnerType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetOwnerType" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (GncOwnerType)gncInvoiceGetOwnerType((struct _gncInvoice const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetTypeListForOwnerType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncOwnerType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  GList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gncInvoiceGetTypeListForOwnerType" "', argument " "1"" of type '" "GncOwnerType""'");
  } 
  arg1 = (GncOwnerType)(val1);
  result = (GList *)gncInvoiceGetTypeListForOwnerType(arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncInvoiceType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetType" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (GncInvoiceType)gncInvoiceGetType((struct _gncInvoice const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetTypeString(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetTypeString" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (char *)gncInvoiceGetTypeString((struct _gncInvoice const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetCurrency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetCurrency" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (gnc_commodity *)gncInvoiceGetCurrency((struct _gncInvoice const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetBillTo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncOwner *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetBillTo" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (GncOwner *)gncInvoiceGetBillTo(arg1);
  {
    GncOwnerType owner_type = gncOwnerGetType(result);
    PyObject * owner_tuple = PyTuple_New(2);
    PyTuple_SetItem(owner_tuple, 0, PyInt_FromLong( (long) owner_type ) );
    PyObject * swig_wrapper_object;
    if (owner_type == GNC_OWNER_CUSTOMER ){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetCustomer(result), SWIGTYPE_p__gncCustomer, 0);
    }
    else if (owner_type == GNC_OWNER_JOB){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetJob(result), SWIGTYPE_p__gncJob, 0);
    }
    else if (owner_type == GNC_OWNER_VENDOR){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetVendor(result), SWIGTYPE_p__gncVendor, 0);
    }
    else if (owner_type == GNC_OWNER_EMPLOYEE){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetEmployee(result), SWIGTYPE_p__gncEmployee, 0);
    }
    else {
      swig_wrapper_object = Py_None;
      Py_INCREF(Py_None);
    }
    PyTuple_SetItem(owner_tuple, 1, swig_wrapper_object);
    resultobj = owner_tuple;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetToChargeAmount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetToChargeAmount" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceGetToChargeAmount((struct _gncInvoice const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetActive" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceGetActive((struct _gncInvoice const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetIsCreditNote(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetIsCreditNote" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceGetIsCreditNote((struct _gncInvoice const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetPostedLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCLot *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetPostedLot" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (GNCLot *)gncInvoiceGetPostedLot((struct _gncInvoice const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCLot, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetPostedTxn(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Transaction *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetPostedTxn" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (Transaction *)gncInvoiceGetPostedTxn((struct _gncInvoice const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Transaction, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetPostedAcc(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetPostedAcc" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (Account *)gncInvoiceGetPostedAcc((struct _gncInvoice const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetTotal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetTotal" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceGetTotal(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetTotalOf(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GncEntryPaymentType arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceGetTotalOf", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetTotalOf" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncInvoiceGetTotalOf" "', argument " "2"" of type '" "GncEntryPaymentType""'");
  } 
  arg2 = (GncEntryPaymentType)(val2);
  result = gncInvoiceGetTotalOf(arg1,arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetTotalSubtotal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetTotalSubtotal" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceGetTotalSubtotal(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetTotalTax(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetTotalTax" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceGetTotalTax(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetTotalTaxList(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  AccountValueList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetTotalTaxList" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (AccountValueList *)gncInvoiceGetTotalTaxList(arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetEntries(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  EntryList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetEntries" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (EntryList *)gncInvoiceGetEntries(arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetPrice(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GNCPrice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceGetPrice", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetPrice" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceGetPrice" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  result = (GNCPrice *)gncInvoiceGetPrice(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPrice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceAmountPositive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceAmountPositive" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceAmountPositive((struct _gncInvoice const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetForeignCurrencies(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GHashTable *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetForeignCurrencies" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (GHashTable *)gncInvoiceGetForeignCurrencies((struct _gncInvoice const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GHashTable, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoicePostToAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  Account *arg2 = (Account *) 0 ;
  time64 arg3 ;
  time64 arg4 ;
  char *arg5 = (char *) 0 ;
  gboolean arg6 ;
  gboolean arg7 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int res5 ;
  char *buf5 = 0 ;
  int alloc5 = 0 ;
  PyObject *swig_obj[7] ;
  Transaction *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoicePostToAccount", 7, 7, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoicePostToAccount" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoicePostToAccount" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[2]) && !PyInt_Check(swig_obj[2])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[2])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[2]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[2]),
        PyDateTime_DATE_GET_HOUR(swig_obj[2]),
        PyDateTime_GET_DAY(swig_obj[2]),
        PyDateTime_GET_MONTH(swig_obj[2]) - 1,
        PyDateTime_GET_YEAR(swig_obj[2]) - 1900
      };
      arg3 = gnc_mktime(&time);
    } else {
      arg3 = PyInt_AsLong(swig_obj[2]);
    }
  }
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[3]) && !PyInt_Check(swig_obj[3])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[3])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[3]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[3]),
        PyDateTime_DATE_GET_HOUR(swig_obj[3]),
        PyDateTime_GET_DAY(swig_obj[3]),
        PyDateTime_GET_MONTH(swig_obj[3]) - 1,
        PyDateTime_GET_YEAR(swig_obj[3]) - 1900
      };
      arg4 = gnc_mktime(&time);
    } else {
      arg4 = PyInt_AsLong(swig_obj[3]);
    }
  }
  res5 = SWIG_AsCharPtrAndSize(swig_obj[4], &buf5, NULL, &alloc5);
  if (!SWIG_IsOK(res5)) {
    SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "gncInvoicePostToAccount" "', argument " "5"" of type '" "char const *""'");
  }
  arg5 = (char *)(buf5);
  {
    if (swig_obj[5] == Py_True)
    arg6 = TRUE;
    else if (swig_obj[5] == Py_False)
    arg6 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[6] == Py_True)
    arg7 = TRUE;
    else if (swig_obj[6] == Py_False)
    arg7 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = (Transaction *)gncInvoicePostToAccount(arg1,arg2,arg3,arg4,(char const *)arg5,arg6,arg7);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Transaction, 0 |  0 );
  if (alloc5 == SWIG_NEWOBJ) free((char*)buf5);
  return resultobj;
fail:
  if (alloc5 == SWIG_NEWOBJ) free((char*)buf5);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceUnpost(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceUnpost", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceUnpost" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = gncInvoiceUnpost(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceAutoApplyPayments(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceAutoApplyPayments" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  gncInvoiceAutoApplyPayments(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceApplyPayment(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  Transaction *arg2 = (Transaction *) 0 ;
  Account *arg3 = (Account *) 0 ;
  gnc_numeric arg4 ;
  gnc_numeric arg5 ;
  time64 arg6 ;
  char *arg7 = (char *) 0 ;
  char *arg8 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 ;
  int res4 = 0 ;
  void *argp5 ;
  int res5 = 0 ;
  int res7 ;
  char *buf7 = 0 ;
  int alloc7 = 0 ;
  int res8 ;
  char *buf8 = 0 ;
  int alloc8 = 0 ;
  PyObject *swig_obj[8] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceApplyPayment", 8, 8, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceApplyPayment" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceApplyPayment" "', argument " "2"" of type '" "Transaction *""'"); 
  }
  arg2 = (Transaction *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gncInvoiceApplyPayment" "', argument " "3"" of type '" "Account *""'"); 
  }
  arg3 = (Account *)(argp3);
  {
    res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res4)) {
      SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gncInvoiceApplyPayment" "', argument " "4"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp4) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncInvoiceApplyPayment" "', argument " "4"" of type '" "gnc_numeric""'");
    } else {
      arg4 = *((gnc_numeric *)(argp4));
    }
  }
  {
    res5 = SWIG_ConvertPtr(swig_obj[4], &argp5, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res5)) {
      SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "gncInvoiceApplyPayment" "', argument " "5"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp5) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncInvoiceApplyPayment" "', argument " "5"" of type '" "gnc_numeric""'");
    } else {
      arg5 = *((gnc_numeric *)(argp5));
    }
  }
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[5]) && !PyInt_Check(swig_obj[5])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[5])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[5]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[5]),
        PyDateTime_DATE_GET_HOUR(swig_obj[5]),
        PyDateTime_GET_DAY(swig_obj[5]),
        PyDateTime_GET_MONTH(swig_obj[5]) - 1,
        PyDateTime_GET_YEAR(swig_obj[5]) - 1900
      };
      arg6 = gnc_mktime(&time);
    } else {
      arg6 = PyInt_AsLong(swig_obj[5]);
    }
  }
  res7 = SWIG_AsCharPtrAndSize(swig_obj[6], &buf7, NULL, &alloc7);
  if (!SWIG_IsOK(res7)) {
    SWIG_exception_fail(SWIG_ArgError(res7), "in method '" "gncInvoiceApplyPayment" "', argument " "7"" of type '" "char const *""'");
  }
  arg7 = (char *)(buf7);
  res8 = SWIG_AsCharPtrAndSize(swig_obj[7], &buf8, NULL, &alloc8);
  if (!SWIG_IsOK(res8)) {
    SWIG_exception_fail(SWIG_ArgError(res8), "in method '" "gncInvoiceApplyPayment" "', argument " "8"" of type '" "char const *""'");
  }
  arg8 = (char *)(buf8);
  gncInvoiceApplyPayment((struct _gncInvoice const *)arg1,arg2,arg3,arg4,arg5,arg6,(char const *)arg7,(char const *)arg8);
  resultobj = SWIG_Py_Void();
  if (alloc7 == SWIG_NEWOBJ) free((char*)buf7);
  if (alloc8 == SWIG_NEWOBJ) free((char*)buf8);
  return resultobj;
fail:
  if (alloc7 == SWIG_NEWOBJ) free((char*)buf7);
  if (alloc8 == SWIG_NEWOBJ) free((char*)buf8);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetInvoiceFromTxn(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Transaction *arg1 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncInvoice *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetInvoiceFromTxn" "', argument " "1"" of type '" "Transaction const *""'"); 
  }
  arg1 = (Transaction *)(argp1);
  result = (GncInvoice *)gncInvoiceGetInvoiceFromTxn((Transaction const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncInvoice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetInvoiceFromLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncInvoice *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetInvoiceFromLot" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = (GncInvoice *)gncInvoiceGetInvoiceFromLot(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncInvoice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceLookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GncInvoice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceLookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceLookup" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceLookup" "', argument " "2"" of type '" "GncGUID const *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = (GncInvoice *)gncInvoiceLookup((QofBook const *)arg1,(struct _gncGuid const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncInvoice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceBeginEdit" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  gncInvoiceBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceCommitEdit" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  gncInvoiceCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceCompare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GncInvoice *arg2 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceCompare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceCompare" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceCompare" "', argument " "2"" of type '" "GncInvoice const *""'"); 
  }
  arg2 = (GncInvoice *)(argp2);
  result = (int)gncInvoiceCompare((struct _gncInvoice const *)arg1,(struct _gncInvoice const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceIsPosted(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceIsPosted" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceIsPosted((struct _gncInvoice const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceIsPaid(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceIsPaid" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = gncInvoiceIsPaid((struct _gncInvoice const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceGetBook(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  QofBook *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceGetBook" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  result = (QofBook *)gncInvoiceGetBook(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_QofBook, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GncInvoice *arg2 = (GncInvoice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceEqual", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceEqual" "', argument " "1"" of type '" "GncInvoice const *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceEqual" "', argument " "2"" of type '" "GncInvoice const *""'"); 
  }
  arg2 = (GncInvoice *)(argp2);
  result = gncInvoiceEqual((struct _gncInvoice const *)arg1,(struct _gncInvoice const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceRegister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceRegister", 0, 0, 0)) SWIG_fail;
  result = gncInvoiceRegister();
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceNextID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  gchar *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceNextID", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceNextID" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  result = (gchar *)gncInvoiceNextID(arg1,(struct _gncOwner const *)arg2);
  resultobj = SWIG_FromCharPtr((const char *)result);
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetPostedAcc(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetPostedAcc", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetPostedAcc" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceSetPostedAcc" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  gncInvoiceSetPostedAcc(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetPostedTxn(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  Transaction *arg2 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetPostedTxn", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetPostedTxn" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceSetPostedTxn" "', argument " "2"" of type '" "Transaction *""'"); 
  }
  arg2 = (Transaction *)(argp2);
  gncInvoiceSetPostedTxn(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceSetPostedLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GNCLot *arg2 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceSetPostedLot", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceSetPostedLot" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceSetPostedLot" "', argument " "2"" of type '" "GNCLot *""'"); 
  }
  arg2 = (GNCLot *)(argp2);
  gncInvoiceSetPostedLot(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceAttachToLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  GNCLot *arg2 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceAttachToLot", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceAttachToLot" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceAttachToLot" "', argument " "2"" of type '" "GNCLot *""'"); 
  }
  arg2 = (GNCLot *)(argp2);
  gncInvoiceAttachToLot(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceDetachFromLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceDetachFromLot" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  gncInvoiceDetachFromLot(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncInvoiceAttachToTxn(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncInvoice *arg1 = (GncInvoice *) 0 ;
  Transaction *arg2 = (Transaction *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncInvoiceAttachToTxn", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncInvoiceAttachToTxn" "', argument " "1"" of type '" "GncInvoice *""'"); 
  }
  arg1 = (GncInvoice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Transaction, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncInvoiceAttachToTxn" "', argument " "2"" of type '" "Transaction *""'"); 
  }
  arg2 = (Transaction *)(argp2);
  gncInvoiceAttachToTxn(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_job_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_job_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_job_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobCreate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncJob *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobCreate" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GncJob *)gncJobCreate(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncJob, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobDestroy" "', argument " "1"" of type '" "GncJob *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  gncJobDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobSetID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncJobSetID", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobSetID" "', argument " "1"" of type '" "GncJob *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncJobSetID" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncJobSetID(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobSetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncJobSetName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobSetName" "', argument " "1"" of type '" "GncJob *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncJobSetName" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncJobSetName(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobSetReference(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncJobSetReference", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobSetReference" "', argument " "1"" of type '" "GncJob *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncJobSetReference" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncJobSetReference(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobSetRate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncJobSetRate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobSetRate" "', argument " "1"" of type '" "GncJob *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncJobSetRate" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncJobSetRate" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncJobSetRate(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobSetOwner(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncJobSetOwner", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobSetOwner" "', argument " "1"" of type '" "GncJob *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  gncJobSetOwner(arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobSetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncJobSetActive", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobSetActive" "', argument " "1"" of type '" "GncJob *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncJobSetActive(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobBeginEdit" "', argument " "1"" of type '" "GncJob *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  gncJobBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobCommitEdit" "', argument " "1"" of type '" "GncJob *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  gncJobCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobGetID(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobGetID" "', argument " "1"" of type '" "GncJob const *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  result = (char *)gncJobGetID((struct _gncJob const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobGetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobGetName" "', argument " "1"" of type '" "GncJob const *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  result = (char *)gncJobGetName((struct _gncJob const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobGetReference(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobGetReference" "', argument " "1"" of type '" "GncJob const *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  result = (char *)gncJobGetReference((struct _gncJob const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobGetRate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobGetRate" "', argument " "1"" of type '" "GncJob const *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  result = gncJobGetRate((struct _gncJob const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobGetOwner(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncOwner *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobGetOwner" "', argument " "1"" of type '" "GncJob *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  result = (GncOwner *)gncJobGetOwner(arg1);
  {
    GncOwnerType owner_type = gncOwnerGetType(result);
    PyObject * owner_tuple = PyTuple_New(2);
    PyTuple_SetItem(owner_tuple, 0, PyInt_FromLong( (long) owner_type ) );
    PyObject * swig_wrapper_object;
    if (owner_type == GNC_OWNER_CUSTOMER ){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetCustomer(result), SWIGTYPE_p__gncCustomer, 0);
    }
    else if (owner_type == GNC_OWNER_JOB){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetJob(result), SWIGTYPE_p__gncJob, 0);
    }
    else if (owner_type == GNC_OWNER_VENDOR){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetVendor(result), SWIGTYPE_p__gncVendor, 0);
    }
    else if (owner_type == GNC_OWNER_EMPLOYEE){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetEmployee(result), SWIGTYPE_p__gncEmployee, 0);
    }
    else {
      swig_wrapper_object = Py_None;
      Py_INCREF(Py_None);
    }
    PyTuple_SetItem(owner_tuple, 1, swig_wrapper_object);
    resultobj = owner_tuple;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobGetActive(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobGetActive" "', argument " "1"" of type '" "GncJob const *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  result = gncJobGetActive((struct _gncJob const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobLookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GncJob *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncJobLookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobLookup" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncJobLookup" "', argument " "2"" of type '" "GncGUID const *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = (GncJob *)gncJobLookup((QofBook const *)arg1,(struct _gncGuid const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncJob, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobCompare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  GncJob *arg2 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncJobCompare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobCompare" "', argument " "1"" of type '" "GncJob const *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncJobCompare" "', argument " "2"" of type '" "GncJob const *""'"); 
  }
  arg2 = (GncJob *)(argp2);
  result = (int)gncJobCompare((struct _gncJob const *)arg1,(struct _gncJob const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncJobEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncJob *arg1 = (GncJob *) 0 ;
  GncJob *arg2 = (GncJob *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncJobEqual", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncJobEqual" "', argument " "1"" of type '" "GncJob const *""'"); 
  }
  arg1 = (GncJob *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncJob, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncJobEqual" "', argument " "2"" of type '" "GncJob const *""'"); 
  }
  arg2 = (GncJob *)(argp2);
  result = gncJobEqual((struct _gncJob const *)arg1,(struct _gncJob const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_entry_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_entry_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_entry_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryDiscountHowToString(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncDiscountHow arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gncEntryDiscountHowToString" "', argument " "1"" of type '" "GncDiscountHow""'");
  } 
  arg1 = (GncDiscountHow)(val1);
  result = (char *)gncEntryDiscountHowToString(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryDiscountStringToHow(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  GncDiscountHow *arg2 = (GncDiscountHow *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryDiscountStringToHow", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryDiscountStringToHow" "', argument " "1"" of type '" "char const *""'");
  }
  arg1 = (char *)(buf1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GncDiscountHow, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntryDiscountStringToHow" "', argument " "2"" of type '" "GncDiscountHow *""'"); 
  }
  arg2 = (GncDiscountHow *)(argp2);
  result = gncEntryDiscountStringToHow((char const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryPaymentTypeToString(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntryPaymentType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gncEntryPaymentTypeToString" "', argument " "1"" of type '" "GncEntryPaymentType""'");
  } 
  arg1 = (GncEntryPaymentType)(val1);
  result = (char *)gncEntryPaymentTypeToString(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryPaymentStringToType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  GncEntryPaymentType *arg2 = (GncEntryPaymentType *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryPaymentStringToType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryPaymentStringToType" "', argument " "1"" of type '" "char const *""'");
  }
  arg1 = (char *)(buf1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GncEntryPaymentType, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntryPaymentStringToType" "', argument " "2"" of type '" "GncEntryPaymentType *""'"); 
  }
  arg2 = (GncEntryPaymentType *)(argp2);
  result = gncEntryPaymentStringToType((char const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryCreate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncEntry *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryCreate" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GncEntry *)gncEntryCreate(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncEntry, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryDestroy" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  gncEntryDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetDateGDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  GDate *arg2 = (GDate *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetDateGDate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetDateGDate" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GDate, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetDateGDate" "', argument " "2"" of type '" "GDate const *""'"); 
  }
  arg2 = (GDate *)(argp2);
  gncEntrySetDateGDate(arg1,(GDate const *)arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetDate", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetDate" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  gncEntrySetDate(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetDateEntered(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetDateEntered", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetDateEntered" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  gncEntrySetDateEntered(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetDescription(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetDescription", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetDescription" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetDescription" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncEntrySetDescription(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetAction(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetAction", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetAction" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetAction" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncEntrySetAction(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetNotes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetNotes" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetNotes" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncEntrySetNotes(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetQuantity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetQuantity", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetQuantity" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetQuantity" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncEntrySetQuantity" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncEntrySetQuantity(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetDocQuantity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gnc_numeric arg2 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetDocQuantity", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetDocQuantity" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetDocQuantity" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncEntrySetDocQuantity" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncEntrySetDocQuantity(arg1,arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetInvAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetInvAccount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetInvAccount" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetInvAccount" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  gncEntrySetInvAccount(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetInvPrice(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetInvPrice", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetInvPrice" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetInvPrice" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncEntrySetInvPrice" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncEntrySetInvPrice(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetInvTaxable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetInvTaxable", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetInvTaxable" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncEntrySetInvTaxable(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetInvTaxIncluded(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetInvTaxIncluded", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetInvTaxIncluded" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncEntrySetInvTaxIncluded(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetInvTaxTable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  GncTaxTable *arg2 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetInvTaxTable", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetInvTaxTable" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetInvTaxTable" "', argument " "2"" of type '" "GncTaxTable *""'"); 
  }
  arg2 = (GncTaxTable *)(argp2);
  gncEntrySetInvTaxTable(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetInvDiscount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetInvDiscount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetInvDiscount" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetInvDiscount" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncEntrySetInvDiscount" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncEntrySetInvDiscount(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetInvDiscountType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  GncAmountType arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetInvDiscountType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetInvDiscountType" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncEntrySetInvDiscountType" "', argument " "2"" of type '" "GncAmountType""'");
  } 
  arg2 = (GncAmountType)(val2);
  gncEntrySetInvDiscountType(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetInvDiscountHow(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  GncDiscountHow arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetInvDiscountHow", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetInvDiscountHow" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncEntrySetInvDiscountHow" "', argument " "2"" of type '" "GncDiscountHow""'");
  } 
  arg2 = (GncDiscountHow)(val2);
  gncEntrySetInvDiscountHow(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qofEntrySetInvDiscType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qofEntrySetInvDiscType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qofEntrySetInvDiscType" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qofEntrySetInvDiscType" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  qofEntrySetInvDiscType(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_qofEntrySetInvDiscHow(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "qofEntrySetInvDiscHow", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qofEntrySetInvDiscHow" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "qofEntrySetInvDiscHow" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  qofEntrySetInvDiscHow(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetBillAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetBillAccount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetBillAccount" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetBillAccount" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  gncEntrySetBillAccount(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetBillPrice(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetBillPrice", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetBillPrice" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetBillPrice" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncEntrySetBillPrice" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncEntrySetBillPrice(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetBillTaxable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetBillTaxable", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetBillTaxable" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncEntrySetBillTaxable(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetBillTaxIncluded(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetBillTaxIncluded", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetBillTaxIncluded" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncEntrySetBillTaxIncluded(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetBillTaxTable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  GncTaxTable *arg2 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetBillTaxTable", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetBillTaxTable" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntrySetBillTaxTable" "', argument " "2"" of type '" "GncTaxTable *""'"); 
  }
  arg2 = (GncTaxTable *)(argp2);
  gncEntrySetBillTaxTable(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetBillable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetBillable", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetBillable" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncEntrySetBillable(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetBillTo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  GncOwner *arg2 = (GncOwner *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetBillTo", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetBillTo" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    GncOwner * temp_owner = gncOwnerNew();
    void * pointer_to_real_thing;
    if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncCustomer,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitCustomer(temp_owner, (GncCustomer *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncJob,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitJob(temp_owner, (GncJob *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncVendor,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitVendor(temp_owner, (GncVendor *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else if ((SWIG_ConvertPtr(swig_obj[1], &pointer_to_real_thing,
          SWIGTYPE_p__gncEmployee,
          SWIG_POINTER_EXCEPTION)) == 0){
      gncOwnerInitEmployee(temp_owner, (GncEmployee *)pointer_to_real_thing);
      arg2 = temp_owner;
    }
    else {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to function with GncOwner * argument "
        "couldn't be converted back to pointer of that type");
      return NULL;
    }
  }
  gncEntrySetBillTo(arg1,arg2);
  resultobj = SWIG_Py_Void();
  {
    gncOwnerFree(arg2);
  }
  return resultobj;
fail:
  {
    gncOwnerFree(arg2);
  }
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntrySetBillPayment(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  GncEntryPaymentType arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntrySetBillPayment", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntrySetBillPayment" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncEntrySetBillPayment" "', argument " "2"" of type '" "GncEntryPaymentType""'");
  } 
  arg2 = (GncEntryPaymentType)(val2);
  gncEntrySetBillPayment(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetDateGDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GDate result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetDateGDate" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetDateGDate((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj((GDate *)memcpy((GDate *)calloc(1,sizeof(GDate)),&result,sizeof(GDate)), SWIGTYPE_p_GDate, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetDate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetDate" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetDate((struct _gncEntry const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetDateEntered(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetDateEntered" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetDateEntered((struct _gncEntry const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetDescription(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetDescription" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (char *)gncEntryGetDescription((struct _gncEntry const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetAction(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetAction" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (char *)gncEntryGetAction((struct _gncEntry const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetNotes(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetNotes" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (char *)gncEntryGetNotes((struct _gncEntry const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetQuantity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetQuantity" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetQuantity((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetDocQuantity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryGetDocQuantity", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetDocQuantity" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = gncEntryGetDocQuantity((struct _gncEntry const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetInvAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetInvAccount" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (Account *)gncEntryGetInvAccount((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetInvPrice(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetInvPrice" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetInvPrice((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetPrice(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryGetPrice", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetPrice" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = gncEntryGetPrice((struct _gncEntry const *)arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetInvDiscount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetInvDiscount" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetInvDiscount((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetInvDiscountType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncAmountType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetInvDiscountType" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (GncAmountType)gncEntryGetInvDiscountType((struct _gncEntry const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetInvDiscountHow(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncDiscountHow result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetInvDiscountHow" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (GncDiscountHow)gncEntryGetInvDiscountHow((struct _gncEntry const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qofEntryGetInvDiscType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qofEntryGetInvDiscType" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (char *)qofEntryGetInvDiscType((struct _gncEntry const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_qofEntryGetInvDiscHow(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "qofEntryGetInvDiscHow" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (char *)qofEntryGetInvDiscHow((struct _gncEntry const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetInvTaxable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetInvTaxable" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetInvTaxable((struct _gncEntry const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetInvTaxIncluded(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetInvTaxIncluded" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetInvTaxIncluded((struct _gncEntry const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetInvTaxTable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncTaxTable *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetInvTaxTable" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (GncTaxTable *)gncEntryGetInvTaxTable((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncTaxTable, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBillAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBillAccount" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (Account *)gncEntryGetBillAccount((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBillPrice(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBillPrice" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetBillPrice((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBillTaxable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBillTaxable" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetBillTaxable((struct _gncEntry const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBillTaxIncluded(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBillTaxIncluded" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetBillTaxIncluded((struct _gncEntry const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBillTaxTable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncTaxTable *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBillTaxTable" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (GncTaxTable *)gncEntryGetBillTaxTable((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncTaxTable, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBillable(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBillable" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryGetBillable((struct _gncEntry const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBillTo(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncOwner *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBillTo" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (GncOwner *)gncEntryGetBillTo(arg1);
  {
    GncOwnerType owner_type = gncOwnerGetType(result);
    PyObject * owner_tuple = PyTuple_New(2);
    PyTuple_SetItem(owner_tuple, 0, PyInt_FromLong( (long) owner_type ) );
    PyObject * swig_wrapper_object;
    if (owner_type == GNC_OWNER_CUSTOMER ){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetCustomer(result), SWIGTYPE_p__gncCustomer, 0);
    }
    else if (owner_type == GNC_OWNER_JOB){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetJob(result), SWIGTYPE_p__gncJob, 0);
    }
    else if (owner_type == GNC_OWNER_VENDOR){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetVendor(result), SWIGTYPE_p__gncVendor, 0);
    }
    else if (owner_type == GNC_OWNER_EMPLOYEE){
      swig_wrapper_object = SWIG_NewPointerObj(
        gncOwnerGetEmployee(result), SWIGTYPE_p__gncEmployee, 0);
    }
    else {
      swig_wrapper_object = Py_None;
      Py_INCREF(Py_None);
    }
    PyTuple_SetItem(owner_tuple, 1, swig_wrapper_object);
    resultobj = owner_tuple;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBillPayment(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncEntryPaymentType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBillPayment" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (GncEntryPaymentType)gncEntryGetBillPayment((struct _gncEntry const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryCopy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  GncEntry *arg2 = (GncEntry *) 0 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryCopy", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryCopy" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntryCopy" "', argument " "2"" of type '" "GncEntry *""'"); 
  }
  arg2 = (GncEntry *)(argp2);
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gncEntryCopy((struct _gncEntry const *)arg1,arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetDocValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  gboolean arg3 ;
  gboolean arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryGetDocValue", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetDocValue" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = gncEntryGetDocValue(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetDocTaxValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  gboolean arg3 ;
  gboolean arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryGetDocTaxValue", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetDocTaxValue" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = gncEntryGetDocTaxValue(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetDocTaxValues(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[3] ;
  AccountValueList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryGetDocTaxValues", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetDocTaxValues" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = (AccountValueList *)gncEntryGetDocTaxValues(arg1,arg2,arg3);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetDocDiscountValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  gboolean arg3 ;
  gboolean arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryGetDocDiscountValue", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetDocDiscountValue" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = gncEntryGetDocDiscountValue(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBalValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryGetBalValue", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBalValue" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = gncEntryGetBalValue(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBalTaxValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryGetBalTaxValue", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBalTaxValue" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = gncEntryGetBalTaxValue(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBalTaxValues(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  AccountValueList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryGetBalTaxValues", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBalTaxValues" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = (AccountValueList *)gncEntryGetBalTaxValues(arg1,arg2);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBalDiscountValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  gboolean arg2 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[3] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryGetBalDiscountValue", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBalDiscountValue" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = gncEntryGetBalDiscountValue(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryComputeValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  gnc_numeric arg1 ;
  gnc_numeric arg2 ;
  GncTaxTable *arg3 = (GncTaxTable *) 0 ;
  gboolean arg4 ;
  gnc_numeric arg5 ;
  GncAmountType arg6 ;
  GncDiscountHow arg7 ;
  int arg8 ;
  gnc_numeric *arg9 = (gnc_numeric *) 0 ;
  gnc_numeric *arg10 = (gnc_numeric *) 0 ;
  GList **arg11 = (GList **) 0 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp5 ;
  int res5 = 0 ;
  int val6 ;
  int ecode6 = 0 ;
  int val7 ;
  int ecode7 = 0 ;
  int val8 ;
  int ecode8 = 0 ;
  void *argp9 = 0 ;
  int res9 = 0 ;
  void *argp10 = 0 ;
  int res10 = 0 ;
  void *argp11 = 0 ;
  int res11 = 0 ;
  PyObject *swig_obj[11] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryComputeValue", 11, 11, swig_obj)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryComputeValue" "', argument " "1"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncEntryComputeValue" "', argument " "1"" of type '" "gnc_numeric""'");
    } else {
      arg1 = *((gnc_numeric *)(argp1));
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntryComputeValue" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncEntryComputeValue" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gncEntryComputeValue" "', argument " "3"" of type '" "GncTaxTable const *""'"); 
  }
  arg3 = (GncTaxTable *)(argp3);
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  {
    res5 = SWIG_ConvertPtr(swig_obj[4], &argp5, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res5)) {
      SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "gncEntryComputeValue" "', argument " "5"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp5) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncEntryComputeValue" "', argument " "5"" of type '" "gnc_numeric""'");
    } else {
      arg5 = *((gnc_numeric *)(argp5));
    }
  }
  ecode6 = SWIG_AsVal_int(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "gncEntryComputeValue" "', argument " "6"" of type '" "GncAmountType""'");
  } 
  arg6 = (GncAmountType)(val6);
  ecode7 = SWIG_AsVal_int(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "gncEntryComputeValue" "', argument " "7"" of type '" "GncDiscountHow""'");
  } 
  arg7 = (GncDiscountHow)(val7);
  ecode8 = SWIG_AsVal_int(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "gncEntryComputeValue" "', argument " "8"" of type '" "int""'");
  } 
  arg8 = (int)(val8);
  res9 = SWIG_ConvertPtr(swig_obj[8], &argp9,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res9)) {
    SWIG_exception_fail(SWIG_ArgError(res9), "in method '" "gncEntryComputeValue" "', argument " "9"" of type '" "gnc_numeric *""'"); 
  }
  arg9 = (gnc_numeric *)(argp9);
  res10 = SWIG_ConvertPtr(swig_obj[9], &argp10,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res10)) {
    SWIG_exception_fail(SWIG_ArgError(res10), "in method '" "gncEntryComputeValue" "', argument " "10"" of type '" "gnc_numeric *""'"); 
  }
  arg10 = (gnc_numeric *)(argp10);
  res11 = SWIG_ConvertPtr(swig_obj[10], &argp11,SWIGTYPE_p_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res11)) {
    SWIG_exception_fail(SWIG_ArgError(res11), "in method '" "gncEntryComputeValue" "', argument " "11"" of type '" "GList **""'"); 
  }
  arg11 = (GList **)(argp11);
  gncEntryComputeValue(arg1,arg2,(struct _gncTaxTable const *)arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetOrder(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncOrder *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetOrder" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (GncOrder *)gncEntryGetOrder((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GncOrder, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetInvoice(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncInvoice *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetInvoice" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (GncInvoice *)gncEntryGetInvoice((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncInvoice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryGetBill(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncInvoice *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryGetBill" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = (GncInvoice *)gncEntryGetBill((struct _gncEntry const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncInvoice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryLookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GncEntry *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryLookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryLookup" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntryLookup" "', argument " "2"" of type '" "GncGUID const *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = (GncEntry *)gncEntryLookup((QofBook const *)arg1,(struct _gncGuid const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncEntry, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryIsOpen(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryIsOpen" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  result = gncEntryIsOpen((struct _gncEntry const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryBeginEdit" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  gncEntryBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryCommitEdit" "', argument " "1"" of type '" "GncEntry *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  gncEntryCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncEntryCompare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncEntry *arg1 = (GncEntry *) 0 ;
  GncEntry *arg2 = (GncEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncEntryCompare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncEntryCompare" "', argument " "1"" of type '" "GncEntry const *""'"); 
  }
  arg1 = (GncEntry *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncEntry, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncEntryCompare" "', argument " "2"" of type '" "GncEntry const *""'"); 
  }
  arg2 = (GncEntry *)(argp2);
  result = (int)gncEntryCompare((struct _gncEntry const *)arg1,(struct _gncEntry const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_taxtable_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_taxtable_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_taxtable_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAmountTypeToString(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncAmountType arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gncAmountTypeToString" "', argument " "1"" of type '" "GncAmountType""'");
  } 
  arg1 = (GncAmountType)(val1);
  result = (char *)gncAmountTypeToString(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAmountStringToType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  GncAmountType *arg2 = (GncAmountType *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAmountStringToType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAmountStringToType" "', argument " "1"" of type '" "char const *""'");
  }
  arg1 = (char *)(buf1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GncAmountType, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAmountStringToType" "', argument " "2"" of type '" "GncAmountType *""'"); 
  }
  arg2 = (GncAmountType *)(argp2);
  result = gncAmountStringToType((char const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxIncludedTypeToString(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxIncluded arg1 ;
  int val1 ;
  int ecode1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  ecode1 = SWIG_AsVal_int(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "gncTaxIncludedTypeToString" "', argument " "1"" of type '" "GncTaxIncluded""'");
  } 
  arg1 = (GncTaxIncluded)(val1);
  result = (char *)gncTaxIncludedTypeToString(arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxIncludedStringToType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  char *arg1 = (char *) 0 ;
  GncTaxIncluded *arg2 = (GncTaxIncluded *) 0 ;
  int res1 ;
  char *buf1 = 0 ;
  int alloc1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxIncludedStringToType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_AsCharPtrAndSize(swig_obj[0], &buf1, NULL, &alloc1);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxIncludedStringToType" "', argument " "1"" of type '" "char const *""'");
  }
  arg1 = (char *)(buf1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GncTaxIncluded, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxIncludedStringToType" "', argument " "2"" of type '" "GncTaxIncluded *""'"); 
  }
  arg2 = (GncTaxIncluded *)(argp2);
  result = gncTaxIncludedStringToType((char const *)arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return resultobj;
fail:
  if (alloc1 == SWIG_NEWOBJ) free((char*)buf1);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableCreate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncTaxTable *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableCreate" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GncTaxTable *)gncTaxTableCreate(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncTaxTable, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableDestroy" "', argument " "1"" of type '" "GncTaxTable *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  gncTaxTableDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableEntryCreate(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTableEntry *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableEntryCreate", 0, 0, 0)) SWIG_fail;
  result = (GncTaxTableEntry *)gncTaxTableEntryCreate();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableEntryDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTableEntry *arg1 = (GncTaxTableEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableEntryDestroy" "', argument " "1"" of type '" "GncTaxTableEntry *""'"); 
  }
  arg1 = (GncTaxTableEntry *)(argp1);
  gncTaxTableEntryDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableSetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableSetName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableSetName" "', argument " "1"" of type '" "GncTaxTable *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxTableSetName" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gncTaxTableSetName(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableIncRef(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableIncRef" "', argument " "1"" of type '" "GncTaxTable *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  gncTaxTableIncRef(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableDecRef(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableDecRef" "', argument " "1"" of type '" "GncTaxTable *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  gncTaxTableDecRef(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableEntrySetAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTableEntry *arg1 = (GncTaxTableEntry *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableEntrySetAccount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableEntrySetAccount" "', argument " "1"" of type '" "GncTaxTableEntry *""'"); 
  }
  arg1 = (GncTaxTableEntry *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxTableEntrySetAccount" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  gncTaxTableEntrySetAccount(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableEntrySetType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTableEntry *arg1 = (GncTaxTableEntry *) 0 ;
  GncAmountType arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableEntrySetType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableEntrySetType" "', argument " "1"" of type '" "GncTaxTableEntry *""'"); 
  }
  arg1 = (GncTaxTableEntry *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncTaxTableEntrySetType" "', argument " "2"" of type '" "GncAmountType""'");
  } 
  arg2 = (GncAmountType)(val2);
  gncTaxTableEntrySetType(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableEntrySetAmount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTableEntry *arg1 = (GncTaxTableEntry *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableEntrySetAmount", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableEntrySetAmount" "', argument " "1"" of type '" "GncTaxTableEntry *""'"); 
  }
  arg1 = (GncTaxTableEntry *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxTableEntrySetAmount" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncTaxTableEntrySetAmount" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gncTaxTableEntrySetAmount(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableAddEntry(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  GncTaxTableEntry *arg2 = (GncTaxTableEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableAddEntry", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableAddEntry" "', argument " "1"" of type '" "GncTaxTable *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxTableAddEntry" "', argument " "2"" of type '" "GncTaxTableEntry *""'"); 
  }
  arg2 = (GncTaxTableEntry *)(argp2);
  gncTaxTableAddEntry(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableRemoveEntry(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  GncTaxTableEntry *arg2 = (GncTaxTableEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableRemoveEntry", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableRemoveEntry" "', argument " "1"" of type '" "GncTaxTable *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxTableRemoveEntry" "', argument " "2"" of type '" "GncTaxTableEntry *""'"); 
  }
  arg2 = (GncTaxTableEntry *)(argp2);
  gncTaxTableRemoveEntry(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableChanged(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableChanged" "', argument " "1"" of type '" "GncTaxTable *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  gncTaxTableChanged(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableBeginEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableBeginEdit" "', argument " "1"" of type '" "GncTaxTable *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  gncTaxTableBeginEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableCommitEdit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableCommitEdit" "', argument " "1"" of type '" "GncTaxTable *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  gncTaxTableCommitEdit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  GncTaxTable *arg2 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableEqual", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableEqual" "', argument " "1"" of type '" "GncTaxTable const *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxTableEqual" "', argument " "2"" of type '" "GncTaxTable const *""'"); 
  }
  arg2 = (GncTaxTable *)(argp2);
  result = gncTaxTableEqual((struct _gncTaxTable const *)arg1,(struct _gncTaxTable const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableLookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  GncGUID *arg2 = (GncGUID *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GncTaxTable *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableLookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableLookup" "', argument " "1"" of type '" "QofBook const *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxTableLookup" "', argument " "2"" of type '" "GncGUID const *""'"); 
  }
  arg2 = (GncGUID *)(argp2);
  result = (GncTaxTable *)gncTaxTableLookup((QofBook const *)arg1,(struct _gncGuid const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncTaxTable, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableLookupByName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  GncTaxTable *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableLookupByName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableLookupByName" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxTableLookupByName" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  result = (GncTaxTable *)gncTaxTableLookupByName(arg1,(char const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableGetDefault(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  GncOwnerType arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  GncTaxTable *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableGetDefault", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableGetDefault" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gncTaxTableGetDefault" "', argument " "2"" of type '" "GncOwnerType""'");
  } 
  arg2 = (GncOwnerType)(val2);
  result = (GncTaxTable *)gncTaxTableGetDefault(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncTaxTable, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableGetTables(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncTaxTableList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableGetTables" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GncTaxTableList *)gncTaxTableGetTables(arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableGetName(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableGetName" "', argument " "1"" of type '" "GncTaxTable const *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  result = (char *)gncTaxTableGetName((struct _gncTaxTable const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableGetParent(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncTaxTable *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableGetParent" "', argument " "1"" of type '" "GncTaxTable const *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  result = (GncTaxTable *)gncTaxTableGetParent((struct _gncTaxTable const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncTaxTable, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableReturnChild(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  GncTaxTable *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableReturnChild", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableReturnChild" "', argument " "1"" of type '" "GncTaxTable *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = (GncTaxTable *)gncTaxTableReturnChild(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncTaxTable, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableGetEntries(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncTaxTableEntryList *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableGetEntries" "', argument " "1"" of type '" "GncTaxTable const *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  result = (GncTaxTableEntryList *)gncTaxTableGetEntries((struct _gncTaxTable const *)arg1);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableGetRefcount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gint64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableGetRefcount" "', argument " "1"" of type '" "GncTaxTable const *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  result = gncTaxTableGetRefcount((struct _gncTaxTable const *)arg1);
  resultobj = SWIG_From_long_SS_long((long long)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableLastModifiedSecs(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableLastModifiedSecs" "', argument " "1"" of type '" "GncTaxTable const *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  result = gncTaxTableLastModifiedSecs((struct _gncTaxTable const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableEntryGetAccount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTableEntry *arg1 = (GncTaxTableEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableEntryGetAccount" "', argument " "1"" of type '" "GncTaxTableEntry const *""'"); 
  }
  arg1 = (GncTaxTableEntry *)(argp1);
  result = (Account *)gncTaxTableEntryGetAccount((struct _gncTaxTableEntry const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableEntryGetType(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTableEntry *arg1 = (GncTaxTableEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GncAmountType result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableEntryGetType" "', argument " "1"" of type '" "GncTaxTableEntry const *""'"); 
  }
  arg1 = (GncTaxTableEntry *)(argp1);
  result = (GncAmountType)gncTaxTableEntryGetType((struct _gncTaxTableEntry const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableEntryGetAmount(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTableEntry *arg1 = (GncTaxTableEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableEntryGetAmount" "', argument " "1"" of type '" "GncTaxTableEntry const *""'"); 
  }
  arg1 = (GncTaxTableEntry *)(argp1);
  result = gncTaxTableEntryGetAmount((struct _gncTaxTableEntry const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableCompare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTable *arg1 = (GncTaxTable *) 0 ;
  GncTaxTable *arg2 = (GncTaxTable *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableCompare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableCompare" "', argument " "1"" of type '" "GncTaxTable const *""'"); 
  }
  arg1 = (GncTaxTable *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncTaxTable, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxTableCompare" "', argument " "2"" of type '" "GncTaxTable const *""'"); 
  }
  arg2 = (GncTaxTable *)(argp2);
  result = (int)gncTaxTableCompare((struct _gncTaxTable const *)arg1,(struct _gncTaxTable const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableEntryCompare(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTableEntry *arg1 = (GncTaxTableEntry *) 0 ;
  GncTaxTableEntry *arg2 = (GncTaxTableEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableEntryCompare", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableEntryCompare" "', argument " "1"" of type '" "GncTaxTableEntry const *""'"); 
  }
  arg1 = (GncTaxTableEntry *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxTableEntryCompare" "', argument " "2"" of type '" "GncTaxTableEntry const *""'"); 
  }
  arg2 = (GncTaxTableEntry *)(argp2);
  result = (int)gncTaxTableEntryCompare((struct _gncTaxTableEntry const *)arg1,(struct _gncTaxTableEntry const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncTaxTableEntryEqual(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncTaxTableEntry *arg1 = (GncTaxTableEntry *) 0 ;
  GncTaxTableEntry *arg2 = (GncTaxTableEntry *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gncTaxTableEntryEqual", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncTaxTableEntryEqual" "', argument " "1"" of type '" "GncTaxTableEntry const *""'"); 
  }
  arg1 = (GncTaxTableEntry *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gncTaxTableEntry, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncTaxTableEntryEqual" "', argument " "2"" of type '" "GncTaxTableEntry const *""'"); 
  }
  arg2 = (GncTaxTableEntry *)(argp2);
  result = gncTaxTableEntryEqual((struct _gncTaxTableEntry const *)arg1,(struct _gncTaxTableEntry const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gncAccountValue_account_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gncAccountValue *arg1 = (struct _gncAccountValue *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "_gncAccountValue_account_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAccountValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gncAccountValue_account_set" "', argument " "1"" of type '" "struct _gncAccountValue *""'"); 
  }
  arg1 = (struct _gncAccountValue *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gncAccountValue_account_set" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  if (arg1) (arg1)->account = arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gncAccountValue_account_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gncAccountValue *arg1 = (struct _gncAccountValue *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Account *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAccountValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gncAccountValue_account_get" "', argument " "1"" of type '" "struct _gncAccountValue *""'"); 
  }
  arg1 = (struct _gncAccountValue *)(argp1);
  result = (Account *) ((arg1)->account);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Account, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gncAccountValue_value_set(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gncAccountValue *arg1 = (struct _gncAccountValue *) 0 ;
  gnc_numeric *arg2 = (gnc_numeric *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "_gncAccountValue_value_set", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAccountValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gncAccountValue_value_set" "', argument " "1"" of type '" "struct _gncAccountValue *""'"); 
  }
  arg1 = (struct _gncAccountValue *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p__gnc_numeric, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "_gncAccountValue_value_set" "', argument " "2"" of type '" "gnc_numeric *""'"); 
  }
  arg2 = (gnc_numeric *)(argp2);
  if (arg1) (arg1)->value = *arg2;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap__gncAccountValue_value_get(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gncAccountValue *arg1 = (struct _gncAccountValue *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAccountValue, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "_gncAccountValue_value_get" "', argument " "1"" of type '" "struct _gncAccountValue *""'"); 
  }
  arg1 = (struct _gncAccountValue *)(argp1);
  result = (gnc_numeric *)& ((arg1)->value);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gnc_numeric, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new__gncAccountValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gncAccountValue *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "new__gncAccountValue", 0, 0, 0)) SWIG_fail;
  result = (struct _gncAccountValue *)calloc(1, sizeof(struct _gncAccountValue));
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncAccountValue, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete__gncAccountValue(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  struct _gncAccountValue *arg1 = (struct _gncAccountValue *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncAccountValue, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete__gncAccountValue" "', argument " "1"" of type '" "struct _gncAccountValue *""'"); 
  }
  arg1 = (struct _gncAccountValue *)(argp1);
  free((char *) arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_gncAccountValue_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p__gncAccountValue, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_gncAccountValue_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_gncAccountValueAdd(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GList *arg1 = (GList *) 0 ;
  Account *arg2 = (Account *) 0 ;
  gnc_numeric arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  GList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAccountValueAdd", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAccountValueAdd" "', argument " "1"" of type '" "GList *""'"); 
  }
  arg1 = (GList *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAccountValueAdd" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gncAccountValueAdd" "', argument " "3"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gncAccountValueAdd" "', argument " "3"" of type '" "gnc_numeric""'");
    } else {
      arg3 = *((gnc_numeric *)(argp3));
    }
  }
  result = (GList *)gncAccountValueAdd(arg1,arg2,arg3);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAccountValueAddList(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GList *arg1 = (GList *) 0 ;
  GList *arg2 = (GList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gncAccountValueAddList", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAccountValueAddList" "', argument " "1"" of type '" "GList *""'"); 
  }
  arg1 = (GList *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gncAccountValueAddList" "', argument " "2"" of type '" "GList *""'"); 
  }
  arg2 = (GList *)(argp2);
  result = (GList *)gncAccountValueAddList(arg1,arg2);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAccountValueTotal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GList *arg1 = (GList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAccountValueTotal" "', argument " "1"" of type '" "GList *""'"); 
  }
  arg1 = (GList *)(argp1);
  result = gncAccountValueTotal(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gncAccountValueDestroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GList *arg1 = (GList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gncAccountValueDestroy" "', argument " "1"" of type '" "GList *""'"); 
  }
  arg1 = (GList *)(argp1);
  gncAccountValueDestroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_search_customer_on_id(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  gchar *arg2 = (gchar *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  GncCustomer *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_search_customer_on_id", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_search_customer_on_id" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_search_customer_on_id" "', argument " "2"" of type '" "gchar const *""'");
  }
  arg2 = (gchar *)(buf2);
  result = (GncCustomer *)gnc_search_customer_on_id(arg1,(gchar const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncCustomer, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_search_invoice_on_id(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  gchar *arg2 = (gchar *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  GncInvoice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_search_invoice_on_id", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_search_invoice_on_id" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_search_invoice_on_id" "', argument " "2"" of type '" "gchar const *""'");
  }
  arg2 = (gchar *)(buf2);
  result = (GncInvoice *)gnc_search_invoice_on_id(arg1,(gchar const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_search_bill_on_id(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  gchar *arg2 = (gchar *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  GncInvoice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_search_bill_on_id", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_search_bill_on_id" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_search_bill_on_id" "', argument " "2"" of type '" "gchar const *""'");
  }
  arg2 = (gchar *)(buf2);
  result = (GncInvoice *)gnc_search_bill_on_id(arg1,(gchar const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncInvoice, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_search_vendor_on_id(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  gchar *arg2 = (gchar *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  GncVendor *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_search_vendor_on_id", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_search_vendor_on_id" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_search_vendor_on_id" "', argument " "2"" of type '" "gchar const *""'");
  }
  arg2 = (gchar *)(buf2);
  result = (GncVendor *)gnc_search_vendor_on_id(arg1,(gchar const *)arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p__gncVendor, 0 |  0 );
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_price_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_get_type(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GType result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_get_type", 0, 0, 0)) SWIG_fail;
  result = gnc_pricedb_get_type();
  resultobj = SWIG_NewPointerObj((GType *)memcpy((GType *)calloc(1,sizeof(GType)),&result,sizeof(GType)), SWIGTYPE_p_GType, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_create(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCPrice *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_create" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GNCPrice *)gnc_price_create(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPrice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_clone(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GNCPrice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_clone", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_clone" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_clone" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  result = (GNCPrice *)gnc_price_clone(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPrice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_invert(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCPrice *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_invert" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  result = (GNCPrice *)gnc_price_invert(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPrice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_ref(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_ref" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  gnc_price_ref(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_unref(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_unref" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  gnc_price_unref(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_begin_edit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_begin_edit" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  gnc_price_begin_edit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_commit_edit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_commit_edit" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  gnc_price_commit_edit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_set_commodity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_set_commodity", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_set_commodity" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_set_commodity" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  gnc_price_set_commodity(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_set_currency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_set_currency", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_set_currency" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_set_currency" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  gnc_price_set_currency(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_set_time64(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  time64 arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_set_time64", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_set_time64" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[1]) && !PyInt_Check(swig_obj[1])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[1])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[1]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[1]),
        PyDateTime_DATE_GET_HOUR(swig_obj[1]),
        PyDateTime_GET_DAY(swig_obj[1]),
        PyDateTime_GET_MONTH(swig_obj[1]) - 1,
        PyDateTime_GET_YEAR(swig_obj[1]) - 1900
      };
      arg2 = gnc_mktime(&time);
    } else {
      arg2 = PyInt_AsLong(swig_obj[1]);
    }
  }
  gnc_price_set_time64(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_set_source(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  PriceSource arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_set_source", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_set_source" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "gnc_price_set_source" "', argument " "2"" of type '" "PriceSource""'");
  } 
  arg2 = (PriceSource)(val2);
  gnc_price_set_source(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_set_source_string(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_set_source_string", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_set_source_string" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_set_source_string" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gnc_price_set_source_string(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_set_typestr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  char *arg2 = (char *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 ;
  char *buf2 = 0 ;
  int alloc2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_set_typestr", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_set_typestr" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  res2 = SWIG_AsCharPtrAndSize(swig_obj[1], &buf2, NULL, &alloc2);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_set_typestr" "', argument " "2"" of type '" "char const *""'");
  }
  arg2 = (char *)(buf2);
  gnc_price_set_typestr(arg1,(char const *)arg2);
  resultobj = SWIG_Py_Void();
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return resultobj;
fail:
  if (alloc2 == SWIG_NEWOBJ) free((char*)buf2);
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_set_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  gnc_numeric arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_set_value", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_set_value" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_set_value" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_price_set_value" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  gnc_price_set_value(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_lookup(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GncGUID *arg1 = (GncGUID *) 0 ;
  QofBook *arg2 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  GNCPrice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_lookup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p__gncGuid, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_lookup" "', argument " "1"" of type '" "GncGUID const *""'"); 
  }
  arg1 = (GncGUID *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_lookup" "', argument " "2"" of type '" "QofBook *""'"); 
  }
  arg2 = (QofBook *)(argp2);
  result = (GNCPrice *)gnc_price_lookup((struct _gncGuid const *)arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPrice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_get_commodity(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_get_commodity" "', argument " "1"" of type '" "GNCPrice const *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  result = (gnc_commodity *)gnc_price_get_commodity((GNCPrice const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_get_currency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_commodity *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_get_currency" "', argument " "1"" of type '" "GNCPrice const *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  result = (gnc_commodity *)gnc_price_get_currency((GNCPrice const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_commodity, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_get_time64(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  time64 result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_get_time64" "', argument " "1"" of type '" "GNCPrice const *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  result = gnc_price_get_time64((GNCPrice const *)arg1);
  {
    if (result == INT64_MAX) {
      resultobj = Py_None;
    } else {
      PyDateTime_IMPORT;
      struct tm t;
      gnc_localtime_r(&result, &t);
      resultobj = PyDateTime_FromDateAndTime(t.tm_year + 1900, t.tm_mon + 1,
        t.tm_mday, t.tm_hour, t.tm_min,
        t.tm_sec, 0);
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_get_source(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  PriceSource result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_get_source" "', argument " "1"" of type '" "GNCPrice const *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  result = (PriceSource)gnc_price_get_source((GNCPrice const *)arg1);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_get_source_string(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_get_source_string" "', argument " "1"" of type '" "GNCPrice const *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  result = (char *)gnc_price_get_source_string((GNCPrice const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_get_typestr(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  char *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_get_typestr" "', argument " "1"" of type '" "GNCPrice const *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  result = (char *)gnc_price_get_typestr((GNCPrice const *)arg1);
  resultobj = SWIG_FromCharPtr((const char *)result);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_get_value(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_get_value" "', argument " "1"" of type '" "GNCPrice const *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  result = gnc_price_get_value((GNCPrice const *)arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_equal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  GNCPrice *arg2 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_equal", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_equal" "', argument " "1"" of type '" "GNCPrice const *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_equal" "', argument " "2"" of type '" "GNCPrice const *""'"); 
  }
  arg2 = (GNCPrice *)(argp2);
  result = gnc_price_equal((GNCPrice const *)arg1,(GNCPrice const *)arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_print(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPrice *arg1 = (GNCPrice *) 0 ;
  FILE *arg2 = (FILE *) 0 ;
  int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_print", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_print" "', argument " "1"" of type '" "GNCPrice *""'"); 
  }
  arg1 = (GNCPrice *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_FILE, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_print" "', argument " "2"" of type '" "FILE *""'"); 
  }
  arg2 = (FILE *)(argp2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gnc_price_print" "', argument " "3"" of type '" "int""'");
  } 
  arg3 = (int)(val3);
  gnc_price_print(arg1,arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_list_insert(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  PriceList **arg1 = (PriceList **) 0 ;
  GNCPrice *arg2 = (GNCPrice *) 0 ;
  gboolean arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_list_insert", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_list_insert" "', argument " "1"" of type '" "PriceList **""'"); 
  }
  arg1 = (PriceList **)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_list_insert" "', argument " "2"" of type '" "GNCPrice *""'"); 
  }
  arg2 = (GNCPrice *)(argp2);
  {
    if (swig_obj[2] == Py_True)
    arg3 = TRUE;
    else if (swig_obj[2] == Py_False)
    arg3 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = gnc_price_list_insert(arg1,arg2,arg3);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_list_remove(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  PriceList **arg1 = (PriceList **) 0 ;
  GNCPrice *arg2 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_list_remove", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_list_remove" "', argument " "1"" of type '" "PriceList **""'"); 
  }
  arg1 = (PriceList **)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_list_remove" "', argument " "2"" of type '" "GNCPrice *""'"); 
  }
  arg2 = (GNCPrice *)(argp2);
  result = gnc_price_list_remove(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_list_destroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  PriceList *arg1 = (PriceList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_list_destroy" "', argument " "1"" of type '" "PriceList *""'"); 
  }
  arg1 = (PriceList *)(argp1);
  gnc_price_list_destroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_price_list_equal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  PriceList *arg1 = (PriceList *) 0 ;
  PriceList *arg2 = (PriceList *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_price_list_equal", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_price_list_equal" "', argument " "1"" of type '" "PriceList *""'"); 
  }
  arg1 = (PriceList *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_price_list_equal" "', argument " "2"" of type '" "PriceList *""'"); 
  }
  arg2 = (PriceList *)(argp2);
  result = gnc_price_list_equal(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_get_db(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofBook *arg1 = (QofBook *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCPriceDB *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofBook, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_get_db" "', argument " "1"" of type '" "QofBook *""'"); 
  }
  arg1 = (QofBook *)(argp1);
  result = (GNCPriceDB *)gnc_pricedb_get_db(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_collection_get_pricedb(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  QofCollection *arg1 = (QofCollection *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  GNCPriceDB *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_QofCollection_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_collection_get_pricedb" "', argument " "1"" of type '" "QofCollection *""'"); 
  }
  arg1 = (QofCollection *)(argp1);
  result = (GNCPriceDB *)gnc_collection_get_pricedb(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_destroy(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_destroy" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  gnc_pricedb_destroy(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_begin_edit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_begin_edit" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  gnc_pricedb_begin_edit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_commit_edit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_commit_edit" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  gnc_pricedb_commit_edit(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_set_bulk_update(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gboolean arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_set_bulk_update", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_set_bulk_update" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  {
    if (swig_obj[1] == Py_True)
    arg2 = TRUE;
    else if (swig_obj[1] == Py_False)
    arg2 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  gnc_pricedb_set_bulk_update(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_add_price(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  GNCPrice *arg2 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_add_price", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_add_price" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_add_price" "', argument " "2"" of type '" "GNCPrice *""'"); 
  }
  arg2 = (GNCPrice *)(argp2);
  result = gnc_pricedb_add_price(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_remove_price(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  GNCPrice *arg2 = (GNCPrice *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_remove_price", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_remove_price" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCPrice, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_remove_price" "', argument " "2"" of type '" "GNCPrice *""'"); 
  }
  arg2 = (GNCPrice *)(argp2);
  result = gnc_pricedb_remove_price(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_remove_old_prices(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  GList *arg2 = (GList *) 0 ;
  GDate *arg3 = (GDate *) 0 ;
  time64 arg4 ;
  PriceRemoveSourceFlags arg5 ;
  PriceRemoveKeepOptions arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  int val6 ;
  int ecode6 = 0 ;
  PyObject *swig_obj[6] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_remove_old_prices", 6, 6, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_remove_old_prices" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GList, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_remove_old_prices" "', argument " "2"" of type '" "GList *""'"); 
  }
  arg2 = (GList *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_GDate, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_pricedb_remove_old_prices" "', argument " "3"" of type '" "GDate *""'"); 
  }
  arg3 = (GDate *)(argp3);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[3]) && !PyInt_Check(swig_obj[3])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[3])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[3]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[3]),
        PyDateTime_DATE_GET_HOUR(swig_obj[3]),
        PyDateTime_GET_DAY(swig_obj[3]),
        PyDateTime_GET_MONTH(swig_obj[3]) - 1,
        PyDateTime_GET_YEAR(swig_obj[3]) - 1900
      };
      arg4 = gnc_mktime(&time);
    } else {
      arg4 = PyInt_AsLong(swig_obj[3]);
    }
  }
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "gnc_pricedb_remove_old_prices" "', argument " "5"" of type '" "PriceRemoveSourceFlags""'");
  } 
  arg5 = (PriceRemoveSourceFlags)(val5);
  ecode6 = SWIG_AsVal_int(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "gnc_pricedb_remove_old_prices" "', argument " "6"" of type '" "PriceRemoveKeepOptions""'");
  } 
  arg6 = (PriceRemoveKeepOptions)(val6);
  result = gnc_pricedb_remove_old_prices(arg1,arg2,arg3,arg4,arg5,arg6);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_lookup_latest(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  GNCPrice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_lookup_latest", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_lookup_latest" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_lookup_latest" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_pricedb_lookup_latest" "', argument " "3"" of type '" "gnc_commodity const *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  result = (GNCPrice *)gnc_pricedb_lookup_latest(arg1,(gnc_commodity const *)arg2,(gnc_commodity const *)arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPrice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_lookup_latest_any_currency(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  PriceList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_lookup_latest_any_currency", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_lookup_latest_any_currency" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_lookup_latest_any_currency" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  result = (PriceList *)gnc_pricedb_lookup_latest_any_currency(arg1,(gnc_commodity const *)arg2);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_has_prices(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_has_prices", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_has_prices" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_has_prices" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_pricedb_has_prices" "', argument " "3"" of type '" "gnc_commodity const *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  result = gnc_pricedb_has_prices(arg1,(gnc_commodity const *)arg2,(gnc_commodity const *)arg3);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_get_prices(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  PriceList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_get_prices", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_get_prices" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_get_prices" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_pricedb_get_prices" "', argument " "3"" of type '" "gnc_commodity const *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  result = (PriceList *)gnc_pricedb_get_prices(arg1,(gnc_commodity const *)arg2,(gnc_commodity const *)arg3);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_lookup_at_time64(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  time64 arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[4] ;
  GNCPrice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_lookup_at_time64", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_lookup_at_time64" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_lookup_at_time64" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_pricedb_lookup_at_time64" "', argument " "3"" of type '" "gnc_commodity const *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[3]) && !PyInt_Check(swig_obj[3])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[3])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[3]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[3]),
        PyDateTime_DATE_GET_HOUR(swig_obj[3]),
        PyDateTime_GET_DAY(swig_obj[3]),
        PyDateTime_GET_MONTH(swig_obj[3]) - 1,
        PyDateTime_GET_YEAR(swig_obj[3]) - 1900
      };
      arg4 = gnc_mktime(&time);
    } else {
      arg4 = PyInt_AsLong(swig_obj[3]);
    }
  }
  result = (GNCPrice *)gnc_pricedb_lookup_at_time64(arg1,(gnc_commodity const *)arg2,(gnc_commodity const *)arg3,arg4);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPrice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_lookup_day_t64(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  time64 arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[4] ;
  GNCPrice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_lookup_day_t64", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_lookup_day_t64" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_lookup_day_t64" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_pricedb_lookup_day_t64" "', argument " "3"" of type '" "gnc_commodity const *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[3]) && !PyInt_Check(swig_obj[3])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[3])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[3]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[3]),
        PyDateTime_DATE_GET_HOUR(swig_obj[3]),
        PyDateTime_GET_DAY(swig_obj[3]),
        PyDateTime_GET_MONTH(swig_obj[3]) - 1,
        PyDateTime_GET_YEAR(swig_obj[3]) - 1900
      };
      arg4 = gnc_mktime(&time);
    } else {
      arg4 = PyInt_AsLong(swig_obj[3]);
    }
  }
  result = (GNCPrice *)gnc_pricedb_lookup_day_t64(arg1,(gnc_commodity const *)arg2,(gnc_commodity const *)arg3,arg4);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPrice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_lookup_nearest_in_time64(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  time64 arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[4] ;
  GNCPrice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_lookup_nearest_in_time64", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_lookup_nearest_in_time64" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_lookup_nearest_in_time64" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_pricedb_lookup_nearest_in_time64" "', argument " "3"" of type '" "gnc_commodity const *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[3]) && !PyInt_Check(swig_obj[3])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[3])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[3]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[3]),
        PyDateTime_DATE_GET_HOUR(swig_obj[3]),
        PyDateTime_GET_DAY(swig_obj[3]),
        PyDateTime_GET_MONTH(swig_obj[3]) - 1,
        PyDateTime_GET_YEAR(swig_obj[3]) - 1900
      };
      arg4 = gnc_mktime(&time);
    } else {
      arg4 = PyInt_AsLong(swig_obj[3]);
    }
  }
  result = (GNCPrice *)gnc_pricedb_lookup_nearest_in_time64(arg1,(gnc_commodity const *)arg2,(gnc_commodity const *)arg3,arg4);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPrice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_lookup_nearest_in_time_any_currency_t64(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  time64 arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  PriceList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_lookup_nearest_in_time_any_currency_t64", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_lookup_nearest_in_time_any_currency_t64" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_lookup_nearest_in_time_any_currency_t64" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[2]) && !PyInt_Check(swig_obj[2])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[2])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[2]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[2]),
        PyDateTime_DATE_GET_HOUR(swig_obj[2]),
        PyDateTime_GET_DAY(swig_obj[2]),
        PyDateTime_GET_MONTH(swig_obj[2]) - 1,
        PyDateTime_GET_YEAR(swig_obj[2]) - 1900
      };
      arg3 = gnc_mktime(&time);
    } else {
      arg3 = PyInt_AsLong(swig_obj[2]);
    }
  }
  result = (PriceList *)gnc_pricedb_lookup_nearest_in_time_any_currency_t64(arg1,(gnc_commodity const *)arg2,arg3);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_lookup_latest_before_t64(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  time64 arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[4] ;
  GNCPrice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_lookup_latest_before_t64", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_lookup_latest_before_t64" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_lookup_latest_before_t64" "', argument " "2"" of type '" "gnc_commodity *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_pricedb_lookup_latest_before_t64" "', argument " "3"" of type '" "gnc_commodity *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[3]) && !PyInt_Check(swig_obj[3])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[3])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[3]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[3]),
        PyDateTime_DATE_GET_HOUR(swig_obj[3]),
        PyDateTime_GET_DAY(swig_obj[3]),
        PyDateTime_GET_MONTH(swig_obj[3]) - 1,
        PyDateTime_GET_YEAR(swig_obj[3]) - 1900
      };
      arg4 = gnc_mktime(&time);
    } else {
      arg4 = PyInt_AsLong(swig_obj[3]);
    }
  }
  result = (GNCPrice *)gnc_pricedb_lookup_latest_before_t64(arg1,arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPrice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_lookup_latest_before_any_currency_t64(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  time64 arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[3] ;
  PriceList *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_lookup_latest_before_any_currency_t64", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_lookup_latest_before_any_currency_t64" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_lookup_latest_before_any_currency_t64" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[2]) && !PyInt_Check(swig_obj[2])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[2])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[2]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[2]),
        PyDateTime_DATE_GET_HOUR(swig_obj[2]),
        PyDateTime_GET_DAY(swig_obj[2]),
        PyDateTime_GET_MONTH(swig_obj[2]) - 1,
        PyDateTime_GET_YEAR(swig_obj[2]) - 1900
      };
      arg3 = gnc_mktime(&time);
    } else {
      arg3 = PyInt_AsLong(swig_obj[2]);
    }
  }
  result = (PriceList *)gnc_pricedb_lookup_latest_before_any_currency_t64(arg1,(gnc_commodity const *)arg2,arg3);
  {
    gpointer data;
    GList *l;
    PyObject *list = PyList_New(0);
    for (l = result; l != NULL; l = l->next)
    {
      data = l->data;
      if (GNC_IS_ACCOUNT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Account, 0));
      else if (GNC_IS_SPLIT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Split, 0));
      else if (GNC_IS_TRANSACTION(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_Transaction, 0));
      else if (GNC_IS_COMMODITY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity, 0));
      else if (GNC_IS_COMMODITY_NAMESPACE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_gnc_commodity_namespace, 0));
      else if (GNC_IS_LOT(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCLot, 0));
      else if (GNC_IS_PRICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_GNCPrice, 0));
      else if (GNC_IS_INVOICE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncInvoice, 0));
      else if (GNC_IS_ENTRY(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEntry, 0));
      else if (GNC_IS_CUSTOMER(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncCustomer, 0));
      else if (GNC_IS_VENDOR(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncVendor, 0));
      else if (GNC_IS_EMPLOYEE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncEmployee, 0));
      else if (GNC_IS_JOB(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncJob, 0));
      else if (GNC_IS_TAXTABLE(data))
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gncTaxTable, 0));
      else if (SWIGTYPE_p_GList == SWIGTYPE_p_GList)
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p__gnc_monetary, 0));
      else
      PyList_Append(list, SWIG_NewPointerObj(data, SWIGTYPE_p_void, 0));
    }
    resultobj = list;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_convert_balance_latest_price(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_numeric arg2 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  gnc_commodity *arg4 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  PyObject *swig_obj[4] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_convert_balance_latest_price", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_convert_balance_latest_price" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_convert_balance_latest_price" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_pricedb_convert_balance_latest_price" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_pricedb_convert_balance_latest_price" "', argument " "3"" of type '" "gnc_commodity const *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gnc_pricedb_convert_balance_latest_price" "', argument " "4"" of type '" "gnc_commodity const *""'"); 
  }
  arg4 = (gnc_commodity *)(argp4);
  result = gnc_pricedb_convert_balance_latest_price(arg1,arg2,(gnc_commodity const *)arg3,(gnc_commodity const *)arg4);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_convert_balance_nearest_price_t64(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_numeric arg2 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  gnc_commodity *arg4 = (gnc_commodity *) 0 ;
  time64 arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  PyObject *swig_obj[5] ;
  gnc_numeric result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_convert_balance_nearest_price_t64", 5, 5, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_convert_balance_nearest_price_t64" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_convert_balance_nearest_price_t64" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "gnc_pricedb_convert_balance_nearest_price_t64" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_pricedb_convert_balance_nearest_price_t64" "', argument " "3"" of type '" "gnc_commodity const *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "gnc_pricedb_convert_balance_nearest_price_t64" "', argument " "4"" of type '" "gnc_commodity const *""'"); 
  }
  arg4 = (gnc_commodity *)(argp4);
  {
    PyDateTime_IMPORT;
    
    if (!PyDate_Check(swig_obj[4]) && !PyInt_Check(swig_obj[4])) {
      PyErr_SetString(PyExc_ValueError,"date, datetime or integer expected");
      return NULL;
    }
    
    if (PyDate_Check(swig_obj[4])) {
      struct tm time = {
        PyDateTime_DATE_GET_SECOND(swig_obj[4]),
        PyDateTime_DATE_GET_MINUTE(swig_obj[4]),
        PyDateTime_DATE_GET_HOUR(swig_obj[4]),
        PyDateTime_GET_DAY(swig_obj[4]),
        PyDateTime_GET_MONTH(swig_obj[4]) - 1,
        PyDateTime_GET_YEAR(swig_obj[4]) - 1900
      };
      arg5 = gnc_mktime(&time);
    } else {
      arg5 = PyInt_AsLong(swig_obj[4]);
    }
  }
  result = gnc_pricedb_convert_balance_nearest_price_t64(arg1,arg2,(gnc_commodity const *)arg3,(gnc_commodity const *)arg4,arg5);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_foreach_price(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  GncPriceForeachFunc arg2 = (GncPriceForeachFunc) 0 ;
  gpointer arg3 = (gpointer) 0 ;
  gboolean arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 ;
  PyObject *swig_obj[4] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_foreach_price", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_foreach_price" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  {
    int res = SWIG_ConvertFunctionPtr(swig_obj[1], (void**)(&arg2), SWIGTYPE_p_f_p_GNCPrice_p_void__gboolean);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in method '" "gnc_pricedb_foreach_price" "', argument " "2"" of type '" "GncPriceForeachFunc""'"); 
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2],SWIG_as_voidptrptr(&arg3), 0, 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "gnc_pricedb_foreach_price" "', argument " "3"" of type '" "gpointer""'"); 
  }
  {
    if (swig_obj[3] == Py_True)
    arg4 = TRUE;
    else if (swig_obj[3] == Py_False)
    arg4 = FALSE;
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "Python object passed to a gboolean argument was not True "
        "or False" );
      return NULL;
    }
  }
  result = gnc_pricedb_foreach_price(arg1,arg2,arg3,arg4);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_num_prices(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  int result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_num_prices", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_num_prices" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_num_prices" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  result = (int)gnc_pricedb_num_prices(arg1,(gnc_commodity const *)arg2);
  resultobj = SWIG_From_int((int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_nth_price(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  gnc_commodity *arg2 = (gnc_commodity *) 0 ;
  int arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  GNCPrice *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_nth_price", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_nth_price" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_nth_price" "', argument " "2"" of type '" "gnc_commodity const *""'"); 
  }
  arg2 = (gnc_commodity *)(argp2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "gnc_pricedb_nth_price" "', argument " "3"" of type '" "int""'");
  } 
  arg3 = (int)(val3);
  result = (GNCPrice *)gnc_pricedb_nth_price(arg1,(gnc_commodity const *)arg2,arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCPrice, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_nth_price_reset_cache(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_nth_price_reset_cache" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  gnc_pricedb_nth_price_reset_cache(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_get_num_prices(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  guint result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_get_num_prices" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  result = gnc_pricedb_get_num_prices(arg1);
  resultobj = SWIG_From_unsigned_SS_int((unsigned int)(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_equal(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  GNCPriceDB *arg2 = (GNCPriceDB *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  gboolean result;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_equal", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_equal" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_equal" "', argument " "2"" of type '" "GNCPriceDB *""'"); 
  }
  arg2 = (GNCPriceDB *)(argp2);
  result = gnc_pricedb_equal(arg1,arg2);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_gnc_pricedb_print_contents(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCPriceDB *arg1 = (GNCPriceDB *) 0 ;
  FILE *arg2 = (FILE *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "gnc_pricedb_print_contents", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_gnc_price_db_s, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "gnc_pricedb_print_contents" "', argument " "1"" of type '" "GNCPriceDB *""'"); 
  }
  arg1 = (GNCPriceDB *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_FILE, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "gnc_pricedb_print_contents" "', argument " "2"" of type '" "FILE *""'"); 
  }
  arg2 = (FILE *)(argp2);
  gnc_pricedb_print_contents(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetCapGains(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gnc_numeric result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetCapGains" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitGetCapGains(arg1);
  resultobj = SWIG_NewPointerObj((gnc_numeric *)memcpy((gnc_numeric *)calloc(1,sizeof(gnc_numeric)),&result,sizeof(gnc_numeric)), SWIGTYPE_p__gnc_numeric, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountHasTrades(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountHasTrades" "', argument " "1"" of type '" "Account const *""'"); 
  }
  arg1 = (Account *)(argp1);
  result = xaccAccountHasTrades((Account const *)arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountFindEarliestOpenLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_numeric arg2 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  GNCLot *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountFindEarliestOpenLot", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountFindEarliestOpenLot" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountFindEarliestOpenLot" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccAccountFindEarliestOpenLot" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountFindEarliestOpenLot" "', argument " "3"" of type '" "gnc_commodity *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  result = (GNCLot *)xaccAccountFindEarliestOpenLot(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCLot, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountFindLatestOpenLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  gnc_numeric arg2 ;
  gnc_commodity *arg3 = (gnc_commodity *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  GNCLot *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccAccountFindLatestOpenLot", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountFindLatestOpenLot" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p__gnc_numeric,  0 );
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccAccountFindLatestOpenLot" "', argument " "2"" of type '" "gnc_numeric""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "xaccAccountFindLatestOpenLot" "', argument " "2"" of type '" "gnc_numeric""'");
    } else {
      arg2 = *((gnc_numeric *)(argp2));
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3,SWIGTYPE_p_gnc_commodity, 0 |  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "xaccAccountFindLatestOpenLot" "', argument " "3"" of type '" "gnc_commodity *""'"); 
  }
  arg3 = (gnc_commodity *)(argp3);
  result = (GNCLot *)xaccAccountFindLatestOpenLot(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_GNCLot, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetCapGainsSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Split *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetCapGainsSplit" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (Split *)xaccSplitGetCapGainsSplit((Split const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitGetGainsSourceSplit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Split *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitGetGainsSourceSplit" "', argument " "1"" of type '" "Split const *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = (Split *)xaccSplitGetGainsSourceSplit((Split const *)arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitAssign(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitAssign" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  result = xaccSplitAssign(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitAssignToLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  GNCLot *arg2 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Split *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitAssignToLot", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitAssignToLot" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitAssignToLot" "', argument " "2"" of type '" "GNCLot *""'"); 
  }
  arg2 = (GNCLot *)(argp2);
  result = (Split *)xaccSplitAssignToLot(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_Split, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccSplitComputeCapGains(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Split *arg1 = (Split *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccSplitComputeCapGains", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Split, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccSplitComputeCapGains" "', argument " "1"" of type '" "Split *""'"); 
  }
  arg1 = (Split *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccSplitComputeCapGains" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  xaccSplitComputeCapGains(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccLotComputeCapGains(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  Account *arg2 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "xaccLotComputeCapGains", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccLotComputeCapGains" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "xaccLotComputeCapGains" "', argument " "2"" of type '" "Account *""'"); 
  }
  arg2 = (Account *)(argp2);
  xaccLotComputeCapGains(arg1,arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccScrubLot(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  GNCLot *arg1 = (GNCLot *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  gboolean result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_GNCLot, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccScrubLot" "', argument " "1"" of type '" "GNCLot *""'"); 
  }
  arg1 = (GNCLot *)(argp1);
  result = xaccScrubLot(arg1);
  {
    if (result == TRUE)
    {
      resultobj = Py_True;
      Py_INCREF(resultobj);
    }
    else if (result == FALSE)
    {
      resultobj = Py_False;
      Py_INCREF(resultobj);
    }
    else
    {
      PyErr_SetString(
        PyExc_ValueError,
        "function returning gboolean returned a value that wasn't "
        "TRUE or FALSE.");
      return NULL;
    }
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountScrubLots(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountScrubLots" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  xaccAccountScrubLots(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_xaccAccountTreeScrubLots(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *resultobj = 0;
  Account *arg1 = (Account *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_Account, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "xaccAccountTreeScrubLots" "', argument " "1"" of type '" "Account *""'"); 
  }
  arg1 = (Account *)(argp1);
  xaccAccountTreeScrubLots(arg1);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


static PyMethodDef SwigMethods[] = {
	 { "SWIG_PyInstanceMethod_New", SWIG_PyInstanceMethod_New, METH_O, NULL},
	 { "gncSplitGetGUID", _wrap_gncSplitGetGUID, METH_O, "gncSplitGetGUID(Split * x) -> GncGUID"},
	 { "gncTransGetGUID", _wrap_gncTransGetGUID, METH_O, "gncTransGetGUID(Transaction * x) -> GncGUID"},
	 { "gncAccountGetGUID", _wrap_gncAccountGetGUID, METH_O, "gncAccountGetGUID(Account * x) -> GncGUID"},
	 { "gnc_split_get_type", _wrap_gnc_split_get_type, METH_NOARGS, "gnc_split_get_type() -> GType"},
	 { "xaccSplitConvertAmount", _wrap_xaccSplitConvertAmount, METH_VARARGS, "xaccSplitConvertAmount(Split const * split, Account const * account) -> _gnc_numeric"},
	 { "xaccMallocSplit", _wrap_xaccMallocSplit, METH_O, "xaccMallocSplit(QofBook * book) -> Split *"},
	 { "xaccSplitReinit", _wrap_xaccSplitReinit, METH_O, "xaccSplitReinit(Split * split)"},
	 { "xaccSplitDestroy", _wrap_xaccSplitDestroy, METH_O, "xaccSplitDestroy(Split * split) -> gboolean"},
	 { "xaccSplitCopyOnto", _wrap_xaccSplitCopyOnto, METH_VARARGS, "xaccSplitCopyOnto(Split const * from_split, Split * to_split)"},
	 { "xaccSplitGetBook", _wrap_xaccSplitGetBook, METH_O, "xaccSplitGetBook(Split const * split) -> QofBook *"},
	 { "xaccSplitGetAccount", _wrap_xaccSplitGetAccount, METH_O, "xaccSplitGetAccount(Split const * split) -> Account *"},
	 { "xaccSplitSetAccount", _wrap_xaccSplitSetAccount, METH_VARARGS, "xaccSplitSetAccount(Split * s, Account * acc)"},
	 { "xaccSplitGetParent", _wrap_xaccSplitGetParent, METH_O, "xaccSplitGetParent(Split const * split) -> Transaction *"},
	 { "xaccSplitSetParent", _wrap_xaccSplitSetParent, METH_VARARGS, "xaccSplitSetParent(Split * split, Transaction * trans)"},
	 { "xaccSplitGetLot", _wrap_xaccSplitGetLot, METH_O, "xaccSplitGetLot(Split const * split) -> GNCLot *"},
	 { "xaccSplitSetLot", _wrap_xaccSplitSetLot, METH_VARARGS, "xaccSplitSetLot(Split * split, GNCLot * lot)"},
	 { "xaccSplitSetMemo", _wrap_xaccSplitSetMemo, METH_VARARGS, "xaccSplitSetMemo(Split * split, char const * memo)"},
	 { "xaccSplitGetMemo", _wrap_xaccSplitGetMemo, METH_O, "xaccSplitGetMemo(Split const * split) -> char const *"},
	 { "xaccSplitSetAction", _wrap_xaccSplitSetAction, METH_VARARGS, "xaccSplitSetAction(Split * split, char const * action)"},
	 { "xaccSplitGetAction", _wrap_xaccSplitGetAction, METH_O, "xaccSplitGetAction(Split const * split) -> char const *"},
	 { "xaccSplitSetReconcile", _wrap_xaccSplitSetReconcile, METH_VARARGS, "xaccSplitSetReconcile(Split * split, char reconciled_flag)"},
	 { "xaccSplitGetReconcile", _wrap_xaccSplitGetReconcile, METH_O, "xaccSplitGetReconcile(Split const * split) -> char"},
	 { "xaccSplitSetDateReconciledSecs", _wrap_xaccSplitSetDateReconciledSecs, METH_VARARGS, "xaccSplitSetDateReconciledSecs(Split * split, time64 time)"},
	 { "xaccSplitGetDateReconciled", _wrap_xaccSplitGetDateReconciled, METH_O, "xaccSplitGetDateReconciled(Split const * split) -> time64"},
	 { "xaccSplitSetAmount", _wrap_xaccSplitSetAmount, METH_VARARGS, "xaccSplitSetAmount(Split * split, _gnc_numeric amount)"},
	 { "xaccSplitGetAmount", _wrap_xaccSplitGetAmount, METH_O, "xaccSplitGetAmount(Split const * split) -> _gnc_numeric"},
	 { "xaccSplitSetValue", _wrap_xaccSplitSetValue, METH_VARARGS, "xaccSplitSetValue(Split * split, _gnc_numeric value)"},
	 { "xaccSplitGetValue", _wrap_xaccSplitGetValue, METH_O, "xaccSplitGetValue(Split const * split) -> _gnc_numeric"},
	 { "xaccSplitSetSharePriceAndAmount", _wrap_xaccSplitSetSharePriceAndAmount, METH_VARARGS, "xaccSplitSetSharePriceAndAmount(Split * split, _gnc_numeric price, _gnc_numeric amount)"},
	 { "xaccSplitGetSharePrice", _wrap_xaccSplitGetSharePrice, METH_O, "xaccSplitGetSharePrice(Split const * split) -> _gnc_numeric"},
	 { "xaccSplitSetBaseValue", _wrap_xaccSplitSetBaseValue, METH_VARARGS, "xaccSplitSetBaseValue(Split * split, _gnc_numeric value, gnc_commodity const * base_currency)"},
	 { "xaccSplitGetBaseValue", _wrap_xaccSplitGetBaseValue, METH_VARARGS, "xaccSplitGetBaseValue(Split const * split, gnc_commodity const * base_currency) -> _gnc_numeric"},
	 { "xaccSplitGetBalance", _wrap_xaccSplitGetBalance, METH_O, "xaccSplitGetBalance(Split const * split) -> _gnc_numeric"},
	 { "xaccSplitGetNoclosingBalance", _wrap_xaccSplitGetNoclosingBalance, METH_O, "xaccSplitGetNoclosingBalance(Split const * split) -> _gnc_numeric"},
	 { "xaccSplitGetClearedBalance", _wrap_xaccSplitGetClearedBalance, METH_O, "xaccSplitGetClearedBalance(Split const * split) -> _gnc_numeric"},
	 { "xaccSplitGetReconciledBalance", _wrap_xaccSplitGetReconciledBalance, METH_O, "xaccSplitGetReconciledBalance(Split const * split) -> _gnc_numeric"},
	 { "xaccSplitEqual", _wrap_xaccSplitEqual, METH_VARARGS, "xaccSplitEqual(Split const * sa, Split const * sb, gboolean check_guids, gboolean check_balances, gboolean check_txn_splits) -> gboolean"},
	 { "xaccSplitLookup", _wrap_xaccSplitLookup, METH_VARARGS, "xaccSplitLookup(GncGUID guid, QofBook * book) -> Split *"},
	 { "xaccSplitListGetUniqueTransactions", _wrap_xaccSplitListGetUniqueTransactions, METH_O, "xaccSplitListGetUniqueTransactions(GList const * splits) -> GList *"},
	 { "xaccSplitAddPeerSplit", _wrap_xaccSplitAddPeerSplit, METH_VARARGS, "xaccSplitAddPeerSplit(Split * split, Split const * other_split, time64 const timestamp)"},
	 { "xaccSplitHasPeers", _wrap_xaccSplitHasPeers, METH_O, "xaccSplitHasPeers(Split const * split) -> gboolean"},
	 { "xaccSplitIsPeerSplit", _wrap_xaccSplitIsPeerSplit, METH_VARARGS, "xaccSplitIsPeerSplit(Split const * split, Split const * other_split) -> gboolean"},
	 { "xaccSplitRemovePeerSplit", _wrap_xaccSplitRemovePeerSplit, METH_VARARGS, "xaccSplitRemovePeerSplit(Split * split, Split const * other_split)"},
	 { "xaccSplitMergePeerSplits", _wrap_xaccSplitMergePeerSplits, METH_VARARGS, "xaccSplitMergePeerSplits(Split * split, Split const * other_split)"},
	 { "xaccSplitGetOtherSplit", _wrap_xaccSplitGetOtherSplit, METH_O, "xaccSplitGetOtherSplit(Split const * split) -> Split *"},
	 { "xaccSplitGetType", _wrap_xaccSplitGetType, METH_O, "xaccSplitGetType(Split const * s) -> char const *"},
	 { "xaccSplitMakeStockSplit", _wrap_xaccSplitMakeStockSplit, METH_O, "xaccSplitMakeStockSplit(Split * s)"},
	 { "xaccSplitOrder", _wrap_xaccSplitOrder, METH_VARARGS, "xaccSplitOrder(Split const * sa, Split const * sb) -> gint"},
	 { "xaccSplitOrderDateOnly", _wrap_xaccSplitOrderDateOnly, METH_VARARGS, "xaccSplitOrderDateOnly(Split const * sa, Split const * sb) -> gint"},
	 { "xaccSplitCompareAccountFullNames", _wrap_xaccSplitCompareAccountFullNames, METH_VARARGS, "xaccSplitCompareAccountFullNames(Split const * sa, Split const * sb) -> int"},
	 { "xaccSplitCompareAccountCodes", _wrap_xaccSplitCompareAccountCodes, METH_VARARGS, "xaccSplitCompareAccountCodes(Split const * sa, Split const * sb) -> int"},
	 { "xaccSplitCompareOtherAccountFullNames", _wrap_xaccSplitCompareOtherAccountFullNames, METH_VARARGS, "xaccSplitCompareOtherAccountFullNames(Split const * sa, Split const * sb) -> int"},
	 { "xaccSplitCompareOtherAccountCodes", _wrap_xaccSplitCompareOtherAccountCodes, METH_VARARGS, "xaccSplitCompareOtherAccountCodes(Split const * sa, Split const * sb) -> int"},
	 { "xaccSplitGetCorrAccountFullName", _wrap_xaccSplitGetCorrAccountFullName, METH_O, "xaccSplitGetCorrAccountFullName(Split const * sa) -> char *"},
	 { "xaccSplitGetCorrAccountName", _wrap_xaccSplitGetCorrAccountName, METH_O, "xaccSplitGetCorrAccountName(Split const * sa) -> char const *"},
	 { "xaccSplitGetCorrAccountCode", _wrap_xaccSplitGetCorrAccountCode, METH_O, "xaccSplitGetCorrAccountCode(Split const * sa) -> char const *"},
	 { "xaccSplitSetSharePrice", _wrap_xaccSplitSetSharePrice, METH_VARARGS, "xaccSplitSetSharePrice(Split * split, _gnc_numeric price)"},
	 { "xaccSplitVoidFormerAmount", _wrap_xaccSplitVoidFormerAmount, METH_O, "xaccSplitVoidFormerAmount(Split const * split) -> _gnc_numeric"},
	 { "xaccSplitVoidFormerValue", _wrap_xaccSplitVoidFormerValue, METH_O, "xaccSplitVoidFormerValue(Split const * split) -> _gnc_numeric"},
	 { "gnc_account_get_children", _wrap_gnc_account_get_children, METH_O, "gnc_account_get_children(Account const * account) -> AccountList *"},
	 { "gnc_account_get_children_sorted", _wrap_gnc_account_get_children_sorted, METH_O, "gnc_account_get_children_sorted(Account const * account) -> AccountList *"},
	 { "gnc_account_get_descendants", _wrap_gnc_account_get_descendants, METH_O, "gnc_account_get_descendants(Account const * account) -> AccountList *"},
	 { "gnc_account_get_descendants_sorted", _wrap_gnc_account_get_descendants_sorted, METH_O, "gnc_account_get_descendants_sorted(Account const * account) -> AccountList *"},
	 { "AccountClass_parent_class_set", _wrap_AccountClass_parent_class_set, METH_VARARGS, "AccountClass_parent_class_set(AccountClass self, QofInstanceClass parent_class)"},
	 { "AccountClass_parent_class_get", _wrap_AccountClass_parent_class_get, METH_O, "AccountClass_parent_class_get(AccountClass self) -> QofInstanceClass"},
	 { "new_AccountClass", _wrap_new_AccountClass, METH_NOARGS, "new_AccountClass() -> AccountClass"},
	 { "delete_AccountClass", _wrap_delete_AccountClass, METH_O, "delete_AccountClass(AccountClass self)"},
	 { "AccountClass_swigregister", AccountClass_swigregister, METH_O, NULL},
	 { "AccountClass_swiginit", AccountClass_swiginit, METH_VARARGS, NULL},
	 { "GncImportMatchMap_acc_set", _wrap_GncImportMatchMap_acc_set, METH_VARARGS, "GncImportMatchMap_acc_set(GncImportMatchMap self, Account * acc)"},
	 { "GncImportMatchMap_acc_get", _wrap_GncImportMatchMap_acc_get, METH_O, "GncImportMatchMap_acc_get(GncImportMatchMap self) -> Account *"},
	 { "GncImportMatchMap_book_set", _wrap_GncImportMatchMap_book_set, METH_VARARGS, "GncImportMatchMap_book_set(GncImportMatchMap self, QofBook * book)"},
	 { "GncImportMatchMap_book_get", _wrap_GncImportMatchMap_book_get, METH_O, "GncImportMatchMap_book_get(GncImportMatchMap self) -> QofBook *"},
	 { "new_GncImportMatchMap", _wrap_new_GncImportMatchMap, METH_NOARGS, "new_GncImportMatchMap() -> GncImportMatchMap"},
	 { "delete_GncImportMatchMap", _wrap_delete_GncImportMatchMap, METH_O, "delete_GncImportMatchMap(GncImportMatchMap self)"},
	 { "GncImportMatchMap_swigregister", GncImportMatchMap_swigregister, METH_O, NULL},
	 { "GncImportMatchMap_swiginit", GncImportMatchMap_swiginit, METH_VARARGS, NULL},
	 { "gnc_account_get_type", _wrap_gnc_account_get_type, METH_NOARGS, "gnc_account_get_type() -> GType"},
	 { "xaccMallocAccount", _wrap_xaccMallocAccount, METH_O, "xaccMallocAccount(QofBook * book) -> Account *"},
	 { "gnc_account_create_root", _wrap_gnc_account_create_root, METH_O, "gnc_account_create_root(QofBook * book) -> Account *"},
	 { "xaccCloneAccount", _wrap_xaccCloneAccount, METH_VARARGS, "xaccCloneAccount(Account const * source, QofBook * book) -> Account *"},
	 { "xaccAccountBeginEdit", _wrap_xaccAccountBeginEdit, METH_O, "xaccAccountBeginEdit(Account * account)"},
	 { "xaccAccountCommitEdit", _wrap_xaccAccountCommitEdit, METH_O, "xaccAccountCommitEdit(Account * account)"},
	 { "xaccAccountDestroy", _wrap_xaccAccountDestroy, METH_O, "xaccAccountDestroy(Account * account)"},
	 { "xaccAccountEqual", _wrap_xaccAccountEqual, METH_VARARGS, "xaccAccountEqual(Account const * a, Account const * b, gboolean check_guids) -> gboolean"},
	 { "xaccAccountOrder", _wrap_xaccAccountOrder, METH_VARARGS, "xaccAccountOrder(Account const * account_1, Account const * account_2) -> int"},
	 { "gnc_get_account_separator_string", _wrap_gnc_get_account_separator_string, METH_NOARGS, "gnc_get_account_separator_string() -> gchar const *"},
	 { "gnc_get_account_separator", _wrap_gnc_get_account_separator, METH_NOARGS, "gnc_get_account_separator() -> gunichar"},
	 { "gnc_set_account_separator", _wrap_gnc_set_account_separator, METH_O, "gnc_set_account_separator(gchar const * separator)"},
	 { "gnc_book_get_root_account", _wrap_gnc_book_get_root_account, METH_O, "gnc_book_get_root_account(QofBook * book) -> Account *"},
	 { "gnc_book_set_root_account", _wrap_gnc_book_set_root_account, METH_VARARGS, "gnc_book_set_root_account(QofBook * book, Account * root)"},
	 { "xaccAccountLookup", _wrap_xaccAccountLookup, METH_VARARGS, "xaccAccountLookup(GncGUID guid, QofBook * book) -> Account *"},
	 { "gnc_account_name_violations_errmsg", _wrap_gnc_account_name_violations_errmsg, METH_VARARGS, "gnc_account_name_violations_errmsg(gchar const * separator, GList * invalid_account_names) -> gchar *"},
	 { "gnc_account_list_name_violations", _wrap_gnc_account_list_name_violations, METH_VARARGS, "gnc_account_list_name_violations(QofBook * book, gchar const * separator) -> GList *"},
	 { "gnc_account_get_book", _wrap_gnc_account_get_book, METH_O, "gnc_account_get_book(Account const * account) -> QofBook *"},
	 { "xaccAccountSetType", _wrap_xaccAccountSetType, METH_VARARGS, "xaccAccountSetType(Account * account, GNCAccountType arg2)"},
	 { "xaccAccountSetName", _wrap_xaccAccountSetName, METH_VARARGS, "xaccAccountSetName(Account * account, char const * name)"},
	 { "xaccAccountSetCode", _wrap_xaccAccountSetCode, METH_VARARGS, "xaccAccountSetCode(Account * account, char const * code)"},
	 { "xaccAccountSetDescription", _wrap_xaccAccountSetDescription, METH_VARARGS, "xaccAccountSetDescription(Account * account, char const * desc)"},
	 { "xaccAccountSetColor", _wrap_xaccAccountSetColor, METH_VARARGS, "xaccAccountSetColor(Account * account, char const * color)"},
	 { "xaccAccountSetFilter", _wrap_xaccAccountSetFilter, METH_VARARGS, "xaccAccountSetFilter(Account * account, char const * filter)"},
	 { "xaccAccountSetSortOrder", _wrap_xaccAccountSetSortOrder, METH_VARARGS, "xaccAccountSetSortOrder(Account * account, char const * sortorder)"},
	 { "xaccAccountSetSortReversed", _wrap_xaccAccountSetSortReversed, METH_VARARGS, "xaccAccountSetSortReversed(Account * account, gboolean sortreversed)"},
	 { "xaccAccountSetNotes", _wrap_xaccAccountSetNotes, METH_VARARGS, "xaccAccountSetNotes(Account * account, char const * notes)"},
	 { "xaccAccountSetLastNum", _wrap_xaccAccountSetLastNum, METH_VARARGS, "xaccAccountSetLastNum(Account * account, char const * num)"},
	 { "gnc_account_set_policy", _wrap_gnc_account_set_policy, METH_VARARGS, "gnc_account_set_policy(Account * account, GNCPolicy * policy)"},
	 { "xaccAccountGetType", _wrap_xaccAccountGetType, METH_O, "xaccAccountGetType(Account const * account) -> GNCAccountType"},
	 { "xaccAccountIsPriced", _wrap_xaccAccountIsPriced, METH_O, "xaccAccountIsPriced(Account const * acc) -> gboolean"},
	 { "gnc_account_set_start_balance", _wrap_gnc_account_set_start_balance, METH_VARARGS, "gnc_account_set_start_balance(Account * acc, _gnc_numeric start_baln)"},
	 { "gnc_account_set_start_cleared_balance", _wrap_gnc_account_set_start_cleared_balance, METH_VARARGS, "gnc_account_set_start_cleared_balance(Account * acc, _gnc_numeric start_baln)"},
	 { "gnc_account_set_start_reconciled_balance", _wrap_gnc_account_set_start_reconciled_balance, METH_VARARGS, "gnc_account_set_start_reconciled_balance(Account * acc, _gnc_numeric start_baln)"},
	 { "gnc_account_set_balance_dirty", _wrap_gnc_account_set_balance_dirty, METH_O, "gnc_account_set_balance_dirty(Account * acc)"},
	 { "gnc_account_set_sort_dirty", _wrap_gnc_account_set_sort_dirty, METH_O, "gnc_account_set_sort_dirty(Account * acc)"},
	 { "gnc_account_insert_split", _wrap_gnc_account_insert_split, METH_VARARGS, "gnc_account_insert_split(Account * acc, Split * s) -> gboolean"},
	 { "gnc_account_remove_split", _wrap_gnc_account_remove_split, METH_VARARGS, "gnc_account_remove_split(Account * acc, Split * s) -> gboolean"},
	 { "xaccAccountGetName", _wrap_xaccAccountGetName, METH_O, "xaccAccountGetName(Account const * account) -> char const *"},
	 { "xaccAccountGetCode", _wrap_xaccAccountGetCode, METH_O, "xaccAccountGetCode(Account const * account) -> char const *"},
	 { "xaccAccountGetDescription", _wrap_xaccAccountGetDescription, METH_O, "xaccAccountGetDescription(Account const * account) -> char const *"},
	 { "xaccAccountGetColor", _wrap_xaccAccountGetColor, METH_O, "xaccAccountGetColor(Account const * account) -> char const *"},
	 { "xaccAccountGetFilter", _wrap_xaccAccountGetFilter, METH_O, "xaccAccountGetFilter(Account const * account) -> char const *"},
	 { "xaccAccountGetSortOrder", _wrap_xaccAccountGetSortOrder, METH_O, "xaccAccountGetSortOrder(Account const * account) -> char const *"},
	 { "xaccAccountGetSortReversed", _wrap_xaccAccountGetSortReversed, METH_O, "xaccAccountGetSortReversed(Account const * account) -> gboolean"},
	 { "xaccAccountGetNotes", _wrap_xaccAccountGetNotes, METH_O, "xaccAccountGetNotes(Account const * account) -> char const *"},
	 { "xaccAccountGetLastNum", _wrap_xaccAccountGetLastNum, METH_O, "xaccAccountGetLastNum(Account const * account) -> char const *"},
	 { "gnc_account_get_policy", _wrap_gnc_account_get_policy, METH_O, "gnc_account_get_policy(Account * account) -> GNCPolicy *"},
	 { "xaccAccountRecomputeBalance", _wrap_xaccAccountRecomputeBalance, METH_O, "xaccAccountRecomputeBalance(Account * arg1)"},
	 { "xaccAccountSortSplits", _wrap_xaccAccountSortSplits, METH_VARARGS, "xaccAccountSortSplits(Account * acc, gboolean force)"},
	 { "gnc_account_get_full_name", _wrap_gnc_account_get_full_name, METH_O, "gnc_account_get_full_name(Account const * account) -> gchar *"},
	 { "xaccAccountGainsAccount", _wrap_xaccAccountGainsAccount, METH_VARARGS, "xaccAccountGainsAccount(Account * acc, gnc_commodity * curr) -> Account *"},
	 { "dxaccAccountSetPriceSrc", _wrap_dxaccAccountSetPriceSrc, METH_VARARGS, "dxaccAccountSetPriceSrc(Account * account, char const * src)"},
	 { "dxaccAccountGetPriceSrc", _wrap_dxaccAccountGetPriceSrc, METH_O, "dxaccAccountGetPriceSrc(Account const * account) -> char const *"},
	 { "xaccAccountGetAutoInterestXfer", _wrap_xaccAccountGetAutoInterestXfer, METH_VARARGS, "xaccAccountGetAutoInterestXfer(Account const * account, gboolean default_value) -> gboolean"},
	 { "xaccAccountSetAutoInterestXfer", _wrap_xaccAccountSetAutoInterestXfer, METH_VARARGS, "xaccAccountSetAutoInterestXfer(Account * account, gboolean value)"},
	 { "xaccAccountSetCommodity", _wrap_xaccAccountSetCommodity, METH_VARARGS, "xaccAccountSetCommodity(Account * account, gnc_commodity * comm)"},
	 { "xaccAccountGetCommodity", _wrap_xaccAccountGetCommodity, METH_O, "xaccAccountGetCommodity(Account const * account) -> gnc_commodity *"},
	 { "gnc_account_get_currency_or_parent", _wrap_gnc_account_get_currency_or_parent, METH_O, "gnc_account_get_currency_or_parent(Account const * account) -> gnc_commodity *"},
	 { "xaccAccountGetCommoditySCU", _wrap_xaccAccountGetCommoditySCU, METH_O, "xaccAccountGetCommoditySCU(Account const * account) -> int"},
	 { "xaccAccountGetCommoditySCUi", _wrap_xaccAccountGetCommoditySCUi, METH_O, "xaccAccountGetCommoditySCUi(Account const * account) -> int"},
	 { "xaccAccountSetCommoditySCU", _wrap_xaccAccountSetCommoditySCU, METH_VARARGS, "xaccAccountSetCommoditySCU(Account * account, int frac)"},
	 { "xaccAccountSetNonStdSCU", _wrap_xaccAccountSetNonStdSCU, METH_VARARGS, "xaccAccountSetNonStdSCU(Account * account, gboolean flag)"},
	 { "xaccAccountGetNonStdSCU", _wrap_xaccAccountGetNonStdSCU, METH_O, "xaccAccountGetNonStdSCU(Account const * account) -> gboolean"},
	 { "xaccAccountGetBalance", _wrap_xaccAccountGetBalance, METH_O, "xaccAccountGetBalance(Account const * account) -> _gnc_numeric"},
	 { "xaccAccountGetClearedBalance", _wrap_xaccAccountGetClearedBalance, METH_O, "xaccAccountGetClearedBalance(Account const * account) -> _gnc_numeric"},
	 { "xaccAccountGetReconciledBalance", _wrap_xaccAccountGetReconciledBalance, METH_O, "xaccAccountGetReconciledBalance(Account const * account) -> _gnc_numeric"},
	 { "xaccAccountGetPresentBalance", _wrap_xaccAccountGetPresentBalance, METH_O, "xaccAccountGetPresentBalance(Account const * account) -> _gnc_numeric"},
	 { "xaccAccountGetProjectedMinimumBalance", _wrap_xaccAccountGetProjectedMinimumBalance, METH_O, "xaccAccountGetProjectedMinimumBalance(Account const * account) -> _gnc_numeric"},
	 { "xaccAccountGetBalanceAsOfDate", _wrap_xaccAccountGetBalanceAsOfDate, METH_VARARGS, "xaccAccountGetBalanceAsOfDate(Account * account, time64 date) -> _gnc_numeric"},
	 { "xaccAccountGetReconciledBalanceAsOfDate", _wrap_xaccAccountGetReconciledBalanceAsOfDate, METH_VARARGS, "xaccAccountGetReconciledBalanceAsOfDate(Account * account, time64 date) -> _gnc_numeric"},
	 { "xaccAccountConvertBalanceToCurrency", _wrap_xaccAccountConvertBalanceToCurrency, METH_VARARGS, "xaccAccountConvertBalanceToCurrency(Account const * account, _gnc_numeric balance, gnc_commodity const * balance_currency, gnc_commodity const * new_currency) -> _gnc_numeric"},
	 { "xaccAccountConvertBalanceToCurrencyAsOfDate", _wrap_xaccAccountConvertBalanceToCurrencyAsOfDate, METH_VARARGS, "xaccAccountConvertBalanceToCurrencyAsOfDate(Account const * account, _gnc_numeric balance, gnc_commodity * balance_currency, gnc_commodity * new_currency, time64 date) -> _gnc_numeric"},
	 { "xaccAccountGetBalanceInCurrency", _wrap_xaccAccountGetBalanceInCurrency, METH_VARARGS, "xaccAccountGetBalanceInCurrency(Account const * account, gnc_commodity const * report_commodity, gboolean include_children) -> _gnc_numeric"},
	 { "xaccAccountGetClearedBalanceInCurrency", _wrap_xaccAccountGetClearedBalanceInCurrency, METH_VARARGS, "xaccAccountGetClearedBalanceInCurrency(Account const * account, gnc_commodity const * report_commodity, gboolean include_children) -> _gnc_numeric"},
	 { "xaccAccountGetReconciledBalanceInCurrency", _wrap_xaccAccountGetReconciledBalanceInCurrency, METH_VARARGS, "xaccAccountGetReconciledBalanceInCurrency(Account const * account, gnc_commodity const * report_commodity, gboolean include_children) -> _gnc_numeric"},
	 { "xaccAccountGetPresentBalanceInCurrency", _wrap_xaccAccountGetPresentBalanceInCurrency, METH_VARARGS, "xaccAccountGetPresentBalanceInCurrency(Account const * account, gnc_commodity const * report_commodity, gboolean include_children) -> _gnc_numeric"},
	 { "xaccAccountGetProjectedMinimumBalanceInCurrency", _wrap_xaccAccountGetProjectedMinimumBalanceInCurrency, METH_VARARGS, "xaccAccountGetProjectedMinimumBalanceInCurrency(Account const * account, gnc_commodity const * report_commodity, gboolean include_children) -> _gnc_numeric"},
	 { "xaccAccountGetNoclosingBalanceAsOfDateInCurrency", _wrap_xaccAccountGetNoclosingBalanceAsOfDateInCurrency, METH_VARARGS, "xaccAccountGetNoclosingBalanceAsOfDateInCurrency(Account * acc, time64 date, gnc_commodity * report_commodity, gboolean include_children) -> _gnc_numeric"},
	 { "xaccAccountGetBalanceAsOfDateInCurrency", _wrap_xaccAccountGetBalanceAsOfDateInCurrency, METH_VARARGS, "xaccAccountGetBalanceAsOfDateInCurrency(Account * account, time64 date, gnc_commodity * report_commodity, gboolean include_children) -> _gnc_numeric"},
	 { "xaccAccountGetNoclosingBalanceChangeForPeriod", _wrap_xaccAccountGetNoclosingBalanceChangeForPeriod, METH_VARARGS, "xaccAccountGetNoclosingBalanceChangeForPeriod(Account * acc, time64 date1, time64 date2, gboolean recurse) -> _gnc_numeric"},
	 { "xaccAccountGetBalanceChangeForPeriod", _wrap_xaccAccountGetBalanceChangeForPeriod, METH_VARARGS, "xaccAccountGetBalanceChangeForPeriod(Account * acc, time64 date1, time64 date2, gboolean recurse) -> _gnc_numeric"},
	 { "gnc_account_append_child", _wrap_gnc_account_append_child, METH_VARARGS, "gnc_account_append_child(Account * new_parent, Account * child)"},
	 { "gnc_account_remove_child", _wrap_gnc_account_remove_child, METH_VARARGS, "gnc_account_remove_child(Account * parent, Account * child)"},
	 { "gnc_account_get_parent", _wrap_gnc_account_get_parent, METH_O, "gnc_account_get_parent(Account const * account) -> Account *"},
	 { "gnc_account_get_root", _wrap_gnc_account_get_root, METH_O, "gnc_account_get_root(Account * account) -> Account *"},
	 { "gnc_account_is_root", _wrap_gnc_account_is_root, METH_O, "gnc_account_is_root(Account const * account) -> gboolean"},
	 { "gnc_account_n_children", _wrap_gnc_account_n_children, METH_O, "gnc_account_n_children(Account const * account) -> gint"},
	 { "gnc_account_child_index", _wrap_gnc_account_child_index, METH_VARARGS, "gnc_account_child_index(Account const * parent, Account const * child) -> gint"},
	 { "gnc_account_nth_child", _wrap_gnc_account_nth_child, METH_VARARGS, "gnc_account_nth_child(Account const * parent, gint num) -> Account *"},
	 { "gnc_account_n_descendants", _wrap_gnc_account_n_descendants, METH_O, "gnc_account_n_descendants(Account const * account) -> gint"},
	 { "gnc_account_get_current_depth", _wrap_gnc_account_get_current_depth, METH_O, "gnc_account_get_current_depth(Account const * account) -> gint"},
	 { "gnc_account_get_tree_depth", _wrap_gnc_account_get_tree_depth, METH_O, "gnc_account_get_tree_depth(Account const * account) -> gint"},
	 { "gnc_account_foreach_child", _wrap_gnc_account_foreach_child, METH_VARARGS, "gnc_account_foreach_child(Account const * account, AccountCb func, gpointer user_data)"},
	 { "gnc_account_foreach_descendant", _wrap_gnc_account_foreach_descendant, METH_VARARGS, "gnc_account_foreach_descendant(Account const * account, AccountCb func, gpointer user_data)"},
	 { "gnc_account_foreach_descendant_until", _wrap_gnc_account_foreach_descendant_until, METH_VARARGS, "gnc_account_foreach_descendant_until(Account const * account, AccountCb2 func, gpointer user_data) -> gpointer"},
	 { "gnc_account_join_children", _wrap_gnc_account_join_children, METH_VARARGS, "gnc_account_join_children(Account * to_parent, Account * from_parent)"},
	 { "gnc_account_merge_children", _wrap_gnc_account_merge_children, METH_O, "gnc_account_merge_children(Account * parent)"},
	 { "xaccAccountSetReconcileChildrenStatus", _wrap_xaccAccountSetReconcileChildrenStatus, METH_VARARGS, "xaccAccountSetReconcileChildrenStatus(Account * account, gboolean status)"},
	 { "xaccAccountGetReconcileChildrenStatus", _wrap_xaccAccountGetReconcileChildrenStatus, METH_O, "xaccAccountGetReconcileChildrenStatus(Account const * account) -> gboolean"},
	 { "xaccAccountHasAncestor", _wrap_xaccAccountHasAncestor, METH_VARARGS, "xaccAccountHasAncestor(Account const * acc, Account const * ancestor) -> gboolean"},
	 { "gnc_account_lookup_by_name", _wrap_gnc_account_lookup_by_name, METH_VARARGS, "gnc_account_lookup_by_name(Account const * parent, char const * name) -> Account *"},
	 { "gnc_account_lookup_by_full_name", _wrap_gnc_account_lookup_by_full_name, METH_VARARGS, "gnc_account_lookup_by_full_name(Account const * any_account, gchar const * name) -> Account *"},
	 { "gnc_account_lookup_by_code", _wrap_gnc_account_lookup_by_code, METH_VARARGS, "gnc_account_lookup_by_code(Account const * parent, char const * code) -> Account *"},
	 { "xaccAccountTypeEnumAsString", _wrap_xaccAccountTypeEnumAsString, METH_O, "xaccAccountTypeEnumAsString(GNCAccountType type) -> char const *"},
	 { "xaccAccountStringToType", _wrap_xaccAccountStringToType, METH_VARARGS, "xaccAccountStringToType(char const * str, GNCAccountType * type) -> gboolean"},
	 { "xaccAccountStringToEnum", _wrap_xaccAccountStringToEnum, METH_O, "xaccAccountStringToEnum(char const * str) -> GNCAccountType"},
	 { "xaccAccountGetTypeStr", _wrap_xaccAccountGetTypeStr, METH_O, "xaccAccountGetTypeStr(GNCAccountType type) -> char const *"},
	 { "xaccAccountTypesCompatibleWith", _wrap_xaccAccountTypesCompatibleWith, METH_O, "xaccAccountTypesCompatibleWith(GNCAccountType type) -> guint32"},
	 { "xaccParentAccountTypesCompatibleWith", _wrap_xaccParentAccountTypesCompatibleWith, METH_O, "xaccParentAccountTypesCompatibleWith(GNCAccountType type) -> guint32"},
	 { "xaccAccountTypesCompatible", _wrap_xaccAccountTypesCompatible, METH_VARARGS, "xaccAccountTypesCompatible(GNCAccountType parent_type, GNCAccountType child_type) -> gboolean"},
	 { "xaccAccountTypesValid", _wrap_xaccAccountTypesValid, METH_NOARGS, "xaccAccountTypesValid() -> guint32"},
	 { "xaccAccountIsAssetLiabType", _wrap_xaccAccountIsAssetLiabType, METH_O, "xaccAccountIsAssetLiabType(GNCAccountType t) -> gboolean"},
	 { "xaccAccountIsAPARType", _wrap_xaccAccountIsAPARType, METH_O, "xaccAccountIsAPARType(GNCAccountType t) -> gboolean"},
	 { "xaccAccountIsEquityType", _wrap_xaccAccountIsEquityType, METH_O, "xaccAccountIsEquityType(GNCAccountType t) -> gboolean"},
	 { "xaccAccountGetSplitList", _wrap_xaccAccountGetSplitList, METH_O, "xaccAccountGetSplitList(Account const * account) -> SplitList *"},
	 { "xaccAccountCountSplits", _wrap_xaccAccountCountSplits, METH_VARARGS, "xaccAccountCountSplits(Account const * acc, gboolean include_children) -> gint64"},
	 { "xaccAccountMoveAllSplits", _wrap_xaccAccountMoveAllSplits, METH_VARARGS, "xaccAccountMoveAllSplits(Account * accfrom, Account * accto)"},
	 { "xaccAccountForEachTransaction", _wrap_xaccAccountForEachTransaction, METH_VARARGS, "xaccAccountForEachTransaction(Account const * account, TransactionCallback proc, void * data) -> gint"},
	 { "xaccAccountFindTransByDesc", _wrap_xaccAccountFindTransByDesc, METH_VARARGS, "xaccAccountFindTransByDesc(Account const * account, char const * description) -> Transaction *"},
	 { "xaccAccountFindSplitByDesc", _wrap_xaccAccountFindSplitByDesc, METH_VARARGS, "xaccAccountFindSplitByDesc(Account const * account, char const * description) -> Split *"},
	 { "xaccAccountInsertLot", _wrap_xaccAccountInsertLot, METH_VARARGS, "xaccAccountInsertLot(Account * arg1, GNCLot * arg2)"},
	 { "xaccAccountRemoveLot", _wrap_xaccAccountRemoveLot, METH_VARARGS, "xaccAccountRemoveLot(Account * arg1, GNCLot * arg2)"},
	 { "xaccAccountGetLotList", _wrap_xaccAccountGetLotList, METH_O, "xaccAccountGetLotList(Account const * account) -> LotList *"},
	 { "xaccAccountForEachLot", _wrap_xaccAccountForEachLot, METH_VARARGS, "xaccAccountForEachLot(Account const * acc, gpointer (*)(GNCLot *,gpointer) proc, gpointer user_data) -> gpointer"},
	 { "xaccAccountFindOpenLots", _wrap_xaccAccountFindOpenLots, METH_VARARGS, "xaccAccountFindOpenLots(Account const * acc, gboolean (*)(GNCLot *,gpointer) match_func, gpointer user_data, GCompareFunc sort_func) -> LotList *"},
	 { "xaccAccountGetReconcileLastDate", _wrap_xaccAccountGetReconcileLastDate, METH_O, "xaccAccountGetReconcileLastDate(Account const * account) -> gboolean"},
	 { "xaccAccountSetReconcileLastDate", _wrap_xaccAccountSetReconcileLastDate, METH_VARARGS, "xaccAccountSetReconcileLastDate(Account * account, time64 last_date)"},
	 { "xaccAccountGetReconcileLastInterval", _wrap_xaccAccountGetReconcileLastInterval, METH_VARARGS, "xaccAccountGetReconcileLastInterval(Account const * account, int * months, int * days) -> gboolean"},
	 { "xaccAccountSetReconcileLastInterval", _wrap_xaccAccountSetReconcileLastInterval, METH_VARARGS, "xaccAccountSetReconcileLastInterval(Account * account, int months, int days)"},
	 { "xaccAccountGetReconcilePostponeDate", _wrap_xaccAccountGetReconcilePostponeDate, METH_O, "xaccAccountGetReconcilePostponeDate(Account const * account) -> gboolean"},
	 { "xaccAccountSetReconcilePostponeDate", _wrap_xaccAccountSetReconcilePostponeDate, METH_VARARGS, "xaccAccountSetReconcilePostponeDate(Account * account, time64 postpone_date)"},
	 { "xaccAccountGetReconcilePostponeBalance", _wrap_xaccAccountGetReconcilePostponeBalance, METH_VARARGS, "xaccAccountGetReconcilePostponeBalance(Account const * account, _gnc_numeric balance) -> gboolean"},
	 { "xaccAccountSetReconcilePostponeBalance", _wrap_xaccAccountSetReconcilePostponeBalance, METH_VARARGS, "xaccAccountSetReconcilePostponeBalance(Account * account, _gnc_numeric balance)"},
	 { "xaccAccountClearReconcilePostpone", _wrap_xaccAccountClearReconcilePostpone, METH_O, "xaccAccountClearReconcilePostpone(Account * account)"},
	 { "xaccAccountGetPlaceholder", _wrap_xaccAccountGetPlaceholder, METH_O, "xaccAccountGetPlaceholder(Account const * account) -> gboolean"},
	 { "xaccAccountSetPlaceholder", _wrap_xaccAccountSetPlaceholder, METH_VARARGS, "xaccAccountSetPlaceholder(Account * account, gboolean val)"},
	 { "xaccAccountGetDescendantPlaceholder", _wrap_xaccAccountGetDescendantPlaceholder, METH_O, "xaccAccountGetDescendantPlaceholder(Account const * account) -> GNCPlaceholderType"},
	 { "xaccAccountGetHidden", _wrap_xaccAccountGetHidden, METH_O, "xaccAccountGetHidden(Account const * acc) -> gboolean"},
	 { "xaccAccountSetHidden", _wrap_xaccAccountSetHidden, METH_VARARGS, "xaccAccountSetHidden(Account * acc, gboolean val)"},
	 { "xaccAccountIsHidden", _wrap_xaccAccountIsHidden, METH_O, "xaccAccountIsHidden(Account const * acc) -> gboolean"},
	 { "xaccAccountGetTaxRelated", _wrap_xaccAccountGetTaxRelated, METH_O, "xaccAccountGetTaxRelated(Account const * account) -> gboolean"},
	 { "xaccAccountSetTaxRelated", _wrap_xaccAccountSetTaxRelated, METH_VARARGS, "xaccAccountSetTaxRelated(Account * account, gboolean tax_related)"},
	 { "xaccAccountGetTaxUSCode", _wrap_xaccAccountGetTaxUSCode, METH_O, "xaccAccountGetTaxUSCode(Account const * account) -> char const *"},
	 { "xaccAccountSetTaxUSCode", _wrap_xaccAccountSetTaxUSCode, METH_VARARGS, "xaccAccountSetTaxUSCode(Account * account, char const * code)"},
	 { "xaccAccountGetTaxUSPayerNameSource", _wrap_xaccAccountGetTaxUSPayerNameSource, METH_O, "xaccAccountGetTaxUSPayerNameSource(Account const * account) -> char const *"},
	 { "xaccAccountSetTaxUSPayerNameSource", _wrap_xaccAccountSetTaxUSPayerNameSource, METH_VARARGS, "xaccAccountSetTaxUSPayerNameSource(Account * account, char const * source)"},
	 { "xaccAccountGetTaxUSCopyNumber", _wrap_xaccAccountGetTaxUSCopyNumber, METH_O, "xaccAccountGetTaxUSCopyNumber(Account const * account) -> gint64"},
	 { "xaccAccountSetTaxUSCopyNumber", _wrap_xaccAccountSetTaxUSCopyNumber, METH_VARARGS, "xaccAccountSetTaxUSCopyNumber(Account * account, gint64 copy_number)"},
	 { "xaccAccountSetMark", _wrap_xaccAccountSetMark, METH_VARARGS, "xaccAccountSetMark(Account * account, short mark)"},
	 { "xaccClearMark", _wrap_xaccClearMark, METH_VARARGS, "xaccClearMark(Account * account, short val)"},
	 { "xaccClearMarkDown", _wrap_xaccClearMarkDown, METH_VARARGS, "xaccClearMarkDown(Account * account, short val)"},
	 { "gnc_account_tree_begin_staged_transaction_traversals", _wrap_gnc_account_tree_begin_staged_transaction_traversals, METH_O, "gnc_account_tree_begin_staged_transaction_traversals(Account * acc)"},
	 { "xaccSplitsBeginStagedTransactionTraversals", _wrap_xaccSplitsBeginStagedTransactionTraversals, METH_O, "xaccSplitsBeginStagedTransactionTraversals(SplitList * splits)"},
	 { "xaccAccountBeginStagedTransactionTraversals", _wrap_xaccAccountBeginStagedTransactionTraversals, METH_O, "xaccAccountBeginStagedTransactionTraversals(Account const * account)"},
	 { "xaccTransactionTraverse", _wrap_xaccTransactionTraverse, METH_VARARGS, "xaccTransactionTraverse(Transaction * trans, int stage) -> gboolean"},
	 { "xaccAccountStagedTransactionTraversal", _wrap_xaccAccountStagedTransactionTraversal, METH_VARARGS, "xaccAccountStagedTransactionTraversal(Account const * a, unsigned int stage, TransactionCallback thunk, void * data) -> int"},
	 { "gnc_account_tree_staged_transaction_traversal", _wrap_gnc_account_tree_staged_transaction_traversal, METH_VARARGS, "gnc_account_tree_staged_transaction_traversal(Account const * account, unsigned int stage, TransactionCallback thunk, void * data) -> int"},
	 { "xaccAccountTreeForEachTransaction", _wrap_xaccAccountTreeForEachTransaction, METH_VARARGS, "xaccAccountTreeForEachTransaction(Account * acc, TransactionCallback proc, void * data) -> int"},
	 { "gnc_account_imap_create_imap", _wrap_gnc_account_imap_create_imap, METH_O, "gnc_account_imap_create_imap(Account * acc) -> GncImportMatchMap"},
	 { "gnc_account_imap_find_account", _wrap_gnc_account_imap_find_account, METH_VARARGS, "gnc_account_imap_find_account(GncImportMatchMap imap, char const * category, char const * key) -> Account *"},
	 { "gnc_account_imap_add_account", _wrap_gnc_account_imap_add_account, METH_VARARGS, "gnc_account_imap_add_account(GncImportMatchMap imap, char const * category, char const * key, Account * acc)"},
	 { "gnc_account_imap_delete_account", _wrap_gnc_account_imap_delete_account, METH_VARARGS, "gnc_account_imap_delete_account(GncImportMatchMap imap, char const * category, char const * key)"},
	 { "gnc_account_imap_find_account_bayes", _wrap_gnc_account_imap_find_account_bayes, METH_VARARGS, "gnc_account_imap_find_account_bayes(GncImportMatchMap imap, GList * tokens) -> Account *"},
	 { "gnc_account_imap_add_account_bayes", _wrap_gnc_account_imap_add_account_bayes, METH_VARARGS, "gnc_account_imap_add_account_bayes(GncImportMatchMap imap, GList * tokens, Account * acc)"},
	 { "GncImapInfo_source_account_set", _wrap_GncImapInfo_source_account_set, METH_VARARGS, "GncImapInfo_source_account_set(GncImapInfo self, Account * source_account)"},
	 { "GncImapInfo_source_account_get", _wrap_GncImapInfo_source_account_get, METH_O, "GncImapInfo_source_account_get(GncImapInfo self) -> Account *"},
	 { "GncImapInfo_map_account_set", _wrap_GncImapInfo_map_account_set, METH_VARARGS, "GncImapInfo_map_account_set(GncImapInfo self, Account * map_account)"},
	 { "GncImapInfo_map_account_get", _wrap_GncImapInfo_map_account_get, METH_O, "GncImapInfo_map_account_get(GncImapInfo self) -> Account *"},
	 { "GncImapInfo_list_set", _wrap_GncImapInfo_list_set, METH_VARARGS, "GncImapInfo_list_set(GncImapInfo self, GList * list)"},
	 { "GncImapInfo_list_get", _wrap_GncImapInfo_list_get, METH_O, "GncImapInfo_list_get(GncImapInfo self) -> GList *"},
	 { "GncImapInfo_head_set", _wrap_GncImapInfo_head_set, METH_VARARGS, "GncImapInfo_head_set(GncImapInfo self, char * head)"},
	 { "GncImapInfo_head_get", _wrap_GncImapInfo_head_get, METH_O, "GncImapInfo_head_get(GncImapInfo self) -> char *"},
	 { "GncImapInfo_category_set", _wrap_GncImapInfo_category_set, METH_VARARGS, "GncImapInfo_category_set(GncImapInfo self, char * category)"},
	 { "GncImapInfo_category_get", _wrap_GncImapInfo_category_get, METH_O, "GncImapInfo_category_get(GncImapInfo self) -> char *"},
	 { "GncImapInfo_match_string_set", _wrap_GncImapInfo_match_string_set, METH_VARARGS, "GncImapInfo_match_string_set(GncImapInfo self, char * match_string)"},
	 { "GncImapInfo_match_string_get", _wrap_GncImapInfo_match_string_get, METH_O, "GncImapInfo_match_string_get(GncImapInfo self) -> char *"},
	 { "GncImapInfo_count_set", _wrap_GncImapInfo_count_set, METH_VARARGS, "GncImapInfo_count_set(GncImapInfo self, char * count)"},
	 { "GncImapInfo_count_get", _wrap_GncImapInfo_count_get, METH_O, "GncImapInfo_count_get(GncImapInfo self) -> char *"},
	 { "new_GncImapInfo", _wrap_new_GncImapInfo, METH_NOARGS, "new_GncImapInfo() -> GncImapInfo"},
	 { "delete_GncImapInfo", _wrap_delete_GncImapInfo, METH_O, "delete_GncImapInfo(GncImapInfo self)"},
	 { "GncImapInfo_swigregister", GncImapInfo_swigregister, METH_O, NULL},
	 { "GncImapInfo_swiginit", GncImapInfo_swiginit, METH_VARARGS, NULL},
	 { "gnc_account_imap_get_info_bayes", _wrap_gnc_account_imap_get_info_bayes, METH_O, "gnc_account_imap_get_info_bayes(Account * acc) -> GList *"},
	 { "gnc_account_imap_get_info", _wrap_gnc_account_imap_get_info, METH_VARARGS, "gnc_account_imap_get_info(Account * acc, char const * category) -> GList *"},
	 { "gnc_account_get_map_entry", _wrap_gnc_account_get_map_entry, METH_VARARGS, "gnc_account_get_map_entry(Account * acc, char const * full_category) -> gchar *"},
	 { "gnc_account_delete_map_entry", _wrap_gnc_account_delete_map_entry, METH_VARARGS, "gnc_account_delete_map_entry(Account * acc, char * head, char * category, char * match_string, gboolean empty)"},
	 { "gnc_account_delete_all_bayes_maps", _wrap_gnc_account_delete_all_bayes_maps, METH_O, "gnc_account_delete_all_bayes_maps(Account * acc)"},
	 { "DxaccAccountSetCurrency", _wrap_DxaccAccountSetCurrency, METH_VARARGS, "DxaccAccountSetCurrency(Account * account, gnc_commodity * currency)"},
	 { "DxaccAccountGetCurrency", _wrap_DxaccAccountGetCurrency, METH_O, "DxaccAccountGetCurrency(Account const * account) -> gnc_commodity *"},
	 { "dxaccAccountSetQuoteTZ", _wrap_dxaccAccountSetQuoteTZ, METH_VARARGS, "dxaccAccountSetQuoteTZ(Account * account, char const * tz)"},
	 { "dxaccAccountGetQuoteTZ", _wrap_dxaccAccountGetQuoteTZ, METH_O, "dxaccAccountGetQuoteTZ(Account const * account) -> char const *"},
	 { "gnc_transaction_get_type", _wrap_gnc_transaction_get_type, METH_NOARGS, "gnc_transaction_get_type() -> GType"},
	 { "xaccMallocTransaction", _wrap_xaccMallocTransaction, METH_O, "xaccMallocTransaction(QofBook * book) -> Transaction *"},
	 { "xaccTransDestroy", _wrap_xaccTransDestroy, METH_O, "xaccTransDestroy(Transaction * trans)"},
	 { "xaccTransClone", _wrap_xaccTransClone, METH_O, "xaccTransClone(Transaction const * t) -> Transaction *"},
	 { "xaccTransCloneNoKvp", _wrap_xaccTransCloneNoKvp, METH_O, "xaccTransCloneNoKvp(Transaction const * t) -> Transaction *"},
	 { "xaccTransEqual", _wrap_xaccTransEqual, METH_VARARGS, "xaccTransEqual(Transaction const * ta, Transaction const * tb, gboolean check_guids, gboolean check_splits, gboolean check_balances, gboolean assume_ordered) -> gboolean"},
	 { "xaccTransBeginEdit", _wrap_xaccTransBeginEdit, METH_O, "xaccTransBeginEdit(Transaction * trans)"},
	 { "xaccTransCommitEdit", _wrap_xaccTransCommitEdit, METH_O, "xaccTransCommitEdit(Transaction * trans)"},
	 { "xaccTransRollbackEdit", _wrap_xaccTransRollbackEdit, METH_O, "xaccTransRollbackEdit(Transaction * trans)"},
	 { "xaccTransIsOpen", _wrap_xaccTransIsOpen, METH_O, "xaccTransIsOpen(Transaction const * trans) -> gboolean"},
	 { "xaccTransLookup", _wrap_xaccTransLookup, METH_VARARGS, "xaccTransLookup(GncGUID guid, QofBook * book) -> Transaction *"},
	 { "xaccTransCopyToClipBoard", _wrap_xaccTransCopyToClipBoard, METH_O, "xaccTransCopyToClipBoard(Transaction const * from_trans) -> Transaction *"},
	 { "xaccTransCopyOnto", _wrap_xaccTransCopyOnto, METH_VARARGS, "xaccTransCopyOnto(Transaction const * from_trans, Transaction * to_trans)"},
	 { "xaccTransCopyFromClipBoard", _wrap_xaccTransCopyFromClipBoard, METH_VARARGS, "xaccTransCopyFromClipBoard(Transaction const * from_trans, Transaction * to_trans, Account const * from_acc, Account * to_acc, gboolean no_date)"},
	 { "xaccTransFindSplitByAccount", _wrap_xaccTransFindSplitByAccount, METH_VARARGS, "xaccTransFindSplitByAccount(Transaction const * trans, Account const * acc) -> Split *"},
	 { "xaccTransScrubGains", _wrap_xaccTransScrubGains, METH_VARARGS, "xaccTransScrubGains(Transaction * trans, Account * gain_acc)"},
	 { "gnc_book_count_transactions", _wrap_gnc_book_count_transactions, METH_O, "gnc_book_count_transactions(QofBook * book) -> guint"},
	 { "xaccTransUseTradingAccounts", _wrap_xaccTransUseTradingAccounts, METH_O, "xaccTransUseTradingAccounts(Transaction const * trans) -> gboolean"},
	 { "xaccTransSortSplits", _wrap_xaccTransSortSplits, METH_O, "xaccTransSortSplits(Transaction * trans)"},
	 { "xaccTransSetTxnType", _wrap_xaccTransSetTxnType, METH_VARARGS, "xaccTransSetTxnType(Transaction * trans, char type)"},
	 { "xaccTransGetTxnType", _wrap_xaccTransGetTxnType, METH_O, "xaccTransGetTxnType(Transaction const * trans) -> char"},
	 { "xaccTransSetNum", _wrap_xaccTransSetNum, METH_VARARGS, "xaccTransSetNum(Transaction * trans, char const * num)"},
	 { "xaccTransSetDescription", _wrap_xaccTransSetDescription, METH_VARARGS, "xaccTransSetDescription(Transaction * trans, char const * desc)"},
	 { "xaccTransSetAssociation", _wrap_xaccTransSetAssociation, METH_VARARGS, "xaccTransSetAssociation(Transaction * trans, char const * assoc)"},
	 { "xaccTransSetNotes", _wrap_xaccTransSetNotes, METH_VARARGS, "xaccTransSetNotes(Transaction * trans, char const * notes)"},
	 { "xaccTransGetNum", _wrap_xaccTransGetNum, METH_O, "xaccTransGetNum(Transaction const * trans) -> char const *"},
	 { "xaccTransGetDescription", _wrap_xaccTransGetDescription, METH_O, "xaccTransGetDescription(Transaction const * trans) -> char const *"},
	 { "xaccTransGetAssociation", _wrap_xaccTransGetAssociation, METH_O, "xaccTransGetAssociation(Transaction const * trans) -> char const *"},
	 { "xaccTransGetNotes", _wrap_xaccTransGetNotes, METH_O, "xaccTransGetNotes(Transaction const * trans) -> char const *"},
	 { "xaccTransSetIsClosingTxn", _wrap_xaccTransSetIsClosingTxn, METH_VARARGS, "xaccTransSetIsClosingTxn(Transaction * trans, gboolean is_closing)"},
	 { "xaccTransGetIsClosingTxn", _wrap_xaccTransGetIsClosingTxn, METH_O, "xaccTransGetIsClosingTxn(Transaction const * trans) -> gboolean"},
	 { "xaccTransGetSplit", _wrap_xaccTransGetSplit, METH_VARARGS, "xaccTransGetSplit(Transaction const * trans, int i) -> Split *"},
	 { "xaccTransGetSplitIndex", _wrap_xaccTransGetSplitIndex, METH_VARARGS, "xaccTransGetSplitIndex(Transaction const * trans, Split const * split) -> int"},
	 { "xaccTransGetSplitList", _wrap_xaccTransGetSplitList, METH_O, "xaccTransGetSplitList(Transaction const * trans) -> SplitList *"},
	 { "xaccTransGetPaymentAcctSplitList", _wrap_xaccTransGetPaymentAcctSplitList, METH_O, "xaccTransGetPaymentAcctSplitList(Transaction const * trans) -> SplitList *"},
	 { "xaccTransGetAPARAcctSplitList", _wrap_xaccTransGetAPARAcctSplitList, METH_VARARGS, "xaccTransGetAPARAcctSplitList(Transaction const * trans, gboolean strict) -> SplitList *"},
	 { "xaccTransStillHasSplit", _wrap_xaccTransStillHasSplit, METH_VARARGS, "xaccTransStillHasSplit(Transaction const * trans, Split const * s) -> gboolean"},
	 { "xaccTransGetFirstPaymentAcctSplit", _wrap_xaccTransGetFirstPaymentAcctSplit, METH_O, "xaccTransGetFirstPaymentAcctSplit(Transaction const * trans) -> Split *"},
	 { "xaccTransGetFirstAPARAcctSplit", _wrap_xaccTransGetFirstAPARAcctSplit, METH_VARARGS, "xaccTransGetFirstAPARAcctSplit(Transaction const * trans, gboolean strict) -> Split *"},
	 { "xaccTransSetReadOnly", _wrap_xaccTransSetReadOnly, METH_VARARGS, "xaccTransSetReadOnly(Transaction * trans, char const * reason)"},
	 { "xaccTransClearReadOnly", _wrap_xaccTransClearReadOnly, METH_O, "xaccTransClearReadOnly(Transaction * trans)"},
	 { "xaccTransGetReadOnly", _wrap_xaccTransGetReadOnly, METH_O, "xaccTransGetReadOnly(Transaction * trans) -> char const *"},
	 { "xaccTransIsReadonlyByPostedDate", _wrap_xaccTransIsReadonlyByPostedDate, METH_O, "xaccTransIsReadonlyByPostedDate(Transaction const * trans) -> gboolean"},
	 { "xaccTransInFutureByPostedDate", _wrap_xaccTransInFutureByPostedDate, METH_O, "xaccTransInFutureByPostedDate(Transaction const * trans) -> gboolean"},
	 { "xaccTransCountSplits", _wrap_xaccTransCountSplits, METH_O, "xaccTransCountSplits(Transaction const * trans) -> int"},
	 { "xaccTransHasReconciledSplits", _wrap_xaccTransHasReconciledSplits, METH_O, "xaccTransHasReconciledSplits(Transaction const * trans) -> gboolean"},
	 { "xaccTransHasReconciledSplitsByAccount", _wrap_xaccTransHasReconciledSplitsByAccount, METH_VARARGS, "xaccTransHasReconciledSplitsByAccount(Transaction const * trans, Account const * account) -> gboolean"},
	 { "xaccTransHasSplitsInState", _wrap_xaccTransHasSplitsInState, METH_VARARGS, "xaccTransHasSplitsInState(Transaction const * trans, char const state) -> gboolean"},
	 { "xaccTransHasSplitsInStateByAccount", _wrap_xaccTransHasSplitsInStateByAccount, METH_VARARGS, "xaccTransHasSplitsInStateByAccount(Transaction const * trans, char const state, Account const * account) -> gboolean"},
	 { "xaccTransGetCurrency", _wrap_xaccTransGetCurrency, METH_O, "xaccTransGetCurrency(Transaction const * trans) -> gnc_commodity *"},
	 { "xaccTransSetCurrency", _wrap_xaccTransSetCurrency, METH_VARARGS, "xaccTransSetCurrency(Transaction * trans, gnc_commodity * curr)"},
	 { "xaccTransGetImbalanceValue", _wrap_xaccTransGetImbalanceValue, METH_O, "xaccTransGetImbalanceValue(Transaction const * trans) -> _gnc_numeric"},
	 { "xaccTransGetImbalance", _wrap_xaccTransGetImbalance, METH_O, "xaccTransGetImbalance(Transaction const * trans) -> MonetaryList *"},
	 { "xaccTransIsBalanced", _wrap_xaccTransIsBalanced, METH_O, "xaccTransIsBalanced(Transaction const * trans) -> gboolean"},
	 { "xaccTransGetAccountValue", _wrap_xaccTransGetAccountValue, METH_VARARGS, "xaccTransGetAccountValue(Transaction const * trans, Account const * account) -> _gnc_numeric"},
	 { "xaccTransGetAccountAmount", _wrap_xaccTransGetAccountAmount, METH_VARARGS, "xaccTransGetAccountAmount(Transaction const * trans, Account const * account) -> _gnc_numeric"},
	 { "xaccTransGetRateForCommodity", _wrap_xaccTransGetRateForCommodity, METH_VARARGS, "xaccTransGetRateForCommodity(Transaction const * trans, gnc_commodity const * split_com, Split const * split_to_exclude, _gnc_numeric rate) -> gboolean"},
	 { "xaccTransGetAccountConvRate", _wrap_xaccTransGetAccountConvRate, METH_VARARGS, "xaccTransGetAccountConvRate(Transaction const * txn, Account const * acc) -> _gnc_numeric"},
	 { "xaccTransGetAccountBalance", _wrap_xaccTransGetAccountBalance, METH_VARARGS, "xaccTransGetAccountBalance(Transaction const * trans, Account const * account) -> _gnc_numeric"},
	 { "xaccTransOrder", _wrap_xaccTransOrder, METH_VARARGS, "xaccTransOrder(Transaction const * ta, Transaction const * tb) -> int"},
	 { "xaccTransOrder_num_action", _wrap_xaccTransOrder_num_action, METH_VARARGS, "xaccTransOrder_num_action(Transaction const * ta, char const * actna, Transaction const * tb, char const * actnb) -> int"},
	 { "xaccTransSetDate", _wrap_xaccTransSetDate, METH_VARARGS, "xaccTransSetDate(Transaction * trans, int day, int mon, int year)"},
	 { "xaccTransSetDatePostedGDate", _wrap_xaccTransSetDatePostedGDate, METH_VARARGS, "xaccTransSetDatePostedGDate(Transaction * trans, GDate date)"},
	 { "xaccTransSetDatePostedSecs", _wrap_xaccTransSetDatePostedSecs, METH_VARARGS, "xaccTransSetDatePostedSecs(Transaction * trans, time64 time)"},
	 { "xaccTransSetDatePostedSecsNormalized", _wrap_xaccTransSetDatePostedSecsNormalized, METH_VARARGS, "xaccTransSetDatePostedSecsNormalized(Transaction * trans, time64 time)"},
	 { "xaccTransSetDateEnteredSecs", _wrap_xaccTransSetDateEnteredSecs, METH_VARARGS, "xaccTransSetDateEnteredSecs(Transaction * trans, time64 time)"},
	 { "xaccTransSetDateDue", _wrap_xaccTransSetDateDue, METH_VARARGS, "xaccTransSetDateDue(Transaction * trans, time64 time)"},
	 { "xaccTransGetDate", _wrap_xaccTransGetDate, METH_O, "xaccTransGetDate(Transaction const * trans) -> time64"},
	 { "xaccTransRetDatePosted", _wrap_xaccTransRetDatePosted, METH_O, "xaccTransRetDatePosted(Transaction const * trans) -> time64"},
	 { "xaccTransGetDatePostedGDate", _wrap_xaccTransGetDatePostedGDate, METH_O, "xaccTransGetDatePostedGDate(Transaction const * trans) -> GDate"},
	 { "xaccTransGetDateEntered", _wrap_xaccTransGetDateEntered, METH_O, "xaccTransGetDateEntered(Transaction const * trans) -> time64"},
	 { "xaccTransRetDateEntered", _wrap_xaccTransRetDateEntered, METH_O, "xaccTransRetDateEntered(Transaction const * trans) -> time64"},
	 { "xaccTransRetDateDue", _wrap_xaccTransRetDateDue, METH_O, "xaccTransRetDateDue(Transaction const * trans) -> time64"},
	 { "xaccTransVoid", _wrap_xaccTransVoid, METH_VARARGS, "xaccTransVoid(Transaction * transaction, char const * reason)"},
	 { "xaccTransUnvoid", _wrap_xaccTransUnvoid, METH_O, "xaccTransUnvoid(Transaction * transaction)"},
	 { "xaccTransReverse", _wrap_xaccTransReverse, METH_O, "xaccTransReverse(Transaction * transaction) -> Transaction *"},
	 { "xaccTransGetReversedBy", _wrap_xaccTransGetReversedBy, METH_O, "xaccTransGetReversedBy(Transaction const * trans) -> Transaction *"},
	 { "xaccTransGetVoidStatus", _wrap_xaccTransGetVoidStatus, METH_O, "xaccTransGetVoidStatus(Transaction const * transaction) -> gboolean"},
	 { "xaccTransGetVoidReason", _wrap_xaccTransGetVoidReason, METH_O, "xaccTransGetVoidReason(Transaction const * transaction) -> char const *"},
	 { "xaccTransGetVoidTime", _wrap_xaccTransGetVoidTime, METH_O, "xaccTransGetVoidTime(Transaction const * tr) -> time64"},
	 { "GncLotClass_parent_class_set", _wrap_GncLotClass_parent_class_set, METH_VARARGS, "GncLotClass_parent_class_set(GncLotClass self, QofInstanceClass parent_class)"},
	 { "GncLotClass_parent_class_get", _wrap_GncLotClass_parent_class_get, METH_O, "GncLotClass_parent_class_get(GncLotClass self) -> QofInstanceClass"},
	 { "new_GncLotClass", _wrap_new_GncLotClass, METH_NOARGS, "new_GncLotClass() -> GncLotClass"},
	 { "delete_GncLotClass", _wrap_delete_GncLotClass, METH_O, "delete_GncLotClass(GncLotClass self)"},
	 { "GncLotClass_swigregister", GncLotClass_swigregister, METH_O, NULL},
	 { "GncLotClass_swiginit", GncLotClass_swiginit, METH_VARARGS, NULL},
	 { "gnc_lot_get_type", _wrap_gnc_lot_get_type, METH_NOARGS, "gnc_lot_get_type() -> GType"},
	 { "gnc_lot_new", _wrap_gnc_lot_new, METH_O, "gnc_lot_new(QofBook * arg1) -> GNCLot *"},
	 { "gnc_lot_destroy", _wrap_gnc_lot_destroy, METH_O, "gnc_lot_destroy(GNCLot * arg1)"},
	 { "gnc_lot_lookup", _wrap_gnc_lot_lookup, METH_VARARGS, "gnc_lot_lookup(GncGUID guid, QofBook * book) -> GNCLot *"},
	 { "gnc_lot_get_book", _wrap_gnc_lot_get_book, METH_O, "gnc_lot_get_book(GNCLot * arg1) -> QofBook *"},
	 { "gnc_lot_begin_edit", _wrap_gnc_lot_begin_edit, METH_O, "gnc_lot_begin_edit(GNCLot * lot)"},
	 { "gnc_lot_commit_edit", _wrap_gnc_lot_commit_edit, METH_O, "gnc_lot_commit_edit(GNCLot * lot)"},
	 { "gnc_lot_add_split", _wrap_gnc_lot_add_split, METH_VARARGS, "gnc_lot_add_split(GNCLot * arg1, Split * arg2)"},
	 { "gnc_lot_remove_split", _wrap_gnc_lot_remove_split, METH_VARARGS, "gnc_lot_remove_split(GNCLot * arg1, Split * arg2)"},
	 { "gnc_lot_get_split_list", _wrap_gnc_lot_get_split_list, METH_O, "gnc_lot_get_split_list(GNCLot const * arg1) -> SplitList *"},
	 { "gnc_lot_count_splits", _wrap_gnc_lot_count_splits, METH_O, "gnc_lot_count_splits(GNCLot const * arg1) -> gint"},
	 { "gnc_lot_get_account", _wrap_gnc_lot_get_account, METH_O, "gnc_lot_get_account(GNCLot const * arg1) -> Account *"},
	 { "gnc_lot_set_account", _wrap_gnc_lot_set_account, METH_VARARGS, "gnc_lot_set_account(GNCLot * arg1, Account * arg2)"},
	 { "gnc_lot_get_balance", _wrap_gnc_lot_get_balance, METH_O, "gnc_lot_get_balance(GNCLot * arg1) -> _gnc_numeric"},
	 { "gnc_lot_get_balance_before", _wrap_gnc_lot_get_balance_before, METH_VARARGS, "gnc_lot_get_balance_before(GNCLot const * arg1, Split const * arg2, _gnc_numeric arg3, _gnc_numeric arg4)"},
	 { "gnc_lot_is_closed", _wrap_gnc_lot_is_closed, METH_O, "gnc_lot_is_closed(GNCLot * arg1) -> gboolean"},
	 { "gnc_lot_get_earliest_split", _wrap_gnc_lot_get_earliest_split, METH_O, "gnc_lot_get_earliest_split(GNCLot * lot) -> Split *"},
	 { "gnc_lot_get_latest_split", _wrap_gnc_lot_get_latest_split, METH_O, "gnc_lot_get_latest_split(GNCLot * lot) -> Split *"},
	 { "gnc_lot_set_closed_unknown", _wrap_gnc_lot_set_closed_unknown, METH_O, "gnc_lot_set_closed_unknown(GNCLot * arg1)"},
	 { "gnc_lot_get_title", _wrap_gnc_lot_get_title, METH_O, "gnc_lot_get_title(GNCLot const * arg1) -> char const *"},
	 { "gnc_lot_get_notes", _wrap_gnc_lot_get_notes, METH_O, "gnc_lot_get_notes(GNCLot const * arg1) -> char const *"},
	 { "gnc_lot_set_title", _wrap_gnc_lot_set_title, METH_VARARGS, "gnc_lot_set_title(GNCLot * arg1, char const * arg2)"},
	 { "gnc_lot_set_notes", _wrap_gnc_lot_set_notes, METH_VARARGS, "gnc_lot_set_notes(GNCLot * arg1, char const * arg2)"},
	 { "gnc_lot_make_default", _wrap_gnc_lot_make_default, METH_O, "gnc_lot_make_default(Account * acc) -> GNCLot *"},
	 { "qof_backend_get_error", _wrap_qof_backend_get_error, METH_O, "qof_backend_get_error(QofBackend * arg1) -> QofBackendError"},
	 { "qof_backend_set_error", _wrap_qof_backend_set_error, METH_VARARGS, "qof_backend_set_error(QofBackend * arg1, QofBackendError arg2)"},
	 { "qof_backend_can_rollback", _wrap_qof_backend_can_rollback, METH_O, "qof_backend_can_rollback(QofBackend * arg1) -> gboolean"},
	 { "qof_backend_rollback_instance", _wrap_qof_backend_rollback_instance, METH_VARARGS, "qof_backend_rollback_instance(QofBackend * arg1, QofInstance * arg2)"},
	 { "qof_load_backend_library", _wrap_qof_load_backend_library, METH_VARARGS, "qof_load_backend_library(gchar const * directory, gchar const * module_name) -> gboolean"},
	 { "qof_finalize_backend_libraries", _wrap_qof_finalize_backend_libraries, METH_NOARGS, "qof_finalize_backend_libraries()"},
	 { "qof_book_get_backend", _wrap_qof_book_get_backend, METH_O, "qof_book_get_backend(QofBook const * book) -> QofBackend *"},
	 { "qof_book_set_backend", _wrap_qof_book_set_backend, METH_VARARGS, "qof_book_set_backend(QofBook * book, QofBackend * arg2)"},
	 { "qof_session_new", _wrap_qof_session_new, METH_NOARGS, "qof_session_new() -> QofSession *"},
	 { "qof_session_destroy", _wrap_qof_session_destroy, METH_O, "qof_session_destroy(QofSession * session)"},
	 { "qof_session_swap_data", _wrap_qof_session_swap_data, METH_VARARGS, "qof_session_swap_data(QofSession * session_1, QofSession * session_2)"},
	 { "qof_session_begin", _wrap_qof_session_begin, METH_VARARGS, "qof_session_begin(QofSession * session, char const * book_id, gboolean ignore_lock, gboolean create, gboolean force)"},
	 { "qof_session_load", _wrap_qof_session_load, METH_VARARGS, "qof_session_load(QofSession * session, QofPercentageFunc percentage_func)"},
	 { "qof_session_get_error", _wrap_qof_session_get_error, METH_O, "qof_session_get_error(QofSession * session) -> QofBackendError"},
	 { "qof_session_get_error_message", _wrap_qof_session_get_error_message, METH_O, "qof_session_get_error_message(QofSession const * session) -> char const *"},
	 { "qof_session_pop_error", _wrap_qof_session_pop_error, METH_O, "qof_session_pop_error(QofSession * session) -> QofBackendError"},
	 { "qof_session_get_book", _wrap_qof_session_get_book, METH_O, "qof_session_get_book(QofSession const * session) -> QofBook *"},
	 { "qof_session_get_file_path", _wrap_qof_session_get_file_path, METH_O, "qof_session_get_file_path(QofSession const * session) -> char const *"},
	 { "qof_session_get_url", _wrap_qof_session_get_url, METH_O, "qof_session_get_url(QofSession const * session) -> char const *"},
	 { "qof_session_save_in_progress", _wrap_qof_session_save_in_progress, METH_O, "qof_session_save_in_progress(QofSession const * session) -> gboolean"},
	 { "qof_session_get_backend", _wrap_qof_session_get_backend, METH_O, "qof_session_get_backend(QofSession const * session) -> QofBackend *"},
	 { "qof_session_save", _wrap_qof_session_save, METH_VARARGS, "qof_session_save(QofSession * session, QofPercentageFunc percentage_func)"},
	 { "qof_session_safe_save", _wrap_qof_session_safe_save, METH_VARARGS, "qof_session_safe_save(QofSession * session, QofPercentageFunc percentage_func)"},
	 { "qof_session_end", _wrap_qof_session_end, METH_O, "qof_session_end(QofSession * session)"},
	 { "qof_session_events_pending", _wrap_qof_session_events_pending, METH_O, "qof_session_events_pending(QofSession const * session) -> gboolean"},
	 { "qof_session_process_events", _wrap_qof_session_process_events, METH_O, "qof_session_process_events(QofSession * session) -> gboolean"},
	 { "qof_session_export", _wrap_qof_session_export, METH_VARARGS, "qof_session_export(QofSession * tmp_session, QofSession * real_session, QofPercentageFunc percentage_func) -> gboolean"},
	 { "qof_backend_get_registered_access_method_list", _wrap_qof_backend_get_registered_access_method_list, METH_NOARGS, "qof_backend_get_registered_access_method_list() -> GList *"},
	 { "qof_session_ensure_all_data_loaded", _wrap_qof_session_ensure_all_data_loaded, METH_O, "qof_session_ensure_all_data_loaded(QofSession * session)"},
	 { "qof_book_use_trading_accounts", _wrap_qof_book_use_trading_accounts, METH_O, "qof_book_use_trading_accounts(QofBook const * book) -> gboolean"},
	 { "qof_book_get_book_currency_name", _wrap_qof_book_get_book_currency_name, METH_O, "qof_book_get_book_currency_name(QofBook * book) -> gchar const *"},
	 { "qof_book_get_default_gains_policy", _wrap_qof_book_get_default_gains_policy, METH_O, "qof_book_get_default_gains_policy(QofBook * book) -> gchar const *"},
	 { "qof_book_get_default_gain_loss_acct_guid", _wrap_qof_book_get_default_gain_loss_acct_guid, METH_O, "qof_book_get_default_gain_loss_acct_guid(QofBook * book) -> GncGUID"},
	 { "qof_book_uses_autoreadonly", _wrap_qof_book_uses_autoreadonly, METH_O, "qof_book_uses_autoreadonly(QofBook const * book) -> gboolean"},
	 { "qof_book_get_num_days_autoreadonly", _wrap_qof_book_get_num_days_autoreadonly, METH_O, "qof_book_get_num_days_autoreadonly(QofBook const * book) -> gint"},
	 { "qof_book_get_autoreadonly_gdate", _wrap_qof_book_get_autoreadonly_gdate, METH_O, "qof_book_get_autoreadonly_gdate(QofBook const * book) -> GDate *"},
	 { "qof_book_use_split_action_for_num_field", _wrap_qof_book_use_split_action_for_num_field, METH_O, "qof_book_use_split_action_for_num_field(QofBook const * book) -> gboolean"},
	 { "qof_book_shutting_down", _wrap_qof_book_shutting_down, METH_O, "qof_book_shutting_down(QofBook const * book) -> gboolean"},
	 { "qof_book_session_not_saved", _wrap_qof_book_session_not_saved, METH_O, "qof_book_session_not_saved(QofBook const * book) -> gboolean"},
	 { "qof_collection_new", _wrap_qof_collection_new, METH_O, "qof_collection_new(QofIdType type) -> QofCollection *"},
	 { "qof_collection_count", _wrap_qof_collection_count, METH_O, "qof_collection_count(QofCollection const * col) -> guint"},
	 { "qof_collection_destroy", _wrap_qof_collection_destroy, METH_O, "qof_collection_destroy(QofCollection * col)"},
	 { "qof_collection_get_type", _wrap_qof_collection_get_type, METH_O, "qof_collection_get_type(QofCollection const * arg1) -> QofIdType"},
	 { "qof_collection_lookup_entity", _wrap_qof_collection_lookup_entity, METH_VARARGS, "qof_collection_lookup_entity(QofCollection const * arg1, GncGUID arg2) -> QofInstance *"},
	 { "qof_collection_foreach", _wrap_qof_collection_foreach, METH_VARARGS, "qof_collection_foreach(QofCollection const * arg1, QofInstanceForeachCB arg2, gpointer user_data)"},
	 { "qof_collection_get_data", _wrap_qof_collection_get_data, METH_O, "qof_collection_get_data(QofCollection const * col) -> gpointer"},
	 { "qof_collection_set_data", _wrap_qof_collection_set_data, METH_VARARGS, "qof_collection_set_data(QofCollection * col, gpointer user_data)"},
	 { "qof_collection_is_dirty", _wrap_qof_collection_is_dirty, METH_O, "qof_collection_is_dirty(QofCollection const * col) -> gboolean"},
	 { "qof_collection_add_entity", _wrap_qof_collection_add_entity, METH_VARARGS, "qof_collection_add_entity(QofCollection * coll, QofInstance * ent) -> gboolean"},
	 { "qof_collection_remove_entity", _wrap_qof_collection_remove_entity, METH_O, "qof_collection_remove_entity(QofInstance * ent)"},
	 { "qof_collection_compare", _wrap_qof_collection_compare, METH_VARARGS, "qof_collection_compare(QofCollection * target, QofCollection * merge) -> gint"},
	 { "qof_collection_from_glist", _wrap_qof_collection_from_glist, METH_VARARGS, "qof_collection_from_glist(QofIdType type, GList const * glist) -> QofCollection *"},
	 { "qof_query_init", _wrap_qof_query_init, METH_NOARGS, "qof_query_init()"},
	 { "qof_query_shutdown", _wrap_qof_query_shutdown, METH_NOARGS, "qof_query_shutdown()"},
	 { "qof_query_build_param_list", _wrap_qof_query_build_param_list, METH_VARARGS, "qof_query_build_param_list(char const * param) -> QofQueryParamList *"},
	 { "qof_query_create", _wrap_qof_query_create, METH_NOARGS, "qof_query_create() -> QofQuery *"},
	 { "qof_query_create_for", _wrap_qof_query_create_for, METH_O, "qof_query_create_for(QofIdTypeConst obj_type) -> QofQuery *"},
	 { "qof_query_destroy", _wrap_qof_query_destroy, METH_O, "qof_query_destroy(QofQuery * q)"},
	 { "qof_query_search_for", _wrap_qof_query_search_for, METH_VARARGS, "qof_query_search_for(QofQuery * query, QofIdTypeConst obj_type)"},
	 { "qof_query_set_book", _wrap_qof_query_set_book, METH_VARARGS, "qof_query_set_book(QofQuery * q, QofBook * book)"},
	 { "qof_query_add_term", _wrap_qof_query_add_term, METH_VARARGS, "qof_query_add_term(QofQuery * query, QofQueryParamList * param_list, _QofQueryPredData pred_data, QofQueryOp op)"},
	 { "qof_query_add_guid_match", _wrap_qof_query_add_guid_match, METH_VARARGS, "qof_query_add_guid_match(QofQuery * q, QofQueryParamList * param_list, GncGUID guid, QofQueryOp op)"},
	 { "qof_query_add_guid_list_match", _wrap_qof_query_add_guid_list_match, METH_VARARGS, "qof_query_add_guid_list_match(QofQuery * q, QofQueryParamList * param_list, GList * guid_list, QofGuidMatch options, QofQueryOp op)"},
	 { "qof_query_add_boolean_match", _wrap_qof_query_add_boolean_match, METH_VARARGS, "qof_query_add_boolean_match(QofQuery * q, QofQueryParamList * param_list, gboolean value, QofQueryOp op)"},
	 { "qof_query_run", _wrap_qof_query_run, METH_O, "qof_query_run(QofQuery * query) -> GList *"},
	 { "qof_query_last_run", _wrap_qof_query_last_run, METH_O, "qof_query_last_run(QofQuery * query) -> GList *"},
	 { "qof_query_run_subquery", _wrap_qof_query_run_subquery, METH_VARARGS, "qof_query_run_subquery(QofQuery * subquery, QofQuery const * primary_query) -> GList *"},
	 { "qof_query_clear", _wrap_qof_query_clear, METH_O, "qof_query_clear(QofQuery * query)"},
	 { "qof_query_purge_terms", _wrap_qof_query_purge_terms, METH_VARARGS, "qof_query_purge_terms(QofQuery * q, QofQueryParamList * param_list)"},
	 { "qof_query_has_terms", _wrap_qof_query_has_terms, METH_O, "qof_query_has_terms(QofQuery * q) -> int"},
	 { "qof_query_num_terms", _wrap_qof_query_num_terms, METH_O, "qof_query_num_terms(QofQuery * q) -> int"},
	 { "qof_query_has_term_type", _wrap_qof_query_has_term_type, METH_VARARGS, "qof_query_has_term_type(QofQuery * q, QofQueryParamList * term_param) -> gboolean"},
	 { "qof_query_get_term_type", _wrap_qof_query_get_term_type, METH_VARARGS, "qof_query_get_term_type(QofQuery * q, QofQueryParamList * term_param) -> GSList *"},
	 { "qof_query_copy", _wrap_qof_query_copy, METH_O, "qof_query_copy(QofQuery * q) -> QofQuery *"},
	 { "qof_query_invert", _wrap_qof_query_invert, METH_O, "qof_query_invert(QofQuery * q) -> QofQuery *"},
	 { "qof_query_merge", _wrap_qof_query_merge, METH_VARARGS, "qof_query_merge(QofQuery * q1, QofQuery * q2, QofQueryOp op) -> QofQuery *"},
	 { "qof_query_merge_in_place", _wrap_qof_query_merge_in_place, METH_VARARGS, "qof_query_merge_in_place(QofQuery * q1, QofQuery * q2, QofQueryOp op)"},
	 { "qof_query_set_sort_order", _wrap_qof_query_set_sort_order, METH_VARARGS, "qof_query_set_sort_order(QofQuery * q, QofQueryParamList * primary_sort_params, QofQueryParamList * secondary_sort_params, QofQueryParamList * tertiary_sort_params)"},
	 { "qof_query_set_sort_options", _wrap_qof_query_set_sort_options, METH_VARARGS, "qof_query_set_sort_options(QofQuery * q, gint prim_op, gint sec_op, gint tert_op)"},
	 { "qof_query_set_sort_increasing", _wrap_qof_query_set_sort_increasing, METH_VARARGS, "qof_query_set_sort_increasing(QofQuery * q, gboolean prim_inc, gboolean sec_inc, gboolean tert_inc)"},
	 { "qof_query_set_max_results", _wrap_qof_query_set_max_results, METH_VARARGS, "qof_query_set_max_results(QofQuery * q, int n)"},
	 { "qof_query_equal", _wrap_qof_query_equal, METH_VARARGS, "qof_query_equal(QofQuery const * q1, QofQuery const * q2) -> gboolean"},
	 { "qof_query_print", _wrap_qof_query_print, METH_O, "qof_query_print(QofQuery * query)"},
	 { "qof_query_get_search_for", _wrap_qof_query_get_search_for, METH_O, "qof_query_get_search_for(QofQuery const * q) -> QofIdType"},
	 { "qof_query_get_books", _wrap_qof_query_get_books, METH_O, "qof_query_get_books(QofQuery * q) -> GList *"},
	 { "_QofQueryPredData_type_name_set", _wrap__QofQueryPredData_type_name_set, METH_VARARGS, "_QofQueryPredData_type_name_set(_QofQueryPredData self, QofType type_name)"},
	 { "_QofQueryPredData_type_name_get", _wrap__QofQueryPredData_type_name_get, METH_O, "_QofQueryPredData_type_name_get(_QofQueryPredData self) -> QofType"},
	 { "_QofQueryPredData_how_set", _wrap__QofQueryPredData_how_set, METH_VARARGS, "_QofQueryPredData_how_set(_QofQueryPredData self, QofQueryCompare how)"},
	 { "_QofQueryPredData_how_get", _wrap__QofQueryPredData_how_get, METH_O, "_QofQueryPredData_how_get(_QofQueryPredData self) -> QofQueryCompare"},
	 { "new__QofQueryPredData", _wrap_new__QofQueryPredData, METH_NOARGS, "new__QofQueryPredData() -> _QofQueryPredData"},
	 { "delete__QofQueryPredData", _wrap_delete__QofQueryPredData, METH_O, "delete__QofQueryPredData(_QofQueryPredData self)"},
	 { "_QofQueryPredData_swigregister", _QofQueryPredData_swigregister, METH_O, NULL},
	 { "_QofQueryPredData_swiginit", _QofQueryPredData_swiginit, METH_VARARGS, NULL},
	 { "qof_query_string_predicate", _wrap_qof_query_string_predicate, METH_VARARGS, "qof_query_string_predicate(QofQueryCompare how, gchar const * str, QofStringMatch options, gboolean is_regex) -> _QofQueryPredData"},
	 { "qof_query_date_predicate", _wrap_qof_query_date_predicate, METH_VARARGS, "qof_query_date_predicate(QofQueryCompare how, QofDateMatch options, time64 date) -> _QofQueryPredData"},
	 { "qof_query_numeric_predicate", _wrap_qof_query_numeric_predicate, METH_VARARGS, "qof_query_numeric_predicate(QofQueryCompare how, QofNumericMatch options, _gnc_numeric value) -> _QofQueryPredData"},
	 { "qof_query_guid_predicate", _wrap_qof_query_guid_predicate, METH_VARARGS, "qof_query_guid_predicate(QofGuidMatch options, GList * guids) -> _QofQueryPredData"},
	 { "qof_query_int32_predicate", _wrap_qof_query_int32_predicate, METH_VARARGS, "qof_query_int32_predicate(QofQueryCompare how, gint32 val) -> _QofQueryPredData"},
	 { "qof_query_int64_predicate", _wrap_qof_query_int64_predicate, METH_VARARGS, "qof_query_int64_predicate(QofQueryCompare how, gint64 val) -> _QofQueryPredData"},
	 { "qof_query_double_predicate", _wrap_qof_query_double_predicate, METH_VARARGS, "qof_query_double_predicate(QofQueryCompare how, double val) -> _QofQueryPredData"},
	 { "qof_query_boolean_predicate", _wrap_qof_query_boolean_predicate, METH_VARARGS, "qof_query_boolean_predicate(QofQueryCompare how, gboolean val) -> _QofQueryPredData"},
	 { "qof_query_char_predicate", _wrap_qof_query_char_predicate, METH_VARARGS, "qof_query_char_predicate(QofCharMatch options, gchar const * chars) -> _QofQueryPredData"},
	 { "qof_query_collect_predicate", _wrap_qof_query_collect_predicate, METH_VARARGS, "qof_query_collect_predicate(QofGuidMatch options, QofCollection * coll) -> _QofQueryPredData"},
	 { "qof_query_choice_predicate", _wrap_qof_query_choice_predicate, METH_VARARGS, "qof_query_choice_predicate(QofGuidMatch options, GList * guids) -> _QofQueryPredData"},
	 { "qof_query_core_predicate_copy", _wrap_qof_query_core_predicate_copy, METH_O, "qof_query_core_predicate_copy(_QofQueryPredData pdata) -> _QofQueryPredData"},
	 { "qof_query_core_predicate_free", _wrap_qof_query_core_predicate_free, METH_O, "qof_query_core_predicate_free(_QofQueryPredData pdata)"},
	 { "qof_query_date_predicate_get_date", _wrap_qof_query_date_predicate_get_date, METH_O, "qof_query_date_predicate_get_date(_QofQueryPredData pd) -> gboolean"},
	 { "qof_query_core_to_string", _wrap_qof_query_core_to_string, METH_VARARGS, "qof_query_core_to_string(QofType arg1, gpointer object, QofParam * getter) -> char *"},
	 { "qof_string_number_compare_func", _wrap_qof_string_number_compare_func, METH_VARARGS, "qof_string_number_compare_func(gpointer a, gpointer b, gint options, QofParam * this_param) -> int"},
	 { "GncGUID_reserved_set", _wrap_GncGUID_reserved_set, METH_VARARGS, "GncGUID_reserved_set(GncGUID self, unsigned char [16] reserved)"},
	 { "GncGUID_reserved_get", _wrap_GncGUID_reserved_get, METH_O, "GncGUID_reserved_get(GncGUID self) -> unsigned char [16]"},
	 { "new_GncGUID", _wrap_new_GncGUID, METH_NOARGS, "new_GncGUID() -> GncGUID"},
	 { "delete_GncGUID", _wrap_delete_GncGUID, METH_O, "delete_GncGUID(GncGUID self)"},
	 { "GncGUID_swigregister", GncGUID_swigregister, METH_O, NULL},
	 { "GncGUID_swiginit", GncGUID_swiginit, METH_VARARGS, NULL},
	 { "gnc_guid_get_type", _wrap_gnc_guid_get_type, METH_NOARGS, "gnc_guid_get_type() -> GType"},
	 { "gnc_value_get_guid", _wrap_gnc_value_get_guid, METH_O, "gnc_value_get_guid(GValue const * value) -> GncGUID"},
	 { "guid_replace", _wrap_guid_replace, METH_O, "guid_replace(GncGUID guid)"},
	 { "guid_new_return", _wrap_guid_new_return, METH_NOARGS, "guid_new_return() -> GncGUID"},
	 { "guid_null", _wrap_guid_null, METH_NOARGS, "guid_null() -> GncGUID"},
	 { "guid_malloc", _wrap_guid_malloc, METH_NOARGS, "guid_malloc() -> GncGUID"},
	 { "guid_new", _wrap_guid_new, METH_NOARGS, "guid_new() -> GncGUID"},
	 { "guid_free", _wrap_guid_free, METH_O, "guid_free(GncGUID guid)"},
	 { "guid_copy", _wrap_guid_copy, METH_O, "guid_copy(GncGUID guid) -> GncGUID"},
	 { "guid_to_string", _wrap_guid_to_string, METH_O, "guid_to_string(GncGUID guid) -> gchar *"},
	 { "guid_to_string_buff", _wrap_guid_to_string_buff, METH_VARARGS, "guid_to_string_buff(GncGUID guid, gchar * buff) -> gchar *"},
	 { "string_to_guid", _wrap_string_to_guid, METH_VARARGS, "string_to_guid(gchar const * string, GncGUID guid) -> gboolean"},
	 { "guid_equal", _wrap_guid_equal, METH_VARARGS, "guid_equal(GncGUID guid_1, GncGUID guid_2) -> gboolean"},
	 { "guid_compare", _wrap_guid_compare, METH_VARARGS, "guid_compare(GncGUID g1, GncGUID g2) -> gint"},
	 { "guid_hash_to_guint", _wrap_guid_hash_to_guint, METH_O, "guid_hash_to_guint(gconstpointer ptr) -> guint"},
	 { "guid_g_hash_table_equal", _wrap_guid_g_hash_table_equal, METH_VARARGS, "guid_g_hash_table_equal(gconstpointer guid_a, gconstpointer guid_b) -> gint"},
	 { "guid_hash_table_new", _wrap_guid_hash_table_new, METH_NOARGS, "guid_hash_table_new() -> GHashTable *"},
	 { "_gnc_numeric_num_set", _wrap__gnc_numeric_num_set, METH_VARARGS, "_gnc_numeric_num_set(_gnc_numeric self, gint64 num)"},
	 { "_gnc_numeric_num_get", _wrap__gnc_numeric_num_get, METH_O, "_gnc_numeric_num_get(_gnc_numeric self) -> gint64"},
	 { "_gnc_numeric_denom_set", _wrap__gnc_numeric_denom_set, METH_VARARGS, "_gnc_numeric_denom_set(_gnc_numeric self, gint64 denom)"},
	 { "_gnc_numeric_denom_get", _wrap__gnc_numeric_denom_get, METH_O, "_gnc_numeric_denom_get(_gnc_numeric self) -> gint64"},
	 { "new__gnc_numeric", _wrap_new__gnc_numeric, METH_NOARGS, "new__gnc_numeric() -> _gnc_numeric"},
	 { "delete__gnc_numeric", _wrap_delete__gnc_numeric, METH_O, "delete__gnc_numeric(_gnc_numeric self)"},
	 { "_gnc_numeric_swigregister", _gnc_numeric_swigregister, METH_O, NULL},
	 { "_gnc_numeric_swiginit", _gnc_numeric_swiginit, METH_VARARGS, NULL},
	 { "gnc_numeric_create", _wrap_gnc_numeric_create, METH_VARARGS, "gnc_numeric_create(gint64 num, gint64 denom) -> _gnc_numeric"},
	 { "gnc_numeric_zero", _wrap_gnc_numeric_zero, METH_NOARGS, "gnc_numeric_zero() -> _gnc_numeric"},
	 { "double_to_gnc_numeric", _wrap_double_to_gnc_numeric, METH_VARARGS, "double_to_gnc_numeric(double n, gint64 denom, gint how) -> _gnc_numeric"},
	 { "string_to_gnc_numeric", _wrap_string_to_gnc_numeric, METH_VARARGS, "string_to_gnc_numeric(gchar const * str, _gnc_numeric n) -> gboolean"},
	 { "gnc_numeric_error", _wrap_gnc_numeric_error, METH_O, "gnc_numeric_error(GNCNumericErrorCode error_code) -> _gnc_numeric"},
	 { "gnc_numeric_errorCode_to_string", _wrap_gnc_numeric_errorCode_to_string, METH_O, "gnc_numeric_errorCode_to_string(GNCNumericErrorCode error_code) -> char const *"},
	 { "gnc_numeric_num", _wrap_gnc_numeric_num, METH_O, "gnc_numeric_num(_gnc_numeric a) -> gint64"},
	 { "gnc_numeric_denom", _wrap_gnc_numeric_denom, METH_O, "gnc_numeric_denom(_gnc_numeric a) -> gint64"},
	 { "gnc_numeric_to_double", _wrap_gnc_numeric_to_double, METH_O, "gnc_numeric_to_double(_gnc_numeric n) -> gdouble"},
	 { "gnc_numeric_to_string", _wrap_gnc_numeric_to_string, METH_O, "gnc_numeric_to_string(_gnc_numeric n) -> gchar *"},
	 { "gnc_num_dbg_to_string", _wrap_gnc_num_dbg_to_string, METH_O, "gnc_num_dbg_to_string(_gnc_numeric n) -> gchar *"},
	 { "gnc_numeric_check", _wrap_gnc_numeric_check, METH_O, "gnc_numeric_check(_gnc_numeric a) -> GNCNumericErrorCode"},
	 { "gnc_numeric_compare", _wrap_gnc_numeric_compare, METH_VARARGS, "gnc_numeric_compare(_gnc_numeric a, _gnc_numeric b) -> gint"},
	 { "gnc_numeric_zero_p", _wrap_gnc_numeric_zero_p, METH_O, "gnc_numeric_zero_p(_gnc_numeric a) -> gboolean"},
	 { "gnc_numeric_negative_p", _wrap_gnc_numeric_negative_p, METH_O, "gnc_numeric_negative_p(_gnc_numeric a) -> gboolean"},
	 { "gnc_numeric_positive_p", _wrap_gnc_numeric_positive_p, METH_O, "gnc_numeric_positive_p(_gnc_numeric a) -> gboolean"},
	 { "gnc_numeric_eq", _wrap_gnc_numeric_eq, METH_VARARGS, "gnc_numeric_eq(_gnc_numeric a, _gnc_numeric b) -> gboolean"},
	 { "gnc_numeric_equal", _wrap_gnc_numeric_equal, METH_VARARGS, "gnc_numeric_equal(_gnc_numeric a, _gnc_numeric b) -> gboolean"},
	 { "gnc_numeric_same", _wrap_gnc_numeric_same, METH_VARARGS, "gnc_numeric_same(_gnc_numeric a, _gnc_numeric b, gint64 denom, gint how) -> gint"},
	 { "gnc_numeric_add", _wrap_gnc_numeric_add, METH_VARARGS, "gnc_numeric_add(_gnc_numeric a, _gnc_numeric b, gint64 denom, gint how) -> _gnc_numeric"},
	 { "gnc_numeric_sub", _wrap_gnc_numeric_sub, METH_VARARGS, "gnc_numeric_sub(_gnc_numeric a, _gnc_numeric b, gint64 denom, gint how) -> _gnc_numeric"},
	 { "gnc_numeric_mul", _wrap_gnc_numeric_mul, METH_VARARGS, "gnc_numeric_mul(_gnc_numeric a, _gnc_numeric b, gint64 denom, gint how) -> _gnc_numeric"},
	 { "gnc_numeric_div", _wrap_gnc_numeric_div, METH_VARARGS, "gnc_numeric_div(_gnc_numeric x, _gnc_numeric y, gint64 denom, gint how) -> _gnc_numeric"},
	 { "gnc_numeric_neg", _wrap_gnc_numeric_neg, METH_O, "gnc_numeric_neg(_gnc_numeric a) -> _gnc_numeric"},
	 { "gnc_numeric_abs", _wrap_gnc_numeric_abs, METH_O, "gnc_numeric_abs(_gnc_numeric a) -> _gnc_numeric"},
	 { "gnc_numeric_add_fixed", _wrap_gnc_numeric_add_fixed, METH_VARARGS, "gnc_numeric_add_fixed(_gnc_numeric a, _gnc_numeric b) -> _gnc_numeric"},
	 { "gnc_numeric_sub_fixed", _wrap_gnc_numeric_sub_fixed, METH_VARARGS, "gnc_numeric_sub_fixed(_gnc_numeric a, _gnc_numeric b) -> _gnc_numeric"},
	 { "gnc_numeric_convert", _wrap_gnc_numeric_convert, METH_VARARGS, "gnc_numeric_convert(_gnc_numeric n, gint64 denom, gint how) -> _gnc_numeric"},
	 { "gnc_numeric_reduce", _wrap_gnc_numeric_reduce, METH_O, "gnc_numeric_reduce(_gnc_numeric n) -> _gnc_numeric"},
	 { "gnc_numeric_to_decimal", _wrap_gnc_numeric_to_decimal, METH_VARARGS, "gnc_numeric_to_decimal(_gnc_numeric a, guint8 * max_decimal_places) -> gboolean"},
	 { "gnc_numeric_invert", _wrap_gnc_numeric_invert, METH_O, "gnc_numeric_invert(_gnc_numeric num) -> _gnc_numeric"},
	 { "gnc_numeric_get_type", _wrap_gnc_numeric_get_type, METH_NOARGS, "gnc_numeric_get_type() -> GType"},
	 { "gnc_commodity_get_type", _wrap_gnc_commodity_get_type, METH_NOARGS, "gnc_commodity_get_type() -> GType"},
	 { "gnc_commodity_namespace_get_type", _wrap_gnc_commodity_namespace_get_type, METH_NOARGS, "gnc_commodity_namespace_get_type() -> GType"},
	 { "gnc_quote_source_fq_installed", _wrap_gnc_quote_source_fq_installed, METH_NOARGS, "gnc_quote_source_fq_installed() -> gboolean"},
	 { "gnc_quote_source_fq_version", _wrap_gnc_quote_source_fq_version, METH_NOARGS, "gnc_quote_source_fq_version() -> char const *"},
	 { "gnc_quote_source_set_fq_installed", _wrap_gnc_quote_source_set_fq_installed, METH_VARARGS, "gnc_quote_source_set_fq_installed(char const * version_string, GList const * sources_list)"},
	 { "gnc_quote_source_num_entries", _wrap_gnc_quote_source_num_entries, METH_O, "gnc_quote_source_num_entries(QuoteSourceType type) -> gint"},
	 { "gnc_quote_source_add_new", _wrap_gnc_quote_source_add_new, METH_VARARGS, "gnc_quote_source_add_new(char const * name, gboolean supported) -> gnc_quote_source *"},
	 { "gnc_quote_source_lookup_by_internal", _wrap_gnc_quote_source_lookup_by_internal, METH_O, "gnc_quote_source_lookup_by_internal(char const * internal_name) -> gnc_quote_source *"},
	 { "gnc_quote_source_lookup_by_ti", _wrap_gnc_quote_source_lookup_by_ti, METH_VARARGS, "gnc_quote_source_lookup_by_ti(QuoteSourceType type, gint index) -> gnc_quote_source *"},
	 { "gnc_quote_source_get_supported", _wrap_gnc_quote_source_get_supported, METH_O, "gnc_quote_source_get_supported(gnc_quote_source const * source) -> gboolean"},
	 { "gnc_quote_source_get_type", _wrap_gnc_quote_source_get_type, METH_O, "gnc_quote_source_get_type(gnc_quote_source const * source) -> QuoteSourceType"},
	 { "gnc_quote_source_get_index", _wrap_gnc_quote_source_get_index, METH_O, "gnc_quote_source_get_index(gnc_quote_source const * source) -> gint"},
	 { "gnc_quote_source_get_user_name", _wrap_gnc_quote_source_get_user_name, METH_O, "gnc_quote_source_get_user_name(gnc_quote_source const * source) -> char const *"},
	 { "gnc_quote_source_get_internal_name", _wrap_gnc_quote_source_get_internal_name, METH_O, "gnc_quote_source_get_internal_name(gnc_quote_source const * source) -> char const *"},
	 { "gnc_commodity_new", _wrap_gnc_commodity_new, METH_VARARGS, "gnc_commodity_new(QofBook * book, char const * fullname, char const * commodity_namespace, char const * mnemonic, char const * cusip, int fraction) -> gnc_commodity *"},
	 { "gnc_commodity_destroy", _wrap_gnc_commodity_destroy, METH_O, "gnc_commodity_destroy(gnc_commodity * cm)"},
	 { "gnc_commodity_copy", _wrap_gnc_commodity_copy, METH_VARARGS, "gnc_commodity_copy(gnc_commodity * dest, gnc_commodity const * src)"},
	 { "gnc_commodity_clone", _wrap_gnc_commodity_clone, METH_VARARGS, "gnc_commodity_clone(gnc_commodity const * src, QofBook * dest_book) -> gnc_commodity *"},
	 { "gnc_commodity_get_mnemonic", _wrap_gnc_commodity_get_mnemonic, METH_O, "gnc_commodity_get_mnemonic(gnc_commodity const * cm) -> char const *"},
	 { "gnc_commodity_get_namespace", _wrap_gnc_commodity_get_namespace, METH_O, "gnc_commodity_get_namespace(gnc_commodity const * cm) -> char const *"},
	 { "gnc_commodity_get_namespace_ds", _wrap_gnc_commodity_get_namespace_ds, METH_O, "gnc_commodity_get_namespace_ds(gnc_commodity const * cm) -> gnc_commodity_namespace *"},
	 { "gnc_commodity_get_fullname", _wrap_gnc_commodity_get_fullname, METH_O, "gnc_commodity_get_fullname(gnc_commodity const * cm) -> char const *"},
	 { "gnc_commodity_get_printname", _wrap_gnc_commodity_get_printname, METH_O, "gnc_commodity_get_printname(gnc_commodity const * cm) -> char const *"},
	 { "gnc_commodity_get_cusip", _wrap_gnc_commodity_get_cusip, METH_O, "gnc_commodity_get_cusip(gnc_commodity const * cm) -> char const *"},
	 { "gnc_commodity_get_unique_name", _wrap_gnc_commodity_get_unique_name, METH_O, "gnc_commodity_get_unique_name(gnc_commodity const * cm) -> char const *"},
	 { "gnc_commodity_get_fraction", _wrap_gnc_commodity_get_fraction, METH_O, "gnc_commodity_get_fraction(gnc_commodity const * cm) -> int"},
	 { "gnc_commodity_get_quote_flag", _wrap_gnc_commodity_get_quote_flag, METH_O, "gnc_commodity_get_quote_flag(gnc_commodity const * cm) -> gboolean"},
	 { "gnc_commodity_get_quote_source", _wrap_gnc_commodity_get_quote_source, METH_O, "gnc_commodity_get_quote_source(gnc_commodity const * cm) -> gnc_quote_source *"},
	 { "gnc_commodity_get_default_quote_source", _wrap_gnc_commodity_get_default_quote_source, METH_O, "gnc_commodity_get_default_quote_source(gnc_commodity const * cm) -> gnc_quote_source *"},
	 { "gnc_commodity_get_quote_tz", _wrap_gnc_commodity_get_quote_tz, METH_O, "gnc_commodity_get_quote_tz(gnc_commodity const * cm) -> char const *"},
	 { "gnc_commodity_get_user_symbol", _wrap_gnc_commodity_get_user_symbol, METH_O, "gnc_commodity_get_user_symbol(gnc_commodity const * cm) -> char const *"},
	 { "gnc_commodity_get_default_symbol", _wrap_gnc_commodity_get_default_symbol, METH_O, "gnc_commodity_get_default_symbol(gnc_commodity const * cm) -> char const *"},
	 { "gnc_commodity_get_nice_symbol", _wrap_gnc_commodity_get_nice_symbol, METH_O, "gnc_commodity_get_nice_symbol(gnc_commodity const * cm) -> char const *"},
	 { "gnc_commodity_set_mnemonic", _wrap_gnc_commodity_set_mnemonic, METH_VARARGS, "gnc_commodity_set_mnemonic(gnc_commodity * cm, char const * mnemonic)"},
	 { "gnc_commodity_set_namespace", _wrap_gnc_commodity_set_namespace, METH_VARARGS, "gnc_commodity_set_namespace(gnc_commodity * cm, char const * new_namespace)"},
	 { "gnc_commodity_set_fullname", _wrap_gnc_commodity_set_fullname, METH_VARARGS, "gnc_commodity_set_fullname(gnc_commodity * cm, char const * fullname)"},
	 { "gnc_commodity_set_cusip", _wrap_gnc_commodity_set_cusip, METH_VARARGS, "gnc_commodity_set_cusip(gnc_commodity * cm, char const * cusip)"},
	 { "gnc_commodity_set_fraction", _wrap_gnc_commodity_set_fraction, METH_VARARGS, "gnc_commodity_set_fraction(gnc_commodity * cm, int smallest_fraction)"},
	 { "gnc_commodity_user_set_quote_flag", _wrap_gnc_commodity_user_set_quote_flag, METH_VARARGS, "gnc_commodity_user_set_quote_flag(gnc_commodity * cm, gboolean const flag)"},
	 { "gnc_commodity_set_quote_flag", _wrap_gnc_commodity_set_quote_flag, METH_VARARGS, "gnc_commodity_set_quote_flag(gnc_commodity * cm, gboolean const flag)"},
	 { "gnc_commodity_set_quote_source", _wrap_gnc_commodity_set_quote_source, METH_VARARGS, "gnc_commodity_set_quote_source(gnc_commodity * cm, gnc_quote_source * src)"},
	 { "gnc_commodity_set_quote_tz", _wrap_gnc_commodity_set_quote_tz, METH_VARARGS, "gnc_commodity_set_quote_tz(gnc_commodity * cm, char const * tz)"},
	 { "gnc_commodity_set_user_symbol", _wrap_gnc_commodity_set_user_symbol, METH_VARARGS, "gnc_commodity_set_user_symbol(gnc_commodity * cm, char const * user_symbol)"},
	 { "gnc_commodity_increment_usage_count", _wrap_gnc_commodity_increment_usage_count, METH_O, "gnc_commodity_increment_usage_count(gnc_commodity * cm)"},
	 { "gnc_commodity_decrement_usage_count", _wrap_gnc_commodity_decrement_usage_count, METH_O, "gnc_commodity_decrement_usage_count(gnc_commodity * cm)"},
	 { "gnc_commodity_equiv", _wrap_gnc_commodity_equiv, METH_VARARGS, "gnc_commodity_equiv(gnc_commodity const * a, gnc_commodity const * b) -> gboolean"},
	 { "gnc_commodity_equal", _wrap_gnc_commodity_equal, METH_VARARGS, "gnc_commodity_equal(gnc_commodity const * a, gnc_commodity const * b) -> gboolean"},
	 { "gnc_commodity_compare", _wrap_gnc_commodity_compare, METH_VARARGS, "gnc_commodity_compare(gnc_commodity const * a, gnc_commodity const * b) -> int"},
	 { "gnc_commodity_compare_void", _wrap_gnc_commodity_compare_void, METH_VARARGS, "gnc_commodity_compare_void(void const * a, void const * b) -> int"},
	 { "gnc_commodity_namespace_is_iso", _wrap_gnc_commodity_namespace_is_iso, METH_O, "gnc_commodity_namespace_is_iso(char const * commodity_namespace) -> gboolean"},
	 { "gnc_commodity_is_iso", _wrap_gnc_commodity_is_iso, METH_O, "gnc_commodity_is_iso(gnc_commodity const * cm) -> gboolean"},
	 { "gnc_commodity_is_currency", _wrap_gnc_commodity_is_currency, METH_O, "gnc_commodity_is_currency(gnc_commodity const * cm) -> gboolean"},
	 { "gnc_commodity_table_get_table", _wrap_gnc_commodity_table_get_table, METH_O, "gnc_commodity_table_get_table(QofBook * book) -> gnc_commodity_table *"},
	 { "gnc_commodity_table_lookup", _wrap_gnc_commodity_table_lookup, METH_VARARGS, "gnc_commodity_table_lookup(gnc_commodity_table const * table, char const * commodity_namespace, char const * mnemonic) -> gnc_commodity *"},
	 { "gnc_commodity_table_lookup_unique", _wrap_gnc_commodity_table_lookup_unique, METH_VARARGS, "gnc_commodity_table_lookup_unique(gnc_commodity_table const * table, char const * unique_name) -> gnc_commodity *"},
	 { "gnc_commodity_table_find_full", _wrap_gnc_commodity_table_find_full, METH_VARARGS, "gnc_commodity_table_find_full(gnc_commodity_table const * t, char const * commodity_namespace, char const * fullname) -> gnc_commodity *"},
	 { "gnc_commodity_find_commodity_by_guid", _wrap_gnc_commodity_find_commodity_by_guid, METH_VARARGS, "gnc_commodity_find_commodity_by_guid(GncGUID guid, QofBook * book) -> gnc_commodity *"},
	 { "gnc_commodity_table_insert", _wrap_gnc_commodity_table_insert, METH_VARARGS, "gnc_commodity_table_insert(gnc_commodity_table * table, gnc_commodity * comm) -> gnc_commodity *"},
	 { "gnc_commodity_table_remove", _wrap_gnc_commodity_table_remove, METH_VARARGS, "gnc_commodity_table_remove(gnc_commodity_table * table, gnc_commodity * comm)"},
	 { "gnc_commodity_table_add_default_data", _wrap_gnc_commodity_table_add_default_data, METH_VARARGS, "gnc_commodity_table_add_default_data(gnc_commodity_table * table, QofBook * book) -> gboolean"},
	 { "gnc_commodity_namespace_get_name", _wrap_gnc_commodity_namespace_get_name, METH_O, "gnc_commodity_namespace_get_name(gnc_commodity_namespace const * ns) -> char const *"},
	 { "gnc_commodity_namespace_get_gui_name", _wrap_gnc_commodity_namespace_get_gui_name, METH_O, "gnc_commodity_namespace_get_gui_name(gnc_commodity_namespace const * ns) -> char const *"},
	 { "gnc_commodity_namespace_get_commodity_list", _wrap_gnc_commodity_namespace_get_commodity_list, METH_O, "gnc_commodity_namespace_get_commodity_list(gnc_commodity_namespace const * ns) -> GList *"},
	 { "gnc_commodity_table_has_namespace", _wrap_gnc_commodity_table_has_namespace, METH_VARARGS, "gnc_commodity_table_has_namespace(gnc_commodity_table const * table, char const * commodity_namespace) -> int"},
	 { "gnc_commodity_table_get_namespaces", _wrap_gnc_commodity_table_get_namespaces, METH_O, "gnc_commodity_table_get_namespaces(gnc_commodity_table const * t) -> GList *"},
	 { "gnc_commodity_table_get_namespaces_list", _wrap_gnc_commodity_table_get_namespaces_list, METH_O, "gnc_commodity_table_get_namespaces_list(gnc_commodity_table const * t) -> GList *"},
	 { "gnc_commodity_table_add_namespace", _wrap_gnc_commodity_table_add_namespace, METH_VARARGS, "gnc_commodity_table_add_namespace(gnc_commodity_table * table, char const * commodity_namespace, QofBook * book) -> gnc_commodity_namespace *"},
	 { "gnc_commodity_table_find_namespace", _wrap_gnc_commodity_table_find_namespace, METH_VARARGS, "gnc_commodity_table_find_namespace(gnc_commodity_table const * table, char const * commodity_namespace) -> gnc_commodity_namespace *"},
	 { "gnc_commodity_table_delete_namespace", _wrap_gnc_commodity_table_delete_namespace, METH_VARARGS, "gnc_commodity_table_delete_namespace(gnc_commodity_table * table, char const * commodity_namespace)"},
	 { "gnc_commodity_table_get_size", _wrap_gnc_commodity_table_get_size, METH_O, "gnc_commodity_table_get_size(gnc_commodity_table const * tbl) -> guint"},
	 { "gnc_commodity_table_get_commodities", _wrap_gnc_commodity_table_get_commodities, METH_VARARGS, "gnc_commodity_table_get_commodities(gnc_commodity_table const * table, char const * commodity_namespace) -> CommodityList *"},
	 { "gnc_commodity_table_get_quotable_commodities", _wrap_gnc_commodity_table_get_quotable_commodities, METH_O, "gnc_commodity_table_get_quotable_commodities(gnc_commodity_table const * table) -> CommodityList *"},
	 { "gnc_commodity_table_foreach_commodity", _wrap_gnc_commodity_table_foreach_commodity, METH_VARARGS, "gnc_commodity_table_foreach_commodity(gnc_commodity_table const * table, gboolean (*)(gnc_commodity *,gpointer) f, gpointer user_data) -> gboolean"},
	 { "gnc_commodity_table_new", _wrap_gnc_commodity_table_new, METH_NOARGS, "gnc_commodity_table_new() -> gnc_commodity_table *"},
	 { "gnc_commodity_table_destroy", _wrap_gnc_commodity_table_destroy, METH_O, "gnc_commodity_table_destroy(gnc_commodity_table * table)"},
	 { "gnc_commodity_obtain_twin", _wrap_gnc_commodity_obtain_twin, METH_VARARGS, "gnc_commodity_obtain_twin(gnc_commodity const * findlike, QofBook * book) -> gnc_commodity *"},
	 { "gnc_commodity_table_register", _wrap_gnc_commodity_table_register, METH_NOARGS, "gnc_commodity_table_register() -> gboolean"},
	 { "gnc_commodity_begin_edit", _wrap_gnc_commodity_begin_edit, METH_O, "gnc_commodity_begin_edit(gnc_commodity * cm)"},
	 { "gnc_commodity_commit_edit", _wrap_gnc_commodity_commit_edit, METH_O, "gnc_commodity_commit_edit(gnc_commodity * cm)"},
	 { "_gnc_monetary_commodity_set", _wrap__gnc_monetary_commodity_set, METH_VARARGS, "_gnc_monetary_commodity_set(_gnc_monetary self, gnc_commodity * commodity)"},
	 { "_gnc_monetary_commodity_get", _wrap__gnc_monetary_commodity_get, METH_O, "_gnc_monetary_commodity_get(_gnc_monetary self) -> gnc_commodity *"},
	 { "_gnc_monetary_value_set", _wrap__gnc_monetary_value_set, METH_VARARGS, "_gnc_monetary_value_set(_gnc_monetary self, _gnc_numeric value)"},
	 { "_gnc_monetary_value_get", _wrap__gnc_monetary_value_get, METH_O, "_gnc_monetary_value_get(_gnc_monetary self) -> _gnc_numeric"},
	 { "new__gnc_monetary", _wrap_new__gnc_monetary, METH_NOARGS, "new__gnc_monetary() -> _gnc_monetary"},
	 { "delete__gnc_monetary", _wrap_delete__gnc_monetary, METH_O, "delete__gnc_monetary(_gnc_monetary self)"},
	 { "_gnc_monetary_swigregister", _gnc_monetary_swigregister, METH_O, NULL},
	 { "_gnc_monetary_swiginit", _gnc_monetary_swiginit, METH_VARARGS, NULL},
	 { "gnc_monetary_create", _wrap_gnc_monetary_create, METH_VARARGS, "gnc_monetary_create(gnc_commodity * commod, _gnc_numeric val) -> _gnc_monetary"},
	 { "gnc_monetary_commodity", _wrap_gnc_monetary_commodity, METH_O, "gnc_monetary_commodity(_gnc_monetary a) -> gnc_commodity *"},
	 { "gnc_monetary_value", _wrap_gnc_monetary_value, METH_O, "gnc_monetary_value(_gnc_monetary a) -> _gnc_numeric"},
	 { "gnc_monetary_list_add_monetary", _wrap_gnc_monetary_list_add_monetary, METH_VARARGS, "gnc_monetary_list_add_monetary(MonetaryList * list, _gnc_monetary mon) -> MonetaryList *"},
	 { "gnc_monetary_list_add_value", _wrap_gnc_monetary_list_add_value, METH_VARARGS, "gnc_monetary_list_add_value(MonetaryList * list, gnc_commodity * commod, _gnc_numeric value) -> MonetaryList *"},
	 { "gnc_monetary_list_delete_zeros", _wrap_gnc_monetary_list_delete_zeros, METH_O, "gnc_monetary_list_delete_zeros(MonetaryList * list) -> MonetaryList *"},
	 { "gnc_monetary_list_free", _wrap_gnc_monetary_list_free, METH_O, "gnc_monetary_list_free(MonetaryList * list)"},
	 { "gncEntryGetGUID", _wrap_gncEntryGetGUID, METH_O, "gncEntryGetGUID(GncEntry * x) -> GncGUID"},
	 { "qofOwnerGetType", _wrap_qofOwnerGetType, METH_O, "qofOwnerGetType(GncOwner const * owner) -> QofIdTypeConst"},
	 { "gncOwnerGetTypeString", _wrap_gncOwnerGetTypeString, METH_O, "gncOwnerGetTypeString(GncOwner const * owner) -> char const *"},
	 { "qofOwnerGetOwner", _wrap_qofOwnerGetOwner, METH_O, "qofOwnerGetOwner(GncOwner const * owner) -> QofInstance *"},
	 { "qofOwnerSetEntity", _wrap_qofOwnerSetEntity, METH_VARARGS, "qofOwnerSetEntity(GncOwner * owner, QofInstance * ent)"},
	 { "GNC_IS_OWNER", _wrap_GNC_IS_OWNER, METH_O, "GNC_IS_OWNER(QofInstance * ent) -> gboolean"},
	 { "gncOwnerTypeToQofIdType", _wrap_gncOwnerTypeToQofIdType, METH_O, "gncOwnerTypeToQofIdType(GncOwnerType t) -> QofIdTypeConst"},
	 { "gncOwnerRegister", _wrap_gncOwnerRegister, METH_NOARGS, "gncOwnerRegister() -> gboolean"},
	 { "gncOwnerInitUndefined", _wrap_gncOwnerInitUndefined, METH_VARARGS, "gncOwnerInitUndefined(GncOwner * owner, gpointer obj)"},
	 { "gncOwnerInitCustomer", _wrap_gncOwnerInitCustomer, METH_VARARGS, "gncOwnerInitCustomer(GncOwner * owner, GncCustomer * customer)"},
	 { "gncOwnerInitJob", _wrap_gncOwnerInitJob, METH_VARARGS, "gncOwnerInitJob(GncOwner * owner, GncJob * job)"},
	 { "gncOwnerInitVendor", _wrap_gncOwnerInitVendor, METH_VARARGS, "gncOwnerInitVendor(GncOwner * owner, GncVendor * vendor)"},
	 { "gncOwnerInitEmployee", _wrap_gncOwnerInitEmployee, METH_VARARGS, "gncOwnerInitEmployee(GncOwner * owner, GncEmployee * employee)"},
	 { "gncOwnerGetType", _wrap_gncOwnerGetType, METH_O, "gncOwnerGetType(GncOwner const * owner) -> GncOwnerType"},
	 { "gncOwnerIsValid", _wrap_gncOwnerIsValid, METH_O, "gncOwnerIsValid(GncOwner const * owner) -> gboolean"},
	 { "gncOwnerGetUndefined", _wrap_gncOwnerGetUndefined, METH_O, "gncOwnerGetUndefined(GncOwner const * owner) -> gpointer"},
	 { "gncOwnerGetCustomer", _wrap_gncOwnerGetCustomer, METH_O, "gncOwnerGetCustomer(GncOwner const * owner) -> GncCustomer *"},
	 { "gncOwnerGetJob", _wrap_gncOwnerGetJob, METH_O, "gncOwnerGetJob(GncOwner const * owner) -> GncJob *"},
	 { "gncOwnerGetVendor", _wrap_gncOwnerGetVendor, METH_O, "gncOwnerGetVendor(GncOwner const * owner) -> GncVendor *"},
	 { "gncOwnerGetEmployee", _wrap_gncOwnerGetEmployee, METH_O, "gncOwnerGetEmployee(GncOwner const * owner) -> GncEmployee *"},
	 { "gncOwnerGetID", _wrap_gncOwnerGetID, METH_O, "gncOwnerGetID(GncOwner const * owner) -> char const *"},
	 { "gncOwnerGetName", _wrap_gncOwnerGetName, METH_O, "gncOwnerGetName(GncOwner const * owner) -> char const *"},
	 { "gncOwnerGetAddr", _wrap_gncOwnerGetAddr, METH_O, "gncOwnerGetAddr(GncOwner const * owner) -> GncAddress *"},
	 { "gncOwnerGetActive", _wrap_gncOwnerGetActive, METH_O, "gncOwnerGetActive(GncOwner const * owner) -> gboolean"},
	 { "gncOwnerGetCurrency", _wrap_gncOwnerGetCurrency, METH_O, "gncOwnerGetCurrency(GncOwner const * owner) -> gnc_commodity *"},
	 { "gncOwnerSetActive", _wrap_gncOwnerSetActive, METH_VARARGS, "gncOwnerSetActive(GncOwner const * owner, gboolean active)"},
	 { "gncOwnerCopy", _wrap_gncOwnerCopy, METH_VARARGS, "gncOwnerCopy(GncOwner const * src, GncOwner * dest)"},
	 { "gncOwnerEqual", _wrap_gncOwnerEqual, METH_VARARGS, "gncOwnerEqual(GncOwner const * a, GncOwner const * b) -> gboolean"},
	 { "gncOwnerGCompareFunc", _wrap_gncOwnerGCompareFunc, METH_VARARGS, "gncOwnerGCompareFunc(GncOwner const * a, GncOwner const * b) -> int"},
	 { "gncOwnerCompare", _wrap_gncOwnerCompare, METH_VARARGS, "gncOwnerCompare(GncOwner const * a, GncOwner const * b) -> int"},
	 { "gncOwnerGetGUID", _wrap_gncOwnerGetGUID, METH_O, "gncOwnerGetGUID(GncOwner const * owner) -> GncGUID"},
	 { "gncOwnerRetGUID", _wrap_gncOwnerRetGUID, METH_O, "gncOwnerRetGUID(GncOwner * owner) -> GncGUID"},
	 { "gncOwnerGetEndOwner", _wrap_gncOwnerGetEndOwner, METH_O, "gncOwnerGetEndOwner(GncOwner const * owner) -> GncOwner const *"},
	 { "gncOwnerGetEndGUID", _wrap_gncOwnerGetEndGUID, METH_O, "gncOwnerGetEndGUID(GncOwner const * owner) -> GncGUID"},
	 { "gncOwnerAttachToLot", _wrap_gncOwnerAttachToLot, METH_VARARGS, "gncOwnerAttachToLot(GncOwner const * owner, GNCLot * lot)"},
	 { "gncOwnerLotMatchOwnerFunc", _wrap_gncOwnerLotMatchOwnerFunc, METH_VARARGS, "gncOwnerLotMatchOwnerFunc(GNCLot * lot, gpointer user_data) -> gboolean"},
	 { "gncOwnerLotsSortFunc", _wrap_gncOwnerLotsSortFunc, METH_VARARGS, "gncOwnerLotsSortFunc(GNCLot * lotA, GNCLot * lotB) -> gint"},
	 { "gncOwnerGetOwnerFromLot", _wrap_gncOwnerGetOwnerFromLot, METH_VARARGS, "gncOwnerGetOwnerFromLot(GNCLot * lot, GncOwner * owner) -> gboolean"},
	 { "gncOwnerGetOwnerFromTxn", _wrap_gncOwnerGetOwnerFromTxn, METH_VARARGS, "gncOwnerGetOwnerFromTxn(Transaction * txn, GncOwner * owner) -> gboolean"},
	 { "gncOwnerGetOwnerFromTypeGuid", _wrap_gncOwnerGetOwnerFromTypeGuid, METH_VARARGS, "gncOwnerGetOwnerFromTypeGuid(QofBook * book, GncOwner * owner, QofIdType type, GncGUID guid) -> gboolean"},
	 { "gncOwnerCreatePaymentLotSecs", _wrap_gncOwnerCreatePaymentLotSecs, METH_VARARGS, "gncOwnerCreatePaymentLotSecs(GncOwner const * owner, Transaction ** preset_txn, Account * posted_acc, Account * xfer_acc, _gnc_numeric amount, _gnc_numeric exch, time64 date, char const * memo, char const * num) -> GNCLot *"},
	 { "gncOwnerAutoApplyPaymentsWithLots", _wrap_gncOwnerAutoApplyPaymentsWithLots, METH_VARARGS, "gncOwnerAutoApplyPaymentsWithLots(GncOwner const * owner, GList * lots)"},
	 { "gncOwnerApplyPaymentSecs", _wrap_gncOwnerApplyPaymentSecs, METH_VARARGS, "gncOwnerApplyPaymentSecs(GncOwner const * owner, Transaction ** preset_txn, GList * lots, Account * posted_acc, Account * xfer_acc, _gnc_numeric amount, _gnc_numeric exch, time64 date, char const * memo, char const * num, gboolean auto_pay)"},
	 { "gncOwnerFindOffsettingSplit", _wrap_gncOwnerFindOffsettingSplit, METH_VARARGS, "gncOwnerFindOffsettingSplit(GNCLot * pay_lot, _gnc_numeric target_value) -> Split *"},
	 { "gncOwnerReduceSplitTo", _wrap_gncOwnerReduceSplitTo, METH_VARARGS, "gncOwnerReduceSplitTo(Split * split, _gnc_numeric target_value) -> gboolean"},
	 { "gncOwnerSetLotLinkMemo", _wrap_gncOwnerSetLotLinkMemo, METH_O, "gncOwnerSetLotLinkMemo(Transaction * ll_txn)"},
	 { "gncOwnerGetAccountTypesList", _wrap_gncOwnerGetAccountTypesList, METH_O, "gncOwnerGetAccountTypesList(GncOwner const * owner) -> GList *"},
	 { "gncOwnerGetCommoditiesList", _wrap_gncOwnerGetCommoditiesList, METH_O, "gncOwnerGetCommoditiesList(GncOwner const * owner) -> GList *"},
	 { "gncOwnerGetBalanceInCurrency", _wrap_gncOwnerGetBalanceInCurrency, METH_VARARGS, "gncOwnerGetBalanceInCurrency(GncOwner const * owner, gnc_commodity const * report_currency) -> _gnc_numeric"},
	 { "gncOwnerNew", _wrap_gncOwnerNew, METH_NOARGS, "gncOwnerNew() -> GncOwner *"},
	 { "gncOwnerFree", _wrap_gncOwnerFree, METH_O, "gncOwnerFree(GncOwner * owner)"},
	 { "gncOwnerBeginEdit", _wrap_gncOwnerBeginEdit, METH_O, "gncOwnerBeginEdit(GncOwner * owner)"},
	 { "gncOwnerCommitEdit", _wrap_gncOwnerCommitEdit, METH_O, "gncOwnerCommitEdit(GncOwner * owner)"},
	 { "gncOwnerDestroy", _wrap_gncOwnerDestroy, METH_O, "gncOwnerDestroy(GncOwner * owner)"},
	 { "gnc_customer_get_type", _wrap_gnc_customer_get_type, METH_NOARGS, "gnc_customer_get_type() -> GType"},
	 { "gncCustomerCreate", _wrap_gncCustomerCreate, METH_O, "gncCustomerCreate(QofBook * book) -> GncCustomer *"},
	 { "gncCustomerDestroy", _wrap_gncCustomerDestroy, METH_O, "gncCustomerDestroy(GncCustomer * customer)"},
	 { "gncCustomerBeginEdit", _wrap_gncCustomerBeginEdit, METH_O, "gncCustomerBeginEdit(GncCustomer * customer)"},
	 { "gncCustomerCommitEdit", _wrap_gncCustomerCommitEdit, METH_O, "gncCustomerCommitEdit(GncCustomer * customer)"},
	 { "gncCustomerSetID", _wrap_gncCustomerSetID, METH_VARARGS, "gncCustomerSetID(GncCustomer * customer, char const * id)"},
	 { "gncCustomerSetName", _wrap_gncCustomerSetName, METH_VARARGS, "gncCustomerSetName(GncCustomer * customer, char const * name)"},
	 { "gncCustomerSetNotes", _wrap_gncCustomerSetNotes, METH_VARARGS, "gncCustomerSetNotes(GncCustomer * customer, char const * notes)"},
	 { "gncCustomerSetTerms", _wrap_gncCustomerSetTerms, METH_VARARGS, "gncCustomerSetTerms(GncCustomer * customer, GncBillTerm * term)"},
	 { "gncCustomerSetTaxIncluded", _wrap_gncCustomerSetTaxIncluded, METH_VARARGS, "gncCustomerSetTaxIncluded(GncCustomer * customer, GncTaxIncluded taxincl)"},
	 { "gncCustomerSetActive", _wrap_gncCustomerSetActive, METH_VARARGS, "gncCustomerSetActive(GncCustomer * customer, gboolean active)"},
	 { "gncCustomerSetDiscount", _wrap_gncCustomerSetDiscount, METH_VARARGS, "gncCustomerSetDiscount(GncCustomer * customer, _gnc_numeric discount)"},
	 { "gncCustomerSetCredit", _wrap_gncCustomerSetCredit, METH_VARARGS, "gncCustomerSetCredit(GncCustomer * customer, _gnc_numeric credit)"},
	 { "gncCustomerSetCurrency", _wrap_gncCustomerSetCurrency, METH_VARARGS, "gncCustomerSetCurrency(GncCustomer * customer, gnc_commodity * currency)"},
	 { "gncCustomerSetTaxTableOverride", _wrap_gncCustomerSetTaxTableOverride, METH_VARARGS, "gncCustomerSetTaxTableOverride(GncCustomer * customer, gboolean override)"},
	 { "gncCustomerSetTaxTable", _wrap_gncCustomerSetTaxTable, METH_VARARGS, "gncCustomerSetTaxTable(GncCustomer * customer, GncTaxTable * table)"},
	 { "gncCustomerAddJob", _wrap_gncCustomerAddJob, METH_VARARGS, "gncCustomerAddJob(GncCustomer * customer, GncJob * job)"},
	 { "gncCustomerRemoveJob", _wrap_gncCustomerRemoveJob, METH_VARARGS, "gncCustomerRemoveJob(GncCustomer * customer, GncJob * job)"},
	 { "gncCustomerLookup", _wrap_gncCustomerLookup, METH_VARARGS, "gncCustomerLookup(QofBook const * book, GncGUID guid) -> GncCustomer *"},
	 { "gncCustomerGetID", _wrap_gncCustomerGetID, METH_O, "gncCustomerGetID(GncCustomer const * customer) -> char const *"},
	 { "gncCustomerGetName", _wrap_gncCustomerGetName, METH_O, "gncCustomerGetName(GncCustomer const * customer) -> char const *"},
	 { "gncCustomerGetAddr", _wrap_gncCustomerGetAddr, METH_O, "gncCustomerGetAddr(GncCustomer const * customer) -> GncAddress *"},
	 { "gncCustomerGetShipAddr", _wrap_gncCustomerGetShipAddr, METH_O, "gncCustomerGetShipAddr(GncCustomer const * customer) -> GncAddress *"},
	 { "gncCustomerGetNotes", _wrap_gncCustomerGetNotes, METH_O, "gncCustomerGetNotes(GncCustomer const * customer) -> char const *"},
	 { "gncCustomerGetTerms", _wrap_gncCustomerGetTerms, METH_O, "gncCustomerGetTerms(GncCustomer const * customer) -> GncBillTerm *"},
	 { "gncCustomerGetTaxIncluded", _wrap_gncCustomerGetTaxIncluded, METH_O, "gncCustomerGetTaxIncluded(GncCustomer const * customer) -> GncTaxIncluded"},
	 { "gncCustomerGetActive", _wrap_gncCustomerGetActive, METH_O, "gncCustomerGetActive(GncCustomer const * customer) -> gboolean"},
	 { "gncCustomerGetDiscount", _wrap_gncCustomerGetDiscount, METH_O, "gncCustomerGetDiscount(GncCustomer const * customer) -> _gnc_numeric"},
	 { "gncCustomerGetCredit", _wrap_gncCustomerGetCredit, METH_O, "gncCustomerGetCredit(GncCustomer const * customer) -> _gnc_numeric"},
	 { "gncCustomerGetCurrency", _wrap_gncCustomerGetCurrency, METH_O, "gncCustomerGetCurrency(GncCustomer const * customer) -> gnc_commodity *"},
	 { "gncCustomerGetTaxTableOverride", _wrap_gncCustomerGetTaxTableOverride, METH_O, "gncCustomerGetTaxTableOverride(GncCustomer const * customer) -> gboolean"},
	 { "gncCustomerGetTaxTable", _wrap_gncCustomerGetTaxTable, METH_O, "gncCustomerGetTaxTable(GncCustomer const * customer) -> GncTaxTable *"},
	 { "gncCustomerCompare", _wrap_gncCustomerCompare, METH_VARARGS, "gncCustomerCompare(GncCustomer const * a, GncCustomer const * b) -> int"},
	 { "gncCustomerEqual", _wrap_gncCustomerEqual, METH_VARARGS, "gncCustomerEqual(GncCustomer const * a, GncCustomer const * b) -> gboolean"},
	 { "gncCustomerGetJoblist", _wrap_gncCustomerGetJoblist, METH_VARARGS, "gncCustomerGetJoblist(GncCustomer const * customer, gboolean show_all) -> GList *"},
	 { "gncCustomerIsDirty", _wrap_gncCustomerIsDirty, METH_O, "gncCustomerIsDirty(GncCustomer * customer) -> gboolean"},
	 { "gncCustomerRegister", _wrap_gncCustomerRegister, METH_NOARGS, "gncCustomerRegister() -> gboolean"},
	 { "gncCustomerNextID", _wrap_gncCustomerNextID, METH_O, "gncCustomerNextID(QofBook * book) -> gchar *"},
	 { "gncCustomerGetCachedBalance", _wrap_gncCustomerGetCachedBalance, METH_O, "gncCustomerGetCachedBalance(GncCustomer * cust) -> _gnc_numeric"},
	 { "gncCustomerSetCachedBalance", _wrap_gncCustomerSetCachedBalance, METH_VARARGS, "gncCustomerSetCachedBalance(GncCustomer * cust, _gnc_numeric new_bal)"},
	 { "gnc_employee_get_type", _wrap_gnc_employee_get_type, METH_NOARGS, "gnc_employee_get_type() -> GType"},
	 { "gncEmployeeCreate", _wrap_gncEmployeeCreate, METH_O, "gncEmployeeCreate(QofBook * book) -> GncEmployee *"},
	 { "gncEmployeeDestroy", _wrap_gncEmployeeDestroy, METH_O, "gncEmployeeDestroy(GncEmployee * employee)"},
	 { "gncEmployeeBeginEdit", _wrap_gncEmployeeBeginEdit, METH_O, "gncEmployeeBeginEdit(GncEmployee * employee)"},
	 { "gncEmployeeCommitEdit", _wrap_gncEmployeeCommitEdit, METH_O, "gncEmployeeCommitEdit(GncEmployee * employee)"},
	 { "gncEmployeeCompare", _wrap_gncEmployeeCompare, METH_VARARGS, "gncEmployeeCompare(GncEmployee const * a, GncEmployee const * b) -> int"},
	 { "gncEmployeeSetID", _wrap_gncEmployeeSetID, METH_VARARGS, "gncEmployeeSetID(GncEmployee * employee, char const * id)"},
	 { "gncEmployeeSetUsername", _wrap_gncEmployeeSetUsername, METH_VARARGS, "gncEmployeeSetUsername(GncEmployee * employee, char const * username)"},
	 { "gncEmployeeSetName", _wrap_gncEmployeeSetName, METH_VARARGS, "gncEmployeeSetName(GncEmployee * employee, char const * name)"},
	 { "gncEmployeeSetLanguage", _wrap_gncEmployeeSetLanguage, METH_VARARGS, "gncEmployeeSetLanguage(GncEmployee * employee, char const * language)"},
	 { "gncEmployeeSetAcl", _wrap_gncEmployeeSetAcl, METH_VARARGS, "gncEmployeeSetAcl(GncEmployee * employee, char const * acl)"},
	 { "gncEmployeeSetWorkday", _wrap_gncEmployeeSetWorkday, METH_VARARGS, "gncEmployeeSetWorkday(GncEmployee * employee, _gnc_numeric workday)"},
	 { "gncEmployeeSetRate", _wrap_gncEmployeeSetRate, METH_VARARGS, "gncEmployeeSetRate(GncEmployee * employee, _gnc_numeric rate)"},
	 { "gncEmployeeSetCurrency", _wrap_gncEmployeeSetCurrency, METH_VARARGS, "gncEmployeeSetCurrency(GncEmployee * employee, gnc_commodity * currency)"},
	 { "gncEmployeeSetActive", _wrap_gncEmployeeSetActive, METH_VARARGS, "gncEmployeeSetActive(GncEmployee * employee, gboolean active)"},
	 { "gncEmployeeSetCCard", _wrap_gncEmployeeSetCCard, METH_VARARGS, "gncEmployeeSetCCard(GncEmployee * employee, Account * ccard_acc)"},
	 { "qofEmployeeSetAddr", _wrap_qofEmployeeSetAddr, METH_VARARGS, "qofEmployeeSetAddr(GncEmployee * employee, QofInstance * addr_ent)"},
	 { "gncEmployeeGetBook", _wrap_gncEmployeeGetBook, METH_O, "gncEmployeeGetBook(GncEmployee * employee) -> QofBook *"},
	 { "gncEmployeeGetID", _wrap_gncEmployeeGetID, METH_O, "gncEmployeeGetID(GncEmployee const * employee) -> char const *"},
	 { "gncEmployeeGetUsername", _wrap_gncEmployeeGetUsername, METH_O, "gncEmployeeGetUsername(GncEmployee const * employee) -> char const *"},
	 { "gncEmployeeGetName", _wrap_gncEmployeeGetName, METH_O, "gncEmployeeGetName(GncEmployee const * employee) -> char const *"},
	 { "gncEmployeeGetAddr", _wrap_gncEmployeeGetAddr, METH_O, "gncEmployeeGetAddr(GncEmployee const * employee) -> GncAddress *"},
	 { "gncEmployeeGetLanguage", _wrap_gncEmployeeGetLanguage, METH_O, "gncEmployeeGetLanguage(GncEmployee const * employee) -> char const *"},
	 { "gncEmployeeGetAcl", _wrap_gncEmployeeGetAcl, METH_O, "gncEmployeeGetAcl(GncEmployee const * employee) -> char const *"},
	 { "gncEmployeeGetWorkday", _wrap_gncEmployeeGetWorkday, METH_O, "gncEmployeeGetWorkday(GncEmployee const * employee) -> _gnc_numeric"},
	 { "gncEmployeeGetRate", _wrap_gncEmployeeGetRate, METH_O, "gncEmployeeGetRate(GncEmployee const * employee) -> _gnc_numeric"},
	 { "gncEmployeeGetCurrency", _wrap_gncEmployeeGetCurrency, METH_O, "gncEmployeeGetCurrency(GncEmployee const * employee) -> gnc_commodity *"},
	 { "gncEmployeeGetActive", _wrap_gncEmployeeGetActive, METH_O, "gncEmployeeGetActive(GncEmployee const * employee) -> gboolean"},
	 { "gncEmployeeGetCCard", _wrap_gncEmployeeGetCCard, METH_O, "gncEmployeeGetCCard(GncEmployee const * employee) -> Account *"},
	 { "gncEmployeeLookup", _wrap_gncEmployeeLookup, METH_VARARGS, "gncEmployeeLookup(QofBook const * book, GncGUID guid) -> GncEmployee *"},
	 { "gncEmployeeEqual", _wrap_gncEmployeeEqual, METH_VARARGS, "gncEmployeeEqual(GncEmployee const * e1, GncEmployee const * e2) -> gboolean"},
	 { "gncEmployeeIsDirty", _wrap_gncEmployeeIsDirty, METH_O, "gncEmployeeIsDirty(GncEmployee const * employee) -> gboolean"},
	 { "gnc_vendor_get_type", _wrap_gnc_vendor_get_type, METH_NOARGS, "gnc_vendor_get_type() -> GType"},
	 { "gncVendorCreate", _wrap_gncVendorCreate, METH_O, "gncVendorCreate(QofBook * book) -> GncVendor *"},
	 { "gncVendorDestroy", _wrap_gncVendorDestroy, METH_O, "gncVendorDestroy(GncVendor * vendor)"},
	 { "gncVendorSetID", _wrap_gncVendorSetID, METH_VARARGS, "gncVendorSetID(GncVendor * vendor, char const * id)"},
	 { "gncVendorSetName", _wrap_gncVendorSetName, METH_VARARGS, "gncVendorSetName(GncVendor * vendor, char const * name)"},
	 { "gncVendorSetNotes", _wrap_gncVendorSetNotes, METH_VARARGS, "gncVendorSetNotes(GncVendor * vendor, char const * notes)"},
	 { "gncVendorSetTerms", _wrap_gncVendorSetTerms, METH_VARARGS, "gncVendorSetTerms(GncVendor * vendor, GncBillTerm * terms)"},
	 { "gncVendorSetTaxIncluded", _wrap_gncVendorSetTaxIncluded, METH_VARARGS, "gncVendorSetTaxIncluded(GncVendor * vendor, GncTaxIncluded taxincl)"},
	 { "gncVendorSetCurrency", _wrap_gncVendorSetCurrency, METH_VARARGS, "gncVendorSetCurrency(GncVendor * vendor, gnc_commodity * currency)"},
	 { "gncVendorSetActive", _wrap_gncVendorSetActive, METH_VARARGS, "gncVendorSetActive(GncVendor * vendor, gboolean active)"},
	 { "gncVendorSetTaxTableOverride", _wrap_gncVendorSetTaxTableOverride, METH_VARARGS, "gncVendorSetTaxTableOverride(GncVendor * vendor, gboolean override)"},
	 { "gncVendorSetTaxTable", _wrap_gncVendorSetTaxTable, METH_VARARGS, "gncVendorSetTaxTable(GncVendor * vendor, GncTaxTable * table)"},
	 { "gncVendorAddJob", _wrap_gncVendorAddJob, METH_VARARGS, "gncVendorAddJob(GncVendor * vendor, GncJob * job)"},
	 { "gncVendorRemoveJob", _wrap_gncVendorRemoveJob, METH_VARARGS, "gncVendorRemoveJob(GncVendor * vendor, GncJob * job)"},
	 { "gncVendorBeginEdit", _wrap_gncVendorBeginEdit, METH_O, "gncVendorBeginEdit(GncVendor * vendor)"},
	 { "gncVendorCommitEdit", _wrap_gncVendorCommitEdit, METH_O, "gncVendorCommitEdit(GncVendor * vendor)"},
	 { "gncVendorGetID", _wrap_gncVendorGetID, METH_O, "gncVendorGetID(GncVendor const * vendor) -> char const *"},
	 { "gncVendorGetName", _wrap_gncVendorGetName, METH_O, "gncVendorGetName(GncVendor const * vendor) -> char const *"},
	 { "gncVendorGetAddr", _wrap_gncVendorGetAddr, METH_O, "gncVendorGetAddr(GncVendor const * vendor) -> GncAddress *"},
	 { "gncVendorGetNotes", _wrap_gncVendorGetNotes, METH_O, "gncVendorGetNotes(GncVendor const * vendor) -> char const *"},
	 { "gncVendorGetTerms", _wrap_gncVendorGetTerms, METH_O, "gncVendorGetTerms(GncVendor const * vendor) -> GncBillTerm *"},
	 { "gncVendorGetTaxIncluded", _wrap_gncVendorGetTaxIncluded, METH_O, "gncVendorGetTaxIncluded(GncVendor const * vendor) -> GncTaxIncluded"},
	 { "gncVendorGetCurrency", _wrap_gncVendorGetCurrency, METH_O, "gncVendorGetCurrency(GncVendor const * vendor) -> gnc_commodity *"},
	 { "gncVendorGetActive", _wrap_gncVendorGetActive, METH_O, "gncVendorGetActive(GncVendor const * vendor) -> gboolean"},
	 { "gncVendorGetTaxTableOverride", _wrap_gncVendorGetTaxTableOverride, METH_O, "gncVendorGetTaxTableOverride(GncVendor const * vendor) -> gboolean"},
	 { "gncVendorGetTaxTable", _wrap_gncVendorGetTaxTable, METH_O, "gncVendorGetTaxTable(GncVendor const * vendor) -> GncTaxTable *"},
	 { "gncVendorCompare", _wrap_gncVendorCompare, METH_VARARGS, "gncVendorCompare(GncVendor const * a, GncVendor const * b) -> int"},
	 { "gncVendorLookup", _wrap_gncVendorLookup, METH_VARARGS, "gncVendorLookup(QofBook const * book, GncGUID guid) -> GncVendor *"},
	 { "gncVendorEqual", _wrap_gncVendorEqual, METH_VARARGS, "gncVendorEqual(GncVendor const * a, GncVendor const * b) -> gboolean"},
	 { "gncVendorIsDirty", _wrap_gncVendorIsDirty, METH_O, "gncVendorIsDirty(GncVendor const * vendor) -> gboolean"},
	 { "gncVendorRegister", _wrap_gncVendorRegister, METH_NOARGS, "gncVendorRegister() -> gboolean"},
	 { "gncVendorNextID", _wrap_gncVendorNextID, METH_O, "gncVendorNextID(QofBook * book) -> gchar *"},
	 { "gncVendorGetCachedBalance", _wrap_gncVendorGetCachedBalance, METH_O, "gncVendorGetCachedBalance(GncVendor * vend) -> _gnc_numeric"},
	 { "gncVendorSetCachedBalance", _wrap_gncVendorSetCachedBalance, METH_VARARGS, "gncVendorSetCachedBalance(GncVendor * vend, _gnc_numeric new_bal)"},
	 { "gnc_address_get_type", _wrap_gnc_address_get_type, METH_NOARGS, "gnc_address_get_type() -> GType"},
	 { "gncAddressCreate", _wrap_gncAddressCreate, METH_VARARGS, "gncAddressCreate(QofBook * book, QofInstance * parent) -> GncAddress *"},
	 { "gncAddressDestroy", _wrap_gncAddressDestroy, METH_O, "gncAddressDestroy(GncAddress * addr)"},
	 { "gncAddressBeginEdit", _wrap_gncAddressBeginEdit, METH_O, "gncAddressBeginEdit(GncAddress * addr)"},
	 { "gncAddressCommitEdit", _wrap_gncAddressCommitEdit, METH_O, "gncAddressCommitEdit(GncAddress * addr)"},
	 { "gncAddressSetName", _wrap_gncAddressSetName, METH_VARARGS, "gncAddressSetName(GncAddress * addr, char const * name)"},
	 { "gncAddressSetAddr1", _wrap_gncAddressSetAddr1, METH_VARARGS, "gncAddressSetAddr1(GncAddress * addr, char const * addr1)"},
	 { "gncAddressSetAddr2", _wrap_gncAddressSetAddr2, METH_VARARGS, "gncAddressSetAddr2(GncAddress * addr, char const * addr2)"},
	 { "gncAddressSetAddr3", _wrap_gncAddressSetAddr3, METH_VARARGS, "gncAddressSetAddr3(GncAddress * addr, char const * addr3)"},
	 { "gncAddressSetAddr4", _wrap_gncAddressSetAddr4, METH_VARARGS, "gncAddressSetAddr4(GncAddress * addr, char const * addr4)"},
	 { "gncAddressSetPhone", _wrap_gncAddressSetPhone, METH_VARARGS, "gncAddressSetPhone(GncAddress * addr, char const * phone)"},
	 { "gncAddressSetFax", _wrap_gncAddressSetFax, METH_VARARGS, "gncAddressSetFax(GncAddress * addr, char const * fax)"},
	 { "gncAddressSetEmail", _wrap_gncAddressSetEmail, METH_VARARGS, "gncAddressSetEmail(GncAddress * addr, char const * email)"},
	 { "gncAddressClearDirty", _wrap_gncAddressClearDirty, METH_O, "gncAddressClearDirty(GncAddress * address)"},
	 { "gncAddressGetName", _wrap_gncAddressGetName, METH_O, "gncAddressGetName(GncAddress const * addr) -> char const *"},
	 { "gncAddressGetAddr1", _wrap_gncAddressGetAddr1, METH_O, "gncAddressGetAddr1(GncAddress const * addr) -> char const *"},
	 { "gncAddressGetAddr2", _wrap_gncAddressGetAddr2, METH_O, "gncAddressGetAddr2(GncAddress const * addr) -> char const *"},
	 { "gncAddressGetAddr3", _wrap_gncAddressGetAddr3, METH_O, "gncAddressGetAddr3(GncAddress const * addr) -> char const *"},
	 { "gncAddressGetAddr4", _wrap_gncAddressGetAddr4, METH_O, "gncAddressGetAddr4(GncAddress const * addr) -> char const *"},
	 { "gncAddressGetPhone", _wrap_gncAddressGetPhone, METH_O, "gncAddressGetPhone(GncAddress const * addr) -> char const *"},
	 { "gncAddressGetFax", _wrap_gncAddressGetFax, METH_O, "gncAddressGetFax(GncAddress const * addr) -> char const *"},
	 { "gncAddressGetEmail", _wrap_gncAddressGetEmail, METH_O, "gncAddressGetEmail(GncAddress const * addr) -> char const *"},
	 { "gncAddressIsDirty", _wrap_gncAddressIsDirty, METH_O, "gncAddressIsDirty(GncAddress const * addr) -> gboolean"},
	 { "gncAddressCompare", _wrap_gncAddressCompare, METH_VARARGS, "gncAddressCompare(GncAddress const * a, GncAddress const * b) -> int"},
	 { "gncAddressEqual", _wrap_gncAddressEqual, METH_VARARGS, "gncAddressEqual(GncAddress const * a, GncAddress const * b) -> gboolean"},
	 { "gnc_billterm_get_type", _wrap_gnc_billterm_get_type, METH_NOARGS, "gnc_billterm_get_type() -> GType"},
	 { "gncBillTermCreate", _wrap_gncBillTermCreate, METH_O, "gncBillTermCreate(QofBook * book) -> GncBillTerm *"},
	 { "gncBillTermDestroy", _wrap_gncBillTermDestroy, METH_O, "gncBillTermDestroy(GncBillTerm * term)"},
	 { "gncBillTermIncRef", _wrap_gncBillTermIncRef, METH_O, "gncBillTermIncRef(GncBillTerm * term)"},
	 { "gncBillTermDecRef", _wrap_gncBillTermDecRef, METH_O, "gncBillTermDecRef(GncBillTerm * term)"},
	 { "gncBillTermChanged", _wrap_gncBillTermChanged, METH_O, "gncBillTermChanged(GncBillTerm * term)"},
	 { "gncBillTermBeginEdit", _wrap_gncBillTermBeginEdit, METH_O, "gncBillTermBeginEdit(GncBillTerm * term)"},
	 { "gncBillTermCommitEdit", _wrap_gncBillTermCommitEdit, METH_O, "gncBillTermCommitEdit(GncBillTerm * term)"},
	 { "gncBillTermSetName", _wrap_gncBillTermSetName, METH_VARARGS, "gncBillTermSetName(GncBillTerm * term, char const * name)"},
	 { "gncBillTermSetDescription", _wrap_gncBillTermSetDescription, METH_VARARGS, "gncBillTermSetDescription(GncBillTerm * term, char const * name)"},
	 { "gncBillTermSetType", _wrap_gncBillTermSetType, METH_VARARGS, "gncBillTermSetType(GncBillTerm * term, GncBillTermType type)"},
	 { "gncBillTermSetDueDays", _wrap_gncBillTermSetDueDays, METH_VARARGS, "gncBillTermSetDueDays(GncBillTerm * term, gint days)"},
	 { "gncBillTermSetDiscountDays", _wrap_gncBillTermSetDiscountDays, METH_VARARGS, "gncBillTermSetDiscountDays(GncBillTerm * term, gint days)"},
	 { "gncBillTermSetDiscount", _wrap_gncBillTermSetDiscount, METH_VARARGS, "gncBillTermSetDiscount(GncBillTerm * term, _gnc_numeric discount)"},
	 { "gncBillTermSetCutoff", _wrap_gncBillTermSetCutoff, METH_VARARGS, "gncBillTermSetCutoff(GncBillTerm * term, gint cutoff)"},
	 { "gncBillTermLookup", _wrap_gncBillTermLookup, METH_VARARGS, "gncBillTermLookup(QofBook const * book, GncGUID guid) -> GncBillTerm *"},
	 { "gncBillTermLookupByName", _wrap_gncBillTermLookupByName, METH_VARARGS, "gncBillTermLookupByName(QofBook * book, char const * name) -> GncBillTerm *"},
	 { "gncBillTermGetTerms", _wrap_gncBillTermGetTerms, METH_O, "gncBillTermGetTerms(QofBook * book) -> GList *"},
	 { "gncBillTermGetName", _wrap_gncBillTermGetName, METH_O, "gncBillTermGetName(GncBillTerm const * term) -> char const *"},
	 { "gncBillTermGetDescription", _wrap_gncBillTermGetDescription, METH_O, "gncBillTermGetDescription(GncBillTerm const * term) -> char const *"},
	 { "gncBillTermGetType", _wrap_gncBillTermGetType, METH_O, "gncBillTermGetType(GncBillTerm const * term) -> GncBillTermType"},
	 { "gncBillTermGetDueDays", _wrap_gncBillTermGetDueDays, METH_O, "gncBillTermGetDueDays(GncBillTerm const * term) -> gint"},
	 { "gncBillTermGetDiscountDays", _wrap_gncBillTermGetDiscountDays, METH_O, "gncBillTermGetDiscountDays(GncBillTerm const * term) -> gint"},
	 { "gncBillTermGetDiscount", _wrap_gncBillTermGetDiscount, METH_O, "gncBillTermGetDiscount(GncBillTerm const * term) -> _gnc_numeric"},
	 { "gncBillTermGetCutoff", _wrap_gncBillTermGetCutoff, METH_O, "gncBillTermGetCutoff(GncBillTerm const * term) -> gint"},
	 { "gncBillTermIsDirty", _wrap_gncBillTermIsDirty, METH_O, "gncBillTermIsDirty(GncBillTerm const * term) -> gboolean"},
	 { "gncBillTermGetParent", _wrap_gncBillTermGetParent, METH_O, "gncBillTermGetParent(GncBillTerm const * term) -> GncBillTerm *"},
	 { "gncBillTermReturnChild", _wrap_gncBillTermReturnChild, METH_VARARGS, "gncBillTermReturnChild(GncBillTerm * term, gboolean make_new) -> GncBillTerm *"},
	 { "gncBillTermGetRefcount", _wrap_gncBillTermGetRefcount, METH_O, "gncBillTermGetRefcount(GncBillTerm const * term) -> gint64"},
	 { "gncBillTermCompare", _wrap_gncBillTermCompare, METH_VARARGS, "gncBillTermCompare(GncBillTerm const * a, GncBillTerm const * b) -> int"},
	 { "gncBillTermEqual", _wrap_gncBillTermEqual, METH_VARARGS, "gncBillTermEqual(GncBillTerm const * a, GncBillTerm const * b) -> gboolean"},
	 { "gncBillTermIsFamily", _wrap_gncBillTermIsFamily, METH_VARARGS, "gncBillTermIsFamily(GncBillTerm const * a, GncBillTerm const * b) -> gboolean"},
	 { "gncBillTermComputeDueDate", _wrap_gncBillTermComputeDueDate, METH_VARARGS, "gncBillTermComputeDueDate(GncBillTerm const * term, time64 post_date) -> time64"},
	 { "gnc_invoice_get_type", _wrap_gnc_invoice_get_type, METH_NOARGS, "gnc_invoice_get_type() -> GType"},
	 { "gncInvoiceCreate", _wrap_gncInvoiceCreate, METH_O, "gncInvoiceCreate(QofBook * book) -> GncInvoice *"},
	 { "gncInvoiceDestroy", _wrap_gncInvoiceDestroy, METH_O, "gncInvoiceDestroy(GncInvoice * invoice)"},
	 { "gncInvoiceCopy", _wrap_gncInvoiceCopy, METH_O, "gncInvoiceCopy(GncInvoice const * other_invoice) -> GncInvoice *"},
	 { "gncInvoiceSetID", _wrap_gncInvoiceSetID, METH_VARARGS, "gncInvoiceSetID(GncInvoice * invoice, char const * id)"},
	 { "gncInvoiceSetOwner", _wrap_gncInvoiceSetOwner, METH_VARARGS, "gncInvoiceSetOwner(GncInvoice * invoice, GncOwner * owner)"},
	 { "gncInvoiceSetDateOpenedGDate", _wrap_gncInvoiceSetDateOpenedGDate, METH_VARARGS, "gncInvoiceSetDateOpenedGDate(GncInvoice * invoice, GDate const * date)"},
	 { "gncInvoiceSetDateOpened", _wrap_gncInvoiceSetDateOpened, METH_VARARGS, "gncInvoiceSetDateOpened(GncInvoice * invoice, time64 date)"},
	 { "gncInvoiceSetDatePosted", _wrap_gncInvoiceSetDatePosted, METH_VARARGS, "gncInvoiceSetDatePosted(GncInvoice * invoice, time64 date)"},
	 { "gncInvoiceSetTerms", _wrap_gncInvoiceSetTerms, METH_VARARGS, "gncInvoiceSetTerms(GncInvoice * invoice, GncBillTerm * terms)"},
	 { "gncInvoiceSetBillingID", _wrap_gncInvoiceSetBillingID, METH_VARARGS, "gncInvoiceSetBillingID(GncInvoice * invoice, char const * billing_id)"},
	 { "gncInvoiceSetNotes", _wrap_gncInvoiceSetNotes, METH_VARARGS, "gncInvoiceSetNotes(GncInvoice * invoice, char const * notes)"},
	 { "gncInvoiceSetCurrency", _wrap_gncInvoiceSetCurrency, METH_VARARGS, "gncInvoiceSetCurrency(GncInvoice * invoice, gnc_commodity * currency)"},
	 { "gncInvoiceSetActive", _wrap_gncInvoiceSetActive, METH_VARARGS, "gncInvoiceSetActive(GncInvoice * invoice, gboolean active)"},
	 { "gncInvoiceSetIsCreditNote", _wrap_gncInvoiceSetIsCreditNote, METH_VARARGS, "gncInvoiceSetIsCreditNote(GncInvoice * invoice, gboolean credit_note)"},
	 { "gncInvoiceSetBillTo", _wrap_gncInvoiceSetBillTo, METH_VARARGS, "gncInvoiceSetBillTo(GncInvoice * invoice, GncOwner * billto)"},
	 { "gncInvoiceSetToChargeAmount", _wrap_gncInvoiceSetToChargeAmount, METH_VARARGS, "gncInvoiceSetToChargeAmount(GncInvoice * invoice, _gnc_numeric amount)"},
	 { "gncInvoiceAddEntry", _wrap_gncInvoiceAddEntry, METH_VARARGS, "gncInvoiceAddEntry(GncInvoice * invoice, GncEntry * entry)"},
	 { "gncInvoiceRemoveEntry", _wrap_gncInvoiceRemoveEntry, METH_VARARGS, "gncInvoiceRemoveEntry(GncInvoice * invoice, GncEntry * entry)"},
	 { "gncInvoiceAddPrice", _wrap_gncInvoiceAddPrice, METH_VARARGS, "gncInvoiceAddPrice(GncInvoice * invoice, GNCPrice * price)"},
	 { "gncBillAddEntry", _wrap_gncBillAddEntry, METH_VARARGS, "gncBillAddEntry(GncInvoice * bill, GncEntry * entry)"},
	 { "gncBillRemoveEntry", _wrap_gncBillRemoveEntry, METH_VARARGS, "gncBillRemoveEntry(GncInvoice * bill, GncEntry * entry)"},
	 { "gncInvoiceSortEntries", _wrap_gncInvoiceSortEntries, METH_O, "gncInvoiceSortEntries(GncInvoice * invoice)"},
	 { "gncInvoiceRemoveEntries", _wrap_gncInvoiceRemoveEntries, METH_O, "gncInvoiceRemoveEntries(GncInvoice * invoice)"},
	 { "gncInvoiceGetID", _wrap_gncInvoiceGetID, METH_O, "gncInvoiceGetID(GncInvoice const * invoice) -> char const *"},
	 { "gncInvoiceGetOwner", _wrap_gncInvoiceGetOwner, METH_O, "gncInvoiceGetOwner(GncInvoice const * invoice) -> GncOwner const *"},
	 { "gncInvoiceGetDateOpened", _wrap_gncInvoiceGetDateOpened, METH_O, "gncInvoiceGetDateOpened(GncInvoice const * invoice) -> time64"},
	 { "gncInvoiceGetDatePosted", _wrap_gncInvoiceGetDatePosted, METH_O, "gncInvoiceGetDatePosted(GncInvoice const * invoice) -> time64"},
	 { "gncInvoiceGetDateDue", _wrap_gncInvoiceGetDateDue, METH_O, "gncInvoiceGetDateDue(GncInvoice const * invoice) -> time64"},
	 { "gncInvoiceGetTerms", _wrap_gncInvoiceGetTerms, METH_O, "gncInvoiceGetTerms(GncInvoice const * invoice) -> GncBillTerm *"},
	 { "gncInvoiceGetBillingID", _wrap_gncInvoiceGetBillingID, METH_O, "gncInvoiceGetBillingID(GncInvoice const * invoice) -> char const *"},
	 { "gncInvoiceGetNotes", _wrap_gncInvoiceGetNotes, METH_O, "gncInvoiceGetNotes(GncInvoice const * invoice) -> char const *"},
	 { "gncInvoiceGetOwnerType", _wrap_gncInvoiceGetOwnerType, METH_O, "gncInvoiceGetOwnerType(GncInvoice const * invoice) -> GncOwnerType"},
	 { "gncInvoiceGetTypeListForOwnerType", _wrap_gncInvoiceGetTypeListForOwnerType, METH_O, "gncInvoiceGetTypeListForOwnerType(GncOwnerType const type) -> GList *"},
	 { "gncInvoiceGetType", _wrap_gncInvoiceGetType, METH_O, "gncInvoiceGetType(GncInvoice const * invoice) -> GncInvoiceType"},
	 { "gncInvoiceGetTypeString", _wrap_gncInvoiceGetTypeString, METH_O, "gncInvoiceGetTypeString(GncInvoice const * invoice) -> char const *"},
	 { "gncInvoiceGetCurrency", _wrap_gncInvoiceGetCurrency, METH_O, "gncInvoiceGetCurrency(GncInvoice const * invoice) -> gnc_commodity *"},
	 { "gncInvoiceGetBillTo", _wrap_gncInvoiceGetBillTo, METH_O, "gncInvoiceGetBillTo(GncInvoice * invoice) -> GncOwner *"},
	 { "gncInvoiceGetToChargeAmount", _wrap_gncInvoiceGetToChargeAmount, METH_O, "gncInvoiceGetToChargeAmount(GncInvoice const * invoice) -> _gnc_numeric"},
	 { "gncInvoiceGetActive", _wrap_gncInvoiceGetActive, METH_O, "gncInvoiceGetActive(GncInvoice const * invoice) -> gboolean"},
	 { "gncInvoiceGetIsCreditNote", _wrap_gncInvoiceGetIsCreditNote, METH_O, "gncInvoiceGetIsCreditNote(GncInvoice const * invoice) -> gboolean"},
	 { "gncInvoiceGetPostedLot", _wrap_gncInvoiceGetPostedLot, METH_O, "gncInvoiceGetPostedLot(GncInvoice const * invoice) -> GNCLot *"},
	 { "gncInvoiceGetPostedTxn", _wrap_gncInvoiceGetPostedTxn, METH_O, "gncInvoiceGetPostedTxn(GncInvoice const * invoice) -> Transaction *"},
	 { "gncInvoiceGetPostedAcc", _wrap_gncInvoiceGetPostedAcc, METH_O, "gncInvoiceGetPostedAcc(GncInvoice const * invoice) -> Account *"},
	 { "gncInvoiceGetTotal", _wrap_gncInvoiceGetTotal, METH_O, "gncInvoiceGetTotal(GncInvoice * invoice) -> _gnc_numeric"},
	 { "gncInvoiceGetTotalOf", _wrap_gncInvoiceGetTotalOf, METH_VARARGS, "gncInvoiceGetTotalOf(GncInvoice * invoice, GncEntryPaymentType type) -> _gnc_numeric"},
	 { "gncInvoiceGetTotalSubtotal", _wrap_gncInvoiceGetTotalSubtotal, METH_O, "gncInvoiceGetTotalSubtotal(GncInvoice * invoice) -> _gnc_numeric"},
	 { "gncInvoiceGetTotalTax", _wrap_gncInvoiceGetTotalTax, METH_O, "gncInvoiceGetTotalTax(GncInvoice * invoice) -> _gnc_numeric"},
	 { "gncInvoiceGetTotalTaxList", _wrap_gncInvoiceGetTotalTaxList, METH_O, "gncInvoiceGetTotalTaxList(GncInvoice * invoice) -> AccountValueList *"},
	 { "gncInvoiceGetEntries", _wrap_gncInvoiceGetEntries, METH_O, "gncInvoiceGetEntries(GncInvoice * invoice) -> EntryList *"},
	 { "gncInvoiceGetPrice", _wrap_gncInvoiceGetPrice, METH_VARARGS, "gncInvoiceGetPrice(GncInvoice * invoice, gnc_commodity * commodity) -> GNCPrice *"},
	 { "gncInvoiceAmountPositive", _wrap_gncInvoiceAmountPositive, METH_O, "gncInvoiceAmountPositive(GncInvoice const * invoice) -> gboolean"},
	 { "gncInvoiceGetForeignCurrencies", _wrap_gncInvoiceGetForeignCurrencies, METH_O, "gncInvoiceGetForeignCurrencies(GncInvoice const * invoice) -> GHashTable *"},
	 { "gncInvoicePostToAccount", _wrap_gncInvoicePostToAccount, METH_VARARGS, "gncInvoicePostToAccount(GncInvoice * invoice, Account * acc, time64 posted_date, time64 due_date, char const * memo, gboolean accumulatesplits, gboolean autopay) -> Transaction *"},
	 { "gncInvoiceUnpost", _wrap_gncInvoiceUnpost, METH_VARARGS, "gncInvoiceUnpost(GncInvoice * invoice, gboolean reset_tax_tables) -> gboolean"},
	 { "gncInvoiceAutoApplyPayments", _wrap_gncInvoiceAutoApplyPayments, METH_O, "gncInvoiceAutoApplyPayments(GncInvoice * invoice)"},
	 { "gncInvoiceApplyPayment", _wrap_gncInvoiceApplyPayment, METH_VARARGS, "gncInvoiceApplyPayment(GncInvoice const * invoice, Transaction * txn, Account * xfer_acc, _gnc_numeric amount, _gnc_numeric exch, time64 date, char const * memo, char const * num)"},
	 { "gncInvoiceGetInvoiceFromTxn", _wrap_gncInvoiceGetInvoiceFromTxn, METH_O, "gncInvoiceGetInvoiceFromTxn(Transaction const * txn) -> GncInvoice *"},
	 { "gncInvoiceGetInvoiceFromLot", _wrap_gncInvoiceGetInvoiceFromLot, METH_O, "gncInvoiceGetInvoiceFromLot(GNCLot * lot) -> GncInvoice *"},
	 { "gncInvoiceLookup", _wrap_gncInvoiceLookup, METH_VARARGS, "gncInvoiceLookup(QofBook const * book, GncGUID guid) -> GncInvoice *"},
	 { "gncInvoiceBeginEdit", _wrap_gncInvoiceBeginEdit, METH_O, "gncInvoiceBeginEdit(GncInvoice * invoice)"},
	 { "gncInvoiceCommitEdit", _wrap_gncInvoiceCommitEdit, METH_O, "gncInvoiceCommitEdit(GncInvoice * invoice)"},
	 { "gncInvoiceCompare", _wrap_gncInvoiceCompare, METH_VARARGS, "gncInvoiceCompare(GncInvoice const * a, GncInvoice const * b) -> int"},
	 { "gncInvoiceIsPosted", _wrap_gncInvoiceIsPosted, METH_O, "gncInvoiceIsPosted(GncInvoice const * invoice) -> gboolean"},
	 { "gncInvoiceIsPaid", _wrap_gncInvoiceIsPaid, METH_O, "gncInvoiceIsPaid(GncInvoice const * invoice) -> gboolean"},
	 { "gncInvoiceGetBook", _wrap_gncInvoiceGetBook, METH_O, "gncInvoiceGetBook(GncInvoice * x) -> QofBook *"},
	 { "gncInvoiceEqual", _wrap_gncInvoiceEqual, METH_VARARGS, "gncInvoiceEqual(GncInvoice const * a, GncInvoice const * b) -> gboolean"},
	 { "gncInvoiceRegister", _wrap_gncInvoiceRegister, METH_NOARGS, "gncInvoiceRegister() -> gboolean"},
	 { "gncInvoiceNextID", _wrap_gncInvoiceNextID, METH_VARARGS, "gncInvoiceNextID(QofBook * book, GncOwner const * owner) -> gchar *"},
	 { "gncInvoiceSetPostedAcc", _wrap_gncInvoiceSetPostedAcc, METH_VARARGS, "gncInvoiceSetPostedAcc(GncInvoice * invoice, Account * acc)"},
	 { "gncInvoiceSetPostedTxn", _wrap_gncInvoiceSetPostedTxn, METH_VARARGS, "gncInvoiceSetPostedTxn(GncInvoice * invoice, Transaction * txn)"},
	 { "gncInvoiceSetPostedLot", _wrap_gncInvoiceSetPostedLot, METH_VARARGS, "gncInvoiceSetPostedLot(GncInvoice * invoice, GNCLot * lot)"},
	 { "gncInvoiceAttachToLot", _wrap_gncInvoiceAttachToLot, METH_VARARGS, "gncInvoiceAttachToLot(GncInvoice * invoice, GNCLot * lot)"},
	 { "gncInvoiceDetachFromLot", _wrap_gncInvoiceDetachFromLot, METH_O, "gncInvoiceDetachFromLot(GNCLot * lot)"},
	 { "gncInvoiceAttachToTxn", _wrap_gncInvoiceAttachToTxn, METH_VARARGS, "gncInvoiceAttachToTxn(GncInvoice * invoice, Transaction * txn)"},
	 { "gnc_job_get_type", _wrap_gnc_job_get_type, METH_NOARGS, "gnc_job_get_type() -> GType"},
	 { "gncJobCreate", _wrap_gncJobCreate, METH_O, "gncJobCreate(QofBook * book) -> GncJob *"},
	 { "gncJobDestroy", _wrap_gncJobDestroy, METH_O, "gncJobDestroy(GncJob * job)"},
	 { "gncJobSetID", _wrap_gncJobSetID, METH_VARARGS, "gncJobSetID(GncJob * job, char const * id)"},
	 { "gncJobSetName", _wrap_gncJobSetName, METH_VARARGS, "gncJobSetName(GncJob * job, char const * jobname)"},
	 { "gncJobSetReference", _wrap_gncJobSetReference, METH_VARARGS, "gncJobSetReference(GncJob * job, char const * owner_reference)"},
	 { "gncJobSetRate", _wrap_gncJobSetRate, METH_VARARGS, "gncJobSetRate(GncJob * job, _gnc_numeric rate)"},
	 { "gncJobSetOwner", _wrap_gncJobSetOwner, METH_VARARGS, "gncJobSetOwner(GncJob * job, GncOwner * owner)"},
	 { "gncJobSetActive", _wrap_gncJobSetActive, METH_VARARGS, "gncJobSetActive(GncJob * job, gboolean active)"},
	 { "gncJobBeginEdit", _wrap_gncJobBeginEdit, METH_O, "gncJobBeginEdit(GncJob * job)"},
	 { "gncJobCommitEdit", _wrap_gncJobCommitEdit, METH_O, "gncJobCommitEdit(GncJob * job)"},
	 { "gncJobGetID", _wrap_gncJobGetID, METH_O, "gncJobGetID(GncJob const * job) -> char const *"},
	 { "gncJobGetName", _wrap_gncJobGetName, METH_O, "gncJobGetName(GncJob const * job) -> char const *"},
	 { "gncJobGetReference", _wrap_gncJobGetReference, METH_O, "gncJobGetReference(GncJob const * job) -> char const *"},
	 { "gncJobGetRate", _wrap_gncJobGetRate, METH_O, "gncJobGetRate(GncJob const * job) -> _gnc_numeric"},
	 { "gncJobGetOwner", _wrap_gncJobGetOwner, METH_O, "gncJobGetOwner(GncJob * job) -> GncOwner *"},
	 { "gncJobGetActive", _wrap_gncJobGetActive, METH_O, "gncJobGetActive(GncJob const * job) -> gboolean"},
	 { "gncJobLookup", _wrap_gncJobLookup, METH_VARARGS, "gncJobLookup(QofBook const * book, GncGUID guid) -> GncJob *"},
	 { "gncJobCompare", _wrap_gncJobCompare, METH_VARARGS, "gncJobCompare(GncJob const * a, GncJob const * b) -> int"},
	 { "gncJobEqual", _wrap_gncJobEqual, METH_VARARGS, "gncJobEqual(GncJob const * a, GncJob const * b) -> gboolean"},
	 { "gnc_entry_get_type", _wrap_gnc_entry_get_type, METH_NOARGS, "gnc_entry_get_type() -> GType"},
	 { "gncEntryDiscountHowToString", _wrap_gncEntryDiscountHowToString, METH_O, "gncEntryDiscountHowToString(GncDiscountHow how) -> char const *"},
	 { "gncEntryDiscountStringToHow", _wrap_gncEntryDiscountStringToHow, METH_VARARGS, "gncEntryDiscountStringToHow(char const * str, GncDiscountHow * how) -> gboolean"},
	 { "gncEntryPaymentTypeToString", _wrap_gncEntryPaymentTypeToString, METH_O, "gncEntryPaymentTypeToString(GncEntryPaymentType type) -> char const *"},
	 { "gncEntryPaymentStringToType", _wrap_gncEntryPaymentStringToType, METH_VARARGS, "gncEntryPaymentStringToType(char const * str, GncEntryPaymentType * type) -> gboolean"},
	 { "gncEntryCreate", _wrap_gncEntryCreate, METH_O, "gncEntryCreate(QofBook * book) -> GncEntry *"},
	 { "gncEntryDestroy", _wrap_gncEntryDestroy, METH_O, "gncEntryDestroy(GncEntry * entry)"},
	 { "gncEntrySetDateGDate", _wrap_gncEntrySetDateGDate, METH_VARARGS, "gncEntrySetDateGDate(GncEntry * entry, GDate const * date)"},
	 { "gncEntrySetDate", _wrap_gncEntrySetDate, METH_VARARGS, "gncEntrySetDate(GncEntry * entry, time64 date)"},
	 { "gncEntrySetDateEntered", _wrap_gncEntrySetDateEntered, METH_VARARGS, "gncEntrySetDateEntered(GncEntry * entry, time64 date)"},
	 { "gncEntrySetDescription", _wrap_gncEntrySetDescription, METH_VARARGS, "gncEntrySetDescription(GncEntry * entry, char const * desc)"},
	 { "gncEntrySetAction", _wrap_gncEntrySetAction, METH_VARARGS, "gncEntrySetAction(GncEntry * entry, char const * action)"},
	 { "gncEntrySetNotes", _wrap_gncEntrySetNotes, METH_VARARGS, "gncEntrySetNotes(GncEntry * entry, char const * notes)"},
	 { "gncEntrySetQuantity", _wrap_gncEntrySetQuantity, METH_VARARGS, "gncEntrySetQuantity(GncEntry * entry, _gnc_numeric quantity)"},
	 { "gncEntrySetDocQuantity", _wrap_gncEntrySetDocQuantity, METH_VARARGS, "gncEntrySetDocQuantity(GncEntry * entry, _gnc_numeric quantity, gboolean is_cn)"},
	 { "gncEntrySetInvAccount", _wrap_gncEntrySetInvAccount, METH_VARARGS, "gncEntrySetInvAccount(GncEntry * entry, Account * acc)"},
	 { "gncEntrySetInvPrice", _wrap_gncEntrySetInvPrice, METH_VARARGS, "gncEntrySetInvPrice(GncEntry * entry, _gnc_numeric price)"},
	 { "gncEntrySetInvTaxable", _wrap_gncEntrySetInvTaxable, METH_VARARGS, "gncEntrySetInvTaxable(GncEntry * entry, gboolean taxable)"},
	 { "gncEntrySetInvTaxIncluded", _wrap_gncEntrySetInvTaxIncluded, METH_VARARGS, "gncEntrySetInvTaxIncluded(GncEntry * entry, gboolean tax_included)"},
	 { "gncEntrySetInvTaxTable", _wrap_gncEntrySetInvTaxTable, METH_VARARGS, "gncEntrySetInvTaxTable(GncEntry * entry, GncTaxTable * table)"},
	 { "gncEntrySetInvDiscount", _wrap_gncEntrySetInvDiscount, METH_VARARGS, "gncEntrySetInvDiscount(GncEntry * entry, _gnc_numeric discount)"},
	 { "gncEntrySetInvDiscountType", _wrap_gncEntrySetInvDiscountType, METH_VARARGS, "gncEntrySetInvDiscountType(GncEntry * entry, GncAmountType type)"},
	 { "gncEntrySetInvDiscountHow", _wrap_gncEntrySetInvDiscountHow, METH_VARARGS, "gncEntrySetInvDiscountHow(GncEntry * entry, GncDiscountHow how)"},
	 { "qofEntrySetInvDiscType", _wrap_qofEntrySetInvDiscType, METH_VARARGS, "qofEntrySetInvDiscType(GncEntry * entry, char const * type)"},
	 { "qofEntrySetInvDiscHow", _wrap_qofEntrySetInvDiscHow, METH_VARARGS, "qofEntrySetInvDiscHow(GncEntry * entry, char const * type)"},
	 { "gncEntrySetBillAccount", _wrap_gncEntrySetBillAccount, METH_VARARGS, "gncEntrySetBillAccount(GncEntry * entry, Account * acc)"},
	 { "gncEntrySetBillPrice", _wrap_gncEntrySetBillPrice, METH_VARARGS, "gncEntrySetBillPrice(GncEntry * entry, _gnc_numeric price)"},
	 { "gncEntrySetBillTaxable", _wrap_gncEntrySetBillTaxable, METH_VARARGS, "gncEntrySetBillTaxable(GncEntry * entry, gboolean taxable)"},
	 { "gncEntrySetBillTaxIncluded", _wrap_gncEntrySetBillTaxIncluded, METH_VARARGS, "gncEntrySetBillTaxIncluded(GncEntry * entry, gboolean tax_included)"},
	 { "gncEntrySetBillTaxTable", _wrap_gncEntrySetBillTaxTable, METH_VARARGS, "gncEntrySetBillTaxTable(GncEntry * entry, GncTaxTable * table)"},
	 { "gncEntrySetBillable", _wrap_gncEntrySetBillable, METH_VARARGS, "gncEntrySetBillable(GncEntry * entry, gboolean billable)"},
	 { "gncEntrySetBillTo", _wrap_gncEntrySetBillTo, METH_VARARGS, "gncEntrySetBillTo(GncEntry * entry, GncOwner * billto)"},
	 { "gncEntrySetBillPayment", _wrap_gncEntrySetBillPayment, METH_VARARGS, "gncEntrySetBillPayment(GncEntry * entry, GncEntryPaymentType type)"},
	 { "gncEntryGetDateGDate", _wrap_gncEntryGetDateGDate, METH_O, "gncEntryGetDateGDate(GncEntry const * entry) -> GDate"},
	 { "gncEntryGetDate", _wrap_gncEntryGetDate, METH_O, "gncEntryGetDate(GncEntry const * entry) -> time64"},
	 { "gncEntryGetDateEntered", _wrap_gncEntryGetDateEntered, METH_O, "gncEntryGetDateEntered(GncEntry const * entry) -> time64"},
	 { "gncEntryGetDescription", _wrap_gncEntryGetDescription, METH_O, "gncEntryGetDescription(GncEntry const * entry) -> char const *"},
	 { "gncEntryGetAction", _wrap_gncEntryGetAction, METH_O, "gncEntryGetAction(GncEntry const * entry) -> char const *"},
	 { "gncEntryGetNotes", _wrap_gncEntryGetNotes, METH_O, "gncEntryGetNotes(GncEntry const * notes) -> char const *"},
	 { "gncEntryGetQuantity", _wrap_gncEntryGetQuantity, METH_O, "gncEntryGetQuantity(GncEntry const * entry) -> _gnc_numeric"},
	 { "gncEntryGetDocQuantity", _wrap_gncEntryGetDocQuantity, METH_VARARGS, "gncEntryGetDocQuantity(GncEntry const * entry, gboolean is_cn) -> _gnc_numeric"},
	 { "gncEntryGetInvAccount", _wrap_gncEntryGetInvAccount, METH_O, "gncEntryGetInvAccount(GncEntry const * entry) -> Account *"},
	 { "gncEntryGetInvPrice", _wrap_gncEntryGetInvPrice, METH_O, "gncEntryGetInvPrice(GncEntry const * entry) -> _gnc_numeric"},
	 { "gncEntryGetPrice", _wrap_gncEntryGetPrice, METH_VARARGS, "gncEntryGetPrice(GncEntry const * entry, gboolean const cust_doc, gboolean const net) -> _gnc_numeric"},
	 { "gncEntryGetInvDiscount", _wrap_gncEntryGetInvDiscount, METH_O, "gncEntryGetInvDiscount(GncEntry const * entry) -> _gnc_numeric"},
	 { "gncEntryGetInvDiscountType", _wrap_gncEntryGetInvDiscountType, METH_O, "gncEntryGetInvDiscountType(GncEntry const * entry) -> GncAmountType"},
	 { "gncEntryGetInvDiscountHow", _wrap_gncEntryGetInvDiscountHow, METH_O, "gncEntryGetInvDiscountHow(GncEntry const * entry) -> GncDiscountHow"},
	 { "qofEntryGetInvDiscType", _wrap_qofEntryGetInvDiscType, METH_O, "qofEntryGetInvDiscType(GncEntry const * entry) -> char *"},
	 { "qofEntryGetInvDiscHow", _wrap_qofEntryGetInvDiscHow, METH_O, "qofEntryGetInvDiscHow(GncEntry const * entry) -> char *"},
	 { "gncEntryGetInvTaxable", _wrap_gncEntryGetInvTaxable, METH_O, "gncEntryGetInvTaxable(GncEntry const * entry) -> gboolean"},
	 { "gncEntryGetInvTaxIncluded", _wrap_gncEntryGetInvTaxIncluded, METH_O, "gncEntryGetInvTaxIncluded(GncEntry const * entry) -> gboolean"},
	 { "gncEntryGetInvTaxTable", _wrap_gncEntryGetInvTaxTable, METH_O, "gncEntryGetInvTaxTable(GncEntry const * entry) -> GncTaxTable *"},
	 { "gncEntryGetBillAccount", _wrap_gncEntryGetBillAccount, METH_O, "gncEntryGetBillAccount(GncEntry const * entry) -> Account *"},
	 { "gncEntryGetBillPrice", _wrap_gncEntryGetBillPrice, METH_O, "gncEntryGetBillPrice(GncEntry const * entry) -> _gnc_numeric"},
	 { "gncEntryGetBillTaxable", _wrap_gncEntryGetBillTaxable, METH_O, "gncEntryGetBillTaxable(GncEntry const * entry) -> gboolean"},
	 { "gncEntryGetBillTaxIncluded", _wrap_gncEntryGetBillTaxIncluded, METH_O, "gncEntryGetBillTaxIncluded(GncEntry const * entry) -> gboolean"},
	 { "gncEntryGetBillTaxTable", _wrap_gncEntryGetBillTaxTable, METH_O, "gncEntryGetBillTaxTable(GncEntry const * entry) -> GncTaxTable *"},
	 { "gncEntryGetBillable", _wrap_gncEntryGetBillable, METH_O, "gncEntryGetBillable(GncEntry const * entry) -> gboolean"},
	 { "gncEntryGetBillTo", _wrap_gncEntryGetBillTo, METH_O, "gncEntryGetBillTo(GncEntry * entry) -> GncOwner *"},
	 { "gncEntryGetBillPayment", _wrap_gncEntryGetBillPayment, METH_O, "gncEntryGetBillPayment(GncEntry const * entry) -> GncEntryPaymentType"},
	 { "gncEntryCopy", _wrap_gncEntryCopy, METH_VARARGS, "gncEntryCopy(GncEntry const * src, GncEntry * dest, gboolean add_entry)"},
	 { "gncEntryGetDocValue", _wrap_gncEntryGetDocValue, METH_VARARGS, "gncEntryGetDocValue(GncEntry * entry, gboolean round, gboolean is_cust_doc, gboolean is_cn) -> _gnc_numeric"},
	 { "gncEntryGetDocTaxValue", _wrap_gncEntryGetDocTaxValue, METH_VARARGS, "gncEntryGetDocTaxValue(GncEntry * entry, gboolean round, gboolean is_cust_doc, gboolean is_cn) -> _gnc_numeric"},
	 { "gncEntryGetDocTaxValues", _wrap_gncEntryGetDocTaxValues, METH_VARARGS, "gncEntryGetDocTaxValues(GncEntry * entry, gboolean is_cust_doc, gboolean is_cn) -> AccountValueList *"},
	 { "gncEntryGetDocDiscountValue", _wrap_gncEntryGetDocDiscountValue, METH_VARARGS, "gncEntryGetDocDiscountValue(GncEntry * entry, gboolean round, gboolean is_cust_doc, gboolean is_cn) -> _gnc_numeric"},
	 { "gncEntryGetBalValue", _wrap_gncEntryGetBalValue, METH_VARARGS, "gncEntryGetBalValue(GncEntry * entry, gboolean round, gboolean is_cust_doc) -> _gnc_numeric"},
	 { "gncEntryGetBalTaxValue", _wrap_gncEntryGetBalTaxValue, METH_VARARGS, "gncEntryGetBalTaxValue(GncEntry * entry, gboolean round, gboolean is_cust_doc) -> _gnc_numeric"},
	 { "gncEntryGetBalTaxValues", _wrap_gncEntryGetBalTaxValues, METH_VARARGS, "gncEntryGetBalTaxValues(GncEntry * entry, gboolean is_cust_doc) -> AccountValueList *"},
	 { "gncEntryGetBalDiscountValue", _wrap_gncEntryGetBalDiscountValue, METH_VARARGS, "gncEntryGetBalDiscountValue(GncEntry * entry, gboolean round, gboolean is_cust_doc) -> _gnc_numeric"},
	 { "gncEntryComputeValue", _wrap_gncEntryComputeValue, METH_VARARGS, "gncEntryComputeValue(_gnc_numeric qty, _gnc_numeric price, GncTaxTable const * tax_table, gboolean tax_included, _gnc_numeric discount, GncAmountType discount_type, GncDiscountHow discount_how, int SCU, _gnc_numeric value, _gnc_numeric discount_value, GList ** tax_values)"},
	 { "gncEntryGetOrder", _wrap_gncEntryGetOrder, METH_O, "gncEntryGetOrder(GncEntry const * entry) -> GncOrder *"},
	 { "gncEntryGetInvoice", _wrap_gncEntryGetInvoice, METH_O, "gncEntryGetInvoice(GncEntry const * entry) -> GncInvoice *"},
	 { "gncEntryGetBill", _wrap_gncEntryGetBill, METH_O, "gncEntryGetBill(GncEntry const * entry) -> GncInvoice *"},
	 { "gncEntryLookup", _wrap_gncEntryLookup, METH_VARARGS, "gncEntryLookup(QofBook const * book, GncGUID guid) -> GncEntry *"},
	 { "gncEntryIsOpen", _wrap_gncEntryIsOpen, METH_O, "gncEntryIsOpen(GncEntry const * entry) -> gboolean"},
	 { "gncEntryBeginEdit", _wrap_gncEntryBeginEdit, METH_O, "gncEntryBeginEdit(GncEntry * entry)"},
	 { "gncEntryCommitEdit", _wrap_gncEntryCommitEdit, METH_O, "gncEntryCommitEdit(GncEntry * entry)"},
	 { "gncEntryCompare", _wrap_gncEntryCompare, METH_VARARGS, "gncEntryCompare(GncEntry const * a, GncEntry const * b) -> int"},
	 { "gnc_taxtable_get_type", _wrap_gnc_taxtable_get_type, METH_NOARGS, "gnc_taxtable_get_type() -> GType"},
	 { "gncAmountTypeToString", _wrap_gncAmountTypeToString, METH_O, "gncAmountTypeToString(GncAmountType type) -> char const *"},
	 { "gncAmountStringToType", _wrap_gncAmountStringToType, METH_VARARGS, "gncAmountStringToType(char const * str, GncAmountType * type) -> gboolean"},
	 { "gncTaxIncludedTypeToString", _wrap_gncTaxIncludedTypeToString, METH_O, "gncTaxIncludedTypeToString(GncTaxIncluded type) -> char const *"},
	 { "gncTaxIncludedStringToType", _wrap_gncTaxIncludedStringToType, METH_VARARGS, "gncTaxIncludedStringToType(char const * str, GncTaxIncluded * type) -> gboolean"},
	 { "gncTaxTableCreate", _wrap_gncTaxTableCreate, METH_O, "gncTaxTableCreate(QofBook * book) -> GncTaxTable *"},
	 { "gncTaxTableDestroy", _wrap_gncTaxTableDestroy, METH_O, "gncTaxTableDestroy(GncTaxTable * table)"},
	 { "gncTaxTableEntryCreate", _wrap_gncTaxTableEntryCreate, METH_NOARGS, "gncTaxTableEntryCreate() -> GncTaxTableEntry *"},
	 { "gncTaxTableEntryDestroy", _wrap_gncTaxTableEntryDestroy, METH_O, "gncTaxTableEntryDestroy(GncTaxTableEntry * entry)"},
	 { "gncTaxTableSetName", _wrap_gncTaxTableSetName, METH_VARARGS, "gncTaxTableSetName(GncTaxTable * table, char const * name)"},
	 { "gncTaxTableIncRef", _wrap_gncTaxTableIncRef, METH_O, "gncTaxTableIncRef(GncTaxTable * table)"},
	 { "gncTaxTableDecRef", _wrap_gncTaxTableDecRef, METH_O, "gncTaxTableDecRef(GncTaxTable * table)"},
	 { "gncTaxTableEntrySetAccount", _wrap_gncTaxTableEntrySetAccount, METH_VARARGS, "gncTaxTableEntrySetAccount(GncTaxTableEntry * entry, Account * account)"},
	 { "gncTaxTableEntrySetType", _wrap_gncTaxTableEntrySetType, METH_VARARGS, "gncTaxTableEntrySetType(GncTaxTableEntry * entry, GncAmountType type)"},
	 { "gncTaxTableEntrySetAmount", _wrap_gncTaxTableEntrySetAmount, METH_VARARGS, "gncTaxTableEntrySetAmount(GncTaxTableEntry * entry, _gnc_numeric amount)"},
	 { "gncTaxTableAddEntry", _wrap_gncTaxTableAddEntry, METH_VARARGS, "gncTaxTableAddEntry(GncTaxTable * table, GncTaxTableEntry * entry)"},
	 { "gncTaxTableRemoveEntry", _wrap_gncTaxTableRemoveEntry, METH_VARARGS, "gncTaxTableRemoveEntry(GncTaxTable * table, GncTaxTableEntry * entry)"},
	 { "gncTaxTableChanged", _wrap_gncTaxTableChanged, METH_O, "gncTaxTableChanged(GncTaxTable * table)"},
	 { "gncTaxTableBeginEdit", _wrap_gncTaxTableBeginEdit, METH_O, "gncTaxTableBeginEdit(GncTaxTable * table)"},
	 { "gncTaxTableCommitEdit", _wrap_gncTaxTableCommitEdit, METH_O, "gncTaxTableCommitEdit(GncTaxTable * table)"},
	 { "gncTaxTableEqual", _wrap_gncTaxTableEqual, METH_VARARGS, "gncTaxTableEqual(GncTaxTable const * a, GncTaxTable const * b) -> gboolean"},
	 { "gncTaxTableLookup", _wrap_gncTaxTableLookup, METH_VARARGS, "gncTaxTableLookup(QofBook const * book, GncGUID guid) -> GncTaxTable *"},
	 { "gncTaxTableLookupByName", _wrap_gncTaxTableLookupByName, METH_VARARGS, "gncTaxTableLookupByName(QofBook * book, char const * name) -> GncTaxTable *"},
	 { "gncTaxTableGetDefault", _wrap_gncTaxTableGetDefault, METH_VARARGS, "gncTaxTableGetDefault(QofBook * book, GncOwnerType type) -> GncTaxTable *"},
	 { "gncTaxTableGetTables", _wrap_gncTaxTableGetTables, METH_O, "gncTaxTableGetTables(QofBook * book) -> GncTaxTableList *"},
	 { "gncTaxTableGetName", _wrap_gncTaxTableGetName, METH_O, "gncTaxTableGetName(GncTaxTable const * table) -> char const *"},
	 { "gncTaxTableGetParent", _wrap_gncTaxTableGetParent, METH_O, "gncTaxTableGetParent(GncTaxTable const * table) -> GncTaxTable *"},
	 { "gncTaxTableReturnChild", _wrap_gncTaxTableReturnChild, METH_VARARGS, "gncTaxTableReturnChild(GncTaxTable * table, gboolean make_new) -> GncTaxTable *"},
	 { "gncTaxTableGetEntries", _wrap_gncTaxTableGetEntries, METH_O, "gncTaxTableGetEntries(GncTaxTable const * table) -> GncTaxTableEntryList *"},
	 { "gncTaxTableGetRefcount", _wrap_gncTaxTableGetRefcount, METH_O, "gncTaxTableGetRefcount(GncTaxTable const * table) -> gint64"},
	 { "gncTaxTableLastModifiedSecs", _wrap_gncTaxTableLastModifiedSecs, METH_O, "gncTaxTableLastModifiedSecs(GncTaxTable const * table) -> time64"},
	 { "gncTaxTableEntryGetAccount", _wrap_gncTaxTableEntryGetAccount, METH_O, "gncTaxTableEntryGetAccount(GncTaxTableEntry const * entry) -> Account *"},
	 { "gncTaxTableEntryGetType", _wrap_gncTaxTableEntryGetType, METH_O, "gncTaxTableEntryGetType(GncTaxTableEntry const * entry) -> GncAmountType"},
	 { "gncTaxTableEntryGetAmount", _wrap_gncTaxTableEntryGetAmount, METH_O, "gncTaxTableEntryGetAmount(GncTaxTableEntry const * entry) -> _gnc_numeric"},
	 { "gncTaxTableCompare", _wrap_gncTaxTableCompare, METH_VARARGS, "gncTaxTableCompare(GncTaxTable const * a, GncTaxTable const * b) -> int"},
	 { "gncTaxTableEntryCompare", _wrap_gncTaxTableEntryCompare, METH_VARARGS, "gncTaxTableEntryCompare(GncTaxTableEntry const * a, GncTaxTableEntry const * b) -> int"},
	 { "gncTaxTableEntryEqual", _wrap_gncTaxTableEntryEqual, METH_VARARGS, "gncTaxTableEntryEqual(GncTaxTableEntry const * a, GncTaxTableEntry const * b) -> gboolean"},
	 { "_gncAccountValue_account_set", _wrap__gncAccountValue_account_set, METH_VARARGS, "_gncAccountValue_account_set(_gncAccountValue self, Account * account)"},
	 { "_gncAccountValue_account_get", _wrap__gncAccountValue_account_get, METH_O, "_gncAccountValue_account_get(_gncAccountValue self) -> Account *"},
	 { "_gncAccountValue_value_set", _wrap__gncAccountValue_value_set, METH_VARARGS, "_gncAccountValue_value_set(_gncAccountValue self, _gnc_numeric value)"},
	 { "_gncAccountValue_value_get", _wrap__gncAccountValue_value_get, METH_O, "_gncAccountValue_value_get(_gncAccountValue self) -> _gnc_numeric"},
	 { "new__gncAccountValue", _wrap_new__gncAccountValue, METH_NOARGS, "new__gncAccountValue() -> _gncAccountValue"},
	 { "delete__gncAccountValue", _wrap_delete__gncAccountValue, METH_O, "delete__gncAccountValue(_gncAccountValue self)"},
	 { "_gncAccountValue_swigregister", _gncAccountValue_swigregister, METH_O, NULL},
	 { "_gncAccountValue_swiginit", _gncAccountValue_swiginit, METH_VARARGS, NULL},
	 { "gncAccountValueAdd", _wrap_gncAccountValueAdd, METH_VARARGS, "gncAccountValueAdd(GList * list, Account * acc, _gnc_numeric value) -> GList *"},
	 { "gncAccountValueAddList", _wrap_gncAccountValueAddList, METH_VARARGS, "gncAccountValueAddList(GList * l1, GList * l2) -> GList *"},
	 { "gncAccountValueTotal", _wrap_gncAccountValueTotal, METH_O, "gncAccountValueTotal(GList * list) -> _gnc_numeric"},
	 { "gncAccountValueDestroy", _wrap_gncAccountValueDestroy, METH_O, "gncAccountValueDestroy(GList * list)"},
	 { "gnc_search_customer_on_id", _wrap_gnc_search_customer_on_id, METH_VARARGS, "gnc_search_customer_on_id(QofBook * book, gchar const * id) -> GncCustomer *"},
	 { "gnc_search_invoice_on_id", _wrap_gnc_search_invoice_on_id, METH_VARARGS, "gnc_search_invoice_on_id(QofBook * book, gchar const * id) -> GncInvoice *"},
	 { "gnc_search_bill_on_id", _wrap_gnc_search_bill_on_id, METH_VARARGS, "gnc_search_bill_on_id(QofBook * book, gchar const * id) -> GncInvoice *"},
	 { "gnc_search_vendor_on_id", _wrap_gnc_search_vendor_on_id, METH_VARARGS, "gnc_search_vendor_on_id(QofBook * book, gchar const * id) -> GncVendor *"},
	 { "gnc_price_get_type", _wrap_gnc_price_get_type, METH_NOARGS, "gnc_price_get_type() -> GType"},
	 { "gnc_pricedb_get_type", _wrap_gnc_pricedb_get_type, METH_NOARGS, "gnc_pricedb_get_type() -> GType"},
	 { "gnc_price_create", _wrap_gnc_price_create, METH_O, "gnc_price_create(QofBook * book) -> GNCPrice *"},
	 { "gnc_price_clone", _wrap_gnc_price_clone, METH_VARARGS, "gnc_price_clone(GNCPrice * p, QofBook * book) -> GNCPrice *"},
	 { "gnc_price_invert", _wrap_gnc_price_invert, METH_O, "gnc_price_invert(GNCPrice * p) -> GNCPrice *"},
	 { "gnc_price_ref", _wrap_gnc_price_ref, METH_O, "gnc_price_ref(GNCPrice * p)"},
	 { "gnc_price_unref", _wrap_gnc_price_unref, METH_O, "gnc_price_unref(GNCPrice * p)"},
	 { "gnc_price_begin_edit", _wrap_gnc_price_begin_edit, METH_O, "gnc_price_begin_edit(GNCPrice * p)"},
	 { "gnc_price_commit_edit", _wrap_gnc_price_commit_edit, METH_O, "gnc_price_commit_edit(GNCPrice * p)"},
	 { "gnc_price_set_commodity", _wrap_gnc_price_set_commodity, METH_VARARGS, "gnc_price_set_commodity(GNCPrice * p, gnc_commodity * c)"},
	 { "gnc_price_set_currency", _wrap_gnc_price_set_currency, METH_VARARGS, "gnc_price_set_currency(GNCPrice * p, gnc_commodity * c)"},
	 { "gnc_price_set_time64", _wrap_gnc_price_set_time64, METH_VARARGS, "gnc_price_set_time64(GNCPrice * p, time64 t)"},
	 { "gnc_price_set_source", _wrap_gnc_price_set_source, METH_VARARGS, "gnc_price_set_source(GNCPrice * p, PriceSource source)"},
	 { "gnc_price_set_source_string", _wrap_gnc_price_set_source_string, METH_VARARGS, "gnc_price_set_source_string(GNCPrice * p, char const * s)"},
	 { "gnc_price_set_typestr", _wrap_gnc_price_set_typestr, METH_VARARGS, "gnc_price_set_typestr(GNCPrice * p, char const * type)"},
	 { "gnc_price_set_value", _wrap_gnc_price_set_value, METH_VARARGS, "gnc_price_set_value(GNCPrice * p, _gnc_numeric value)"},
	 { "gnc_price_lookup", _wrap_gnc_price_lookup, METH_VARARGS, "gnc_price_lookup(GncGUID guid, QofBook * book) -> GNCPrice *"},
	 { "gnc_price_get_commodity", _wrap_gnc_price_get_commodity, METH_O, "gnc_price_get_commodity(GNCPrice const * p) -> gnc_commodity *"},
	 { "gnc_price_get_currency", _wrap_gnc_price_get_currency, METH_O, "gnc_price_get_currency(GNCPrice const * p) -> gnc_commodity *"},
	 { "gnc_price_get_time64", _wrap_gnc_price_get_time64, METH_O, "gnc_price_get_time64(GNCPrice const * p) -> time64"},
	 { "gnc_price_get_source", _wrap_gnc_price_get_source, METH_O, "gnc_price_get_source(GNCPrice const * p) -> PriceSource"},
	 { "gnc_price_get_source_string", _wrap_gnc_price_get_source_string, METH_O, "gnc_price_get_source_string(GNCPrice const * p) -> char const *"},
	 { "gnc_price_get_typestr", _wrap_gnc_price_get_typestr, METH_O, "gnc_price_get_typestr(GNCPrice const * p) -> char const *"},
	 { "gnc_price_get_value", _wrap_gnc_price_get_value, METH_O, "gnc_price_get_value(GNCPrice const * p) -> _gnc_numeric"},
	 { "gnc_price_equal", _wrap_gnc_price_equal, METH_VARARGS, "gnc_price_equal(GNCPrice const * p1, GNCPrice const * p2) -> gboolean"},
	 { "gnc_price_print", _wrap_gnc_price_print, METH_VARARGS, "gnc_price_print(GNCPrice * db, FILE * f, int indent)"},
	 { "gnc_price_list_insert", _wrap_gnc_price_list_insert, METH_VARARGS, "gnc_price_list_insert(PriceList ** prices, GNCPrice * p, gboolean check_dupl) -> gboolean"},
	 { "gnc_price_list_remove", _wrap_gnc_price_list_remove, METH_VARARGS, "gnc_price_list_remove(PriceList ** prices, GNCPrice * p) -> gboolean"},
	 { "gnc_price_list_destroy", _wrap_gnc_price_list_destroy, METH_O, "gnc_price_list_destroy(PriceList * prices)"},
	 { "gnc_price_list_equal", _wrap_gnc_price_list_equal, METH_VARARGS, "gnc_price_list_equal(PriceList * prices1, PriceList * prices2) -> gboolean"},
	 { "gnc_pricedb_get_db", _wrap_gnc_pricedb_get_db, METH_O, "gnc_pricedb_get_db(QofBook * book) -> GNCPriceDB *"},
	 { "gnc_collection_get_pricedb", _wrap_gnc_collection_get_pricedb, METH_O, "gnc_collection_get_pricedb(QofCollection * col) -> GNCPriceDB *"},
	 { "gnc_pricedb_destroy", _wrap_gnc_pricedb_destroy, METH_O, "gnc_pricedb_destroy(GNCPriceDB * db)"},
	 { "gnc_pricedb_begin_edit", _wrap_gnc_pricedb_begin_edit, METH_O, "gnc_pricedb_begin_edit(GNCPriceDB * arg1)"},
	 { "gnc_pricedb_commit_edit", _wrap_gnc_pricedb_commit_edit, METH_O, "gnc_pricedb_commit_edit(GNCPriceDB * arg1)"},
	 { "gnc_pricedb_set_bulk_update", _wrap_gnc_pricedb_set_bulk_update, METH_VARARGS, "gnc_pricedb_set_bulk_update(GNCPriceDB * db, gboolean bulk_update)"},
	 { "gnc_pricedb_add_price", _wrap_gnc_pricedb_add_price, METH_VARARGS, "gnc_pricedb_add_price(GNCPriceDB * db, GNCPrice * p) -> gboolean"},
	 { "gnc_pricedb_remove_price", _wrap_gnc_pricedb_remove_price, METH_VARARGS, "gnc_pricedb_remove_price(GNCPriceDB * db, GNCPrice * p) -> gboolean"},
	 { "gnc_pricedb_remove_old_prices", _wrap_gnc_pricedb_remove_old_prices, METH_VARARGS, "gnc_pricedb_remove_old_prices(GNCPriceDB * db, GList * comm_list, GDate * fiscal_end_date, time64 cutoff, PriceRemoveSourceFlags source, PriceRemoveKeepOptions keep) -> gboolean"},
	 { "gnc_pricedb_lookup_latest", _wrap_gnc_pricedb_lookup_latest, METH_VARARGS, "gnc_pricedb_lookup_latest(GNCPriceDB * db, gnc_commodity const * commodity, gnc_commodity const * currency) -> GNCPrice *"},
	 { "gnc_pricedb_lookup_latest_any_currency", _wrap_gnc_pricedb_lookup_latest_any_currency, METH_VARARGS, "gnc_pricedb_lookup_latest_any_currency(GNCPriceDB * db, gnc_commodity const * commodity) -> PriceList *"},
	 { "gnc_pricedb_has_prices", _wrap_gnc_pricedb_has_prices, METH_VARARGS, "gnc_pricedb_has_prices(GNCPriceDB * db, gnc_commodity const * commodity, gnc_commodity const * currency) -> gboolean"},
	 { "gnc_pricedb_get_prices", _wrap_gnc_pricedb_get_prices, METH_VARARGS, "gnc_pricedb_get_prices(GNCPriceDB * db, gnc_commodity const * commodity, gnc_commodity const * currency) -> PriceList *"},
	 { "gnc_pricedb_lookup_at_time64", _wrap_gnc_pricedb_lookup_at_time64, METH_VARARGS, "gnc_pricedb_lookup_at_time64(GNCPriceDB * db, gnc_commodity const * commodity, gnc_commodity const * currency, time64 t) -> GNCPrice *"},
	 { "gnc_pricedb_lookup_day_t64", _wrap_gnc_pricedb_lookup_day_t64, METH_VARARGS, "gnc_pricedb_lookup_day_t64(GNCPriceDB * db, gnc_commodity const * commodity, gnc_commodity const * currency, time64 t) -> GNCPrice *"},
	 { "gnc_pricedb_lookup_nearest_in_time64", _wrap_gnc_pricedb_lookup_nearest_in_time64, METH_VARARGS, "gnc_pricedb_lookup_nearest_in_time64(GNCPriceDB * db, gnc_commodity const * c, gnc_commodity const * currency, time64 t) -> GNCPrice *"},
	 { "gnc_pricedb_lookup_nearest_in_time_any_currency_t64", _wrap_gnc_pricedb_lookup_nearest_in_time_any_currency_t64, METH_VARARGS, "gnc_pricedb_lookup_nearest_in_time_any_currency_t64(GNCPriceDB * db, gnc_commodity const * c, time64 t) -> PriceList *"},
	 { "gnc_pricedb_lookup_latest_before_t64", _wrap_gnc_pricedb_lookup_latest_before_t64, METH_VARARGS, "gnc_pricedb_lookup_latest_before_t64(GNCPriceDB * db, gnc_commodity * c, gnc_commodity * currency, time64 t) -> GNCPrice *"},
	 { "gnc_pricedb_lookup_latest_before_any_currency_t64", _wrap_gnc_pricedb_lookup_latest_before_any_currency_t64, METH_VARARGS, "gnc_pricedb_lookup_latest_before_any_currency_t64(GNCPriceDB * db, gnc_commodity const * c, time64 t) -> PriceList *"},
	 { "gnc_pricedb_convert_balance_latest_price", _wrap_gnc_pricedb_convert_balance_latest_price, METH_VARARGS, "gnc_pricedb_convert_balance_latest_price(GNCPriceDB * pdb, _gnc_numeric balance, gnc_commodity const * balance_currency, gnc_commodity const * new_currency) -> _gnc_numeric"},
	 { "gnc_pricedb_convert_balance_nearest_price_t64", _wrap_gnc_pricedb_convert_balance_nearest_price_t64, METH_VARARGS, "gnc_pricedb_convert_balance_nearest_price_t64(GNCPriceDB * pdb, _gnc_numeric balance, gnc_commodity const * balance_currency, gnc_commodity const * new_currency, time64 t) -> _gnc_numeric"},
	 { "gnc_pricedb_foreach_price", _wrap_gnc_pricedb_foreach_price, METH_VARARGS, "gnc_pricedb_foreach_price(GNCPriceDB * db, GncPriceForeachFunc f, gpointer user_data, gboolean stable_order) -> gboolean"},
	 { "gnc_pricedb_num_prices", _wrap_gnc_pricedb_num_prices, METH_VARARGS, "gnc_pricedb_num_prices(GNCPriceDB * db, gnc_commodity const * c) -> int"},
	 { "gnc_pricedb_nth_price", _wrap_gnc_pricedb_nth_price, METH_VARARGS, "gnc_pricedb_nth_price(GNCPriceDB * db, gnc_commodity const * c, int const n) -> GNCPrice *"},
	 { "gnc_pricedb_nth_price_reset_cache", _wrap_gnc_pricedb_nth_price_reset_cache, METH_O, "gnc_pricedb_nth_price_reset_cache(GNCPriceDB * db)"},
	 { "gnc_pricedb_get_num_prices", _wrap_gnc_pricedb_get_num_prices, METH_O, "gnc_pricedb_get_num_prices(GNCPriceDB * db) -> guint"},
	 { "gnc_pricedb_equal", _wrap_gnc_pricedb_equal, METH_VARARGS, "gnc_pricedb_equal(GNCPriceDB * db1, GNCPriceDB * db2) -> gboolean"},
	 { "gnc_pricedb_print_contents", _wrap_gnc_pricedb_print_contents, METH_VARARGS, "gnc_pricedb_print_contents(GNCPriceDB * db, FILE * f)"},
	 { "xaccSplitGetCapGains", _wrap_xaccSplitGetCapGains, METH_O, "xaccSplitGetCapGains(Split * arg1) -> _gnc_numeric"},
	 { "xaccAccountHasTrades", _wrap_xaccAccountHasTrades, METH_O, "xaccAccountHasTrades(Account const * arg1) -> gboolean"},
	 { "xaccAccountFindEarliestOpenLot", _wrap_xaccAccountFindEarliestOpenLot, METH_VARARGS, "xaccAccountFindEarliestOpenLot(Account * acc, _gnc_numeric sign, gnc_commodity * currency) -> GNCLot *"},
	 { "xaccAccountFindLatestOpenLot", _wrap_xaccAccountFindLatestOpenLot, METH_VARARGS, "xaccAccountFindLatestOpenLot(Account * acc, _gnc_numeric sign, gnc_commodity * currency) -> GNCLot *"},
	 { "xaccSplitGetCapGainsSplit", _wrap_xaccSplitGetCapGainsSplit, METH_O, "xaccSplitGetCapGainsSplit(Split const * arg1) -> Split *"},
	 { "xaccSplitGetGainsSourceSplit", _wrap_xaccSplitGetGainsSourceSplit, METH_O, "xaccSplitGetGainsSourceSplit(Split const * arg1) -> Split *"},
	 { "xaccSplitAssign", _wrap_xaccSplitAssign, METH_O, "xaccSplitAssign(Split * split) -> gboolean"},
	 { "xaccSplitAssignToLot", _wrap_xaccSplitAssignToLot, METH_VARARGS, "xaccSplitAssignToLot(Split * split, GNCLot * lot) -> Split *"},
	 { "xaccSplitComputeCapGains", _wrap_xaccSplitComputeCapGains, METH_VARARGS, "xaccSplitComputeCapGains(Split * split, Account * gain_acc)"},
	 { "xaccLotComputeCapGains", _wrap_xaccLotComputeCapGains, METH_VARARGS, "xaccLotComputeCapGains(GNCLot * lot, Account * gain_acc)"},
	 { "xaccScrubLot", _wrap_xaccScrubLot, METH_O, "xaccScrubLot(GNCLot * lot) -> gboolean"},
	 { "xaccAccountScrubLots", _wrap_xaccAccountScrubLots, METH_O, "xaccAccountScrubLots(Account * acc)"},
	 { "xaccAccountTreeScrubLots", _wrap_xaccAccountTreeScrubLots, METH_O, "xaccAccountTreeScrubLots(Account * acc)"},
	 { NULL, NULL, 0, NULL }
};

static PyMethodDef SwigMethods_proxydocs[] = {
	 { NULL, NULL, 0, NULL }
};


/* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */

static swig_type_info _swigt__p_Account = {"_p_Account", "Account *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_AccountClass = {"_p_AccountClass", "AccountClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_AccountList = {"_p_AccountList", "AccountList *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_FILE = {"_p_FILE", "FILE *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GCompareFunc = {"_p_GCompareFunc", "GCompareFunc *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GDate = {"_p_GDate", "GDate *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GHashTable = {"_p_GHashTable", "GHashTable *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GList = {"_p_GList", "GList *|CommodityList *|AccountValueList *|MonetaryList *|GncTaxTableList *|EntryList *|GncTaxTableEntryList *|GncInvoiceList *|PriceList *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GNCAccountType = {"_p_GNCAccountType", "enum GNCAccountType *|GNCAccountType *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GNCLot = {"_p_GNCLot", "GNCLot *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GNCNumericErrorCode = {"_p_GNCNumericErrorCode", "enum GNCNumericErrorCode *|GNCNumericErrorCode *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GNCPlaceholderType = {"_p_GNCPlaceholderType", "enum GNCPlaceholderType *|GNCPlaceholderType *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GNCPolicy = {"_p_GNCPolicy", "GNCPolicy *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GNCPrice = {"_p_GNCPrice", "GNCPrice *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GSList = {"_p_GSList", "GSList *|QofQueryParamList *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GType = {"_p_GType", "GType *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GValue = {"_p_GValue", "GValue *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GncAmountType = {"_p_GncAmountType", "enum GncAmountType *|GncAmountType *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GncBillTermType = {"_p_GncBillTermType", "enum GncBillTermType *|GncBillTermType *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GncDiscountHow = {"_p_GncDiscountHow", "enum GncDiscountHow *|GncDiscountHow *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GncEntryPaymentType = {"_p_GncEntryPaymentType", "enum GncEntryPaymentType *|GncEntryPaymentType *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GncImportMatchMap = {"_p_GncImportMatchMap", "GncImportMatchMap *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GncInvoiceType = {"_p_GncInvoiceType", "enum GncInvoiceType *|GncInvoiceType *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GncLotClass = {"_p_GncLotClass", "GncLotClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GncOrder = {"_p_GncOrder", "GncOrder *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GncOwnerType = {"_p_GncOwnerType", "enum GncOwnerType *|GncOwnerType *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_GncTaxIncluded = {"_p_GncTaxIncluded", "enum GncTaxIncluded *|GncTaxIncluded *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_LotList = {"_p_LotList", "LotList *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_PriceRemoveKeepOptions = {"_p_PriceRemoveKeepOptions", "enum PriceRemoveKeepOptions *|PriceRemoveKeepOptions *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_PriceRemoveSourceFlags = {"_p_PriceRemoveSourceFlags", "enum PriceRemoveSourceFlags *|PriceRemoveSourceFlags *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_PriceSource = {"_p_PriceSource", "enum PriceSource *|PriceSource *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofBackend = {"_p_QofBackend", "struct QofBackend *|QofBackend *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofBackendError = {"_p_QofBackendError", "enum QofBackendError *|QofBackendError *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofBook = {"_p_QofBook", "QofBook *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofCharMatch = {"_p_QofCharMatch", "enum QofCharMatch *|QofCharMatch *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofCollection_s = {"_p_QofCollection_s", "QofCollection *|struct QofCollection_s *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofDateMatch = {"_p_QofDateMatch", "enum QofDateMatch *|QofDateMatch *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofGuidMatch = {"_p_QofGuidMatch", "enum QofGuidMatch *|QofGuidMatch *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofInstance = {"_p_QofInstance", "QofInstance *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofInstanceClass = {"_p_QofInstanceClass", "QofInstanceClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofNumericMatch = {"_p_QofNumericMatch", "enum QofNumericMatch *|QofNumericMatch *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofParam = {"_p_QofParam", "QofParam *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofQueryCompare = {"_p_QofQueryCompare", "enum QofQueryCompare *|QofQueryCompare *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofQueryOp = {"_p_QofQueryOp", "enum QofQueryOp *|QofQueryOp *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofSessionImpl = {"_p_QofSessionImpl", "struct QofSessionImpl *|QofSession *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofStringMatch = {"_p_QofStringMatch", "enum QofStringMatch *|QofStringMatch *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QofType = {"_p_QofType", "QofType *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_QuoteSourceType = {"_p_QuoteSourceType", "enum QuoteSourceType *|QuoteSourceType *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_Split = {"_p_Split", "Split *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_SplitList = {"_p_SplitList", "SplitList *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_Transaction = {"_p_Transaction", "Transaction *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_TransactionCallback = {"_p_TransactionCallback", "TransactionCallback *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__GncCommodityClass = {"_p__GncCommodityClass", "struct _GncCommodityClass *|gnc_commodityClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__GncCommodityNamespaceClass = {"_p__GncCommodityNamespaceClass", "struct _GncCommodityNamespaceClass *|gnc_commodity_namespaceClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__GncPriceClass = {"_p__GncPriceClass", "struct _GncPriceClass *|GNCPriceClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__GncPriceDBClass = {"_p__GncPriceDBClass", "struct _GncPriceDBClass *|GNCPriceDBClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__QofQuery = {"_p__QofQuery", "struct _QofQuery *|QofQuery *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__QofQueryPredData = {"_p__QofQueryPredData", "struct _QofQueryPredData *|QofQueryPredData *|_QofQueryPredData *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__SplitClass = {"_p__SplitClass", "struct _SplitClass *|SplitClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__TransactionClass = {"_p__TransactionClass", "struct _TransactionClass *|TransactionClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncAccountValue = {"_p__gncAccountValue", "struct _gncAccountValue *|GncAccountValue *|_gncAccountValue *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncAddress = {"_p__gncAddress", "struct _gncAddress *|GncAddress *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncAddressClass = {"_p__gncAddressClass", "struct _gncAddressClass *|GncAddressClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncBillTerm = {"_p__gncBillTerm", "struct _gncBillTerm *|GncBillTerm *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncBillTermClass = {"_p__gncBillTermClass", "struct _gncBillTermClass *|GncBillTermClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncCustomer = {"_p__gncCustomer", "struct _gncCustomer *|GncCustomer *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncCustomerClass = {"_p__gncCustomerClass", "struct _gncCustomerClass *|GncCustomerClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncEmployee = {"_p__gncEmployee", "struct _gncEmployee *|GncEmployee *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncEmployeeClass = {"_p__gncEmployeeClass", "struct _gncEmployeeClass *|GncEmployeeClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncEntry = {"_p__gncEntry", "struct _gncEntry *|GncEntry *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncEntryClass = {"_p__gncEntryClass", "struct _gncEntryClass *|GncEntryClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncGuid = {"_p__gncGuid", "struct _gncGuid *|GncGUID *|_gncGuid *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncInvoice = {"_p__gncInvoice", "struct _gncInvoice *|GncInvoice *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncInvoiceClass = {"_p__gncInvoiceClass", "struct _gncInvoiceClass *|GncInvoiceClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncJob = {"_p__gncJob", "struct _gncJob *|GncJob *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncJobClass = {"_p__gncJobClass", "struct _gncJobClass *|GncJobClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncOwner = {"_p__gncOwner", "struct _gncOwner *|GncOwner *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncTaxTable = {"_p__gncTaxTable", "struct _gncTaxTable *|GncTaxTable *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncTaxTableClass = {"_p__gncTaxTableClass", "struct _gncTaxTableClass *|GncTaxTableClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncTaxTableEntry = {"_p__gncTaxTableEntry", "struct _gncTaxTableEntry *|GncTaxTableEntry *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncVendor = {"_p__gncVendor", "struct _gncVendor *|GncVendor *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gncVendorClass = {"_p__gncVendorClass", "struct _gncVendorClass *|GncVendorClass *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gnc_monetary = {"_p__gnc_monetary", "struct _gnc_monetary *|gnc_monetary *|_gnc_monetary *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p__gnc_numeric = {"_p__gnc_numeric", "struct _gnc_numeric *|gnc_numeric *|_gnc_numeric *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_Account_p_void__p_void = {"_p_f_p_Account_p_void__p_void", "void *(*)(Account *,void *)|AccountCb2", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_Account_p_void__void = {"_p_f_p_Account_p_void__void", "AccountCb|void (*)(Account *,void *)", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_GNCLot_p_void__gboolean = {"_p_f_p_GNCLot_p_void__gboolean", "gboolean (*)(GNCLot *,void *)|gboolean (*)(GNCLot *,gpointer)", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_GNCLot_p_void__p_void = {"_p_f_p_GNCLot_p_void__p_void", "void *(*)(GNCLot *,void *)|gpointer (*)(GNCLot *,gpointer)", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_GNCPrice_p_void__gboolean = {"_p_f_p_GNCPrice_p_void__gboolean", "gboolean (*)(GNCPrice *,void *)|GncPriceForeachFunc", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_QofInstance_p_void__void = {"_p_f_p_QofInstance_p_void__void", "QofInstanceForeachCB|void (*)(QofInstance *,void *)", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_gnc_commodity_p_void__gboolean = {"_p_f_p_gnc_commodity_p_void__gboolean", "gboolean (*)(gnc_commodity *,void *)|gboolean (*)(gnc_commodity *,gpointer)", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_f_p_q_const__char_double__void = {"_p_f_p_q_const__char_double__void", "QofPercentageFunc|void (*)(char const *,double)", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gboolean = {"_p_gboolean", "gboolean *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gconstpointer = {"_p_gconstpointer", "gconstpointer *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gnc_commodity = {"_p_gnc_commodity", "gnc_commodity *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gnc_commodity_namespace = {"_p_gnc_commodity_namespace", "gnc_commodity_namespace *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gnc_commodity_table = {"_p_gnc_commodity_table", "gnc_commodity_table *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gnc_price_db_s = {"_p_gnc_price_db_s", "GNCPriceDB *|struct gnc_price_db_s *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gnc_quote_source = {"_p_gnc_quote_source", "gnc_quote_source *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_guint32 = {"_p_guint32", "guint32 *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_guint8 = {"_p_guint8", "guint8 *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_gunichar = {"_p_gunichar", "gunichar *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_imap_info = {"_p_imap_info", "struct imap_info *|GncImapInfo *|imap_info *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_int = {"_p_int", "intptr_t *|int *|int_least32_t *|int_fast32_t *|int32_t *|int_fast16_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_long_long = {"_p_long_long", "int_least64_t *|int_fast64_t *|int64_t *|long long *|intmax_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_GList = {"_p_p_GList", "GList **|PriceList **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_Transaction = {"_p_p_Transaction", "Transaction **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_short = {"_p_short", "short *|int_least16_t *|int16_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_signed_char = {"_p_signed_char", "signed char *|int_least8_t *|int_fast8_t *|int8_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_time64 = {"_p_time64", "time64 *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_unsigned_char = {"_p_unsigned_char", "unsigned char *|uint_least8_t *|uint_fast8_t *|uint8_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_unsigned_int = {"_p_unsigned_int", "uintptr_t *|uint_least32_t *|uint_fast32_t *|uint32_t *|unsigned int *|uint_fast16_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_unsigned_long_long = {"_p_unsigned_long_long", "uint_least64_t *|uint_fast64_t *|uint64_t *|unsigned long long *|uintmax_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_unsigned_short = {"_p_unsigned_short", "unsigned short *|uint_least16_t *|uint16_t *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_void = {"_p_void", "gpointer|void *", 0, 0, (void*)0, 0};

static swig_type_info *swig_type_initial[] = {
  &_swigt__p_Account,
  &_swigt__p_AccountClass,
  &_swigt__p_AccountList,
  &_swigt__p_FILE,
  &_swigt__p_GCompareFunc,
  &_swigt__p_GDate,
  &_swigt__p_GHashTable,
  &_swigt__p_GList,
  &_swigt__p_GNCAccountType,
  &_swigt__p_GNCLot,
  &_swigt__p_GNCNumericErrorCode,
  &_swigt__p_GNCPlaceholderType,
  &_swigt__p_GNCPolicy,
  &_swigt__p_GNCPrice,
  &_swigt__p_GSList,
  &_swigt__p_GType,
  &_swigt__p_GValue,
  &_swigt__p_GncAmountType,
  &_swigt__p_GncBillTermType,
  &_swigt__p_GncDiscountHow,
  &_swigt__p_GncEntryPaymentType,
  &_swigt__p_GncImportMatchMap,
  &_swigt__p_GncInvoiceType,
  &_swigt__p_GncLotClass,
  &_swigt__p_GncOrder,
  &_swigt__p_GncOwnerType,
  &_swigt__p_GncTaxIncluded,
  &_swigt__p_LotList,
  &_swigt__p_PriceRemoveKeepOptions,
  &_swigt__p_PriceRemoveSourceFlags,
  &_swigt__p_PriceSource,
  &_swigt__p_QofBackend,
  &_swigt__p_QofBackendError,
  &_swigt__p_QofBook,
  &_swigt__p_QofCharMatch,
  &_swigt__p_QofCollection_s,
  &_swigt__p_QofDateMatch,
  &_swigt__p_QofGuidMatch,
  &_swigt__p_QofInstance,
  &_swigt__p_QofInstanceClass,
  &_swigt__p_QofNumericMatch,
  &_swigt__p_QofParam,
  &_swigt__p_QofQueryCompare,
  &_swigt__p_QofQueryOp,
  &_swigt__p_QofSessionImpl,
  &_swigt__p_QofStringMatch,
  &_swigt__p_QofType,
  &_swigt__p_QuoteSourceType,
  &_swigt__p_Split,
  &_swigt__p_SplitList,
  &_swigt__p_Transaction,
  &_swigt__p_TransactionCallback,
  &_swigt__p__GncCommodityClass,
  &_swigt__p__GncCommodityNamespaceClass,
  &_swigt__p__GncPriceClass,
  &_swigt__p__GncPriceDBClass,
  &_swigt__p__QofQuery,
  &_swigt__p__QofQueryPredData,
  &_swigt__p__SplitClass,
  &_swigt__p__TransactionClass,
  &_swigt__p__gncAccountValue,
  &_swigt__p__gncAddress,
  &_swigt__p__gncAddressClass,
  &_swigt__p__gncBillTerm,
  &_swigt__p__gncBillTermClass,
  &_swigt__p__gncCustomer,
  &_swigt__p__gncCustomerClass,
  &_swigt__p__gncEmployee,
  &_swigt__p__gncEmployeeClass,
  &_swigt__p__gncEntry,
  &_swigt__p__gncEntryClass,
  &_swigt__p__gncGuid,
  &_swigt__p__gncInvoice,
  &_swigt__p__gncInvoiceClass,
  &_swigt__p__gncJob,
  &_swigt__p__gncJobClass,
  &_swigt__p__gncOwner,
  &_swigt__p__gncTaxTable,
  &_swigt__p__gncTaxTableClass,
  &_swigt__p__gncTaxTableEntry,
  &_swigt__p__gncVendor,
  &_swigt__p__gncVendorClass,
  &_swigt__p__gnc_monetary,
  &_swigt__p__gnc_numeric,
  &_swigt__p_char,
  &_swigt__p_f_p_Account_p_void__p_void,
  &_swigt__p_f_p_Account_p_void__void,
  &_swigt__p_f_p_GNCLot_p_void__gboolean,
  &_swigt__p_f_p_GNCLot_p_void__p_void,
  &_swigt__p_f_p_GNCPrice_p_void__gboolean,
  &_swigt__p_f_p_QofInstance_p_void__void,
  &_swigt__p_f_p_gnc_commodity_p_void__gboolean,
  &_swigt__p_f_p_q_const__char_double__void,
  &_swigt__p_gboolean,
  &_swigt__p_gconstpointer,
  &_swigt__p_gnc_commodity,
  &_swigt__p_gnc_commodity_namespace,
  &_swigt__p_gnc_commodity_table,
  &_swigt__p_gnc_price_db_s,
  &_swigt__p_gnc_quote_source,
  &_swigt__p_guint32,
  &_swigt__p_guint8,
  &_swigt__p_gunichar,
  &_swigt__p_imap_info,
  &_swigt__p_int,
  &_swigt__p_long_long,
  &_swigt__p_p_GList,
  &_swigt__p_p_Transaction,
  &_swigt__p_short,
  &_swigt__p_signed_char,
  &_swigt__p_time64,
  &_swigt__p_unsigned_char,
  &_swigt__p_unsigned_int,
  &_swigt__p_unsigned_long_long,
  &_swigt__p_unsigned_short,
  &_swigt__p_void,
};

static swig_cast_info _swigc__p_Account[] = {  {&_swigt__p_Account, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_AccountClass[] = {  {&_swigt__p_AccountClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_AccountList[] = {  {&_swigt__p_AccountList, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_FILE[] = {  {&_swigt__p_FILE, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GCompareFunc[] = {  {&_swigt__p_GCompareFunc, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GDate[] = {  {&_swigt__p_GDate, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GHashTable[] = {  {&_swigt__p_GHashTable, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GList[] = {  {&_swigt__p_GList, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GNCAccountType[] = {  {&_swigt__p_GNCAccountType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GNCLot[] = {  {&_swigt__p_GNCLot, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GNCNumericErrorCode[] = {  {&_swigt__p_GNCNumericErrorCode, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GNCPlaceholderType[] = {  {&_swigt__p_GNCPlaceholderType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GNCPolicy[] = {  {&_swigt__p_GNCPolicy, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GNCPrice[] = {  {&_swigt__p_GNCPrice, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GSList[] = {  {&_swigt__p_GSList, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GType[] = {  {&_swigt__p_GType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GValue[] = {  {&_swigt__p_GValue, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GncAmountType[] = {  {&_swigt__p_GncAmountType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GncBillTermType[] = {  {&_swigt__p_GncBillTermType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GncDiscountHow[] = {  {&_swigt__p_GncDiscountHow, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GncEntryPaymentType[] = {  {&_swigt__p_GncEntryPaymentType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GncImportMatchMap[] = {  {&_swigt__p_GncImportMatchMap, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GncInvoiceType[] = {  {&_swigt__p_GncInvoiceType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GncLotClass[] = {  {&_swigt__p_GncLotClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GncOrder[] = {  {&_swigt__p_GncOrder, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GncOwnerType[] = {  {&_swigt__p_GncOwnerType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_GncTaxIncluded[] = {  {&_swigt__p_GncTaxIncluded, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_LotList[] = {  {&_swigt__p_LotList, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_PriceRemoveKeepOptions[] = {  {&_swigt__p_PriceRemoveKeepOptions, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_PriceRemoveSourceFlags[] = {  {&_swigt__p_PriceRemoveSourceFlags, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_PriceSource[] = {  {&_swigt__p_PriceSource, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofBackend[] = {  {&_swigt__p_QofBackend, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofBackendError[] = {  {&_swigt__p_QofBackendError, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofBook[] = {  {&_swigt__p_QofBook, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofCharMatch[] = {  {&_swigt__p_QofCharMatch, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofCollection_s[] = {  {&_swigt__p_QofCollection_s, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofDateMatch[] = {  {&_swigt__p_QofDateMatch, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofGuidMatch[] = {  {&_swigt__p_QofGuidMatch, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofInstance[] = {  {&_swigt__p_QofInstance, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofInstanceClass[] = {  {&_swigt__p_QofInstanceClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofNumericMatch[] = {  {&_swigt__p_QofNumericMatch, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofParam[] = {  {&_swigt__p_QofParam, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofQueryCompare[] = {  {&_swigt__p_QofQueryCompare, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofQueryOp[] = {  {&_swigt__p_QofQueryOp, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofSessionImpl[] = {  {&_swigt__p_QofSessionImpl, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofStringMatch[] = {  {&_swigt__p_QofStringMatch, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QofType[] = {  {&_swigt__p_QofType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_QuoteSourceType[] = {  {&_swigt__p_QuoteSourceType, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Split[] = {  {&_swigt__p_Split, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_SplitList[] = {  {&_swigt__p_SplitList, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_Transaction[] = {  {&_swigt__p_Transaction, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_TransactionCallback[] = {  {&_swigt__p_TransactionCallback, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__GncCommodityClass[] = {  {&_swigt__p__GncCommodityClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__GncCommodityNamespaceClass[] = {  {&_swigt__p__GncCommodityNamespaceClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__GncPriceClass[] = {  {&_swigt__p__GncPriceClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__GncPriceDBClass[] = {  {&_swigt__p__GncPriceDBClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__QofQuery[] = {  {&_swigt__p__QofQuery, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__QofQueryPredData[] = {  {&_swigt__p__QofQueryPredData, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__SplitClass[] = {  {&_swigt__p__SplitClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__TransactionClass[] = {  {&_swigt__p__TransactionClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncAccountValue[] = {  {&_swigt__p__gncAccountValue, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncAddress[] = {  {&_swigt__p__gncAddress, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncAddressClass[] = {  {&_swigt__p__gncAddressClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncBillTerm[] = {  {&_swigt__p__gncBillTerm, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncBillTermClass[] = {  {&_swigt__p__gncBillTermClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncCustomer[] = {  {&_swigt__p__gncCustomer, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncCustomerClass[] = {  {&_swigt__p__gncCustomerClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncEmployee[] = {  {&_swigt__p__gncEmployee, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncEmployeeClass[] = {  {&_swigt__p__gncEmployeeClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncEntry[] = {  {&_swigt__p__gncEntry, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncEntryClass[] = {  {&_swigt__p__gncEntryClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncGuid[] = {  {&_swigt__p__gncGuid, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncInvoice[] = {  {&_swigt__p__gncInvoice, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncInvoiceClass[] = {  {&_swigt__p__gncInvoiceClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncJob[] = {  {&_swigt__p__gncJob, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncJobClass[] = {  {&_swigt__p__gncJobClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncOwner[] = {  {&_swigt__p__gncOwner, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncTaxTable[] = {  {&_swigt__p__gncTaxTable, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncTaxTableClass[] = {  {&_swigt__p__gncTaxTableClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncTaxTableEntry[] = {  {&_swigt__p__gncTaxTableEntry, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncVendor[] = {  {&_swigt__p__gncVendor, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gncVendorClass[] = {  {&_swigt__p__gncVendorClass, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gnc_monetary[] = {  {&_swigt__p__gnc_monetary, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p__gnc_numeric[] = {  {&_swigt__p__gnc_numeric, 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_f_p_Account_p_void__p_void[] = {  {&_swigt__p_f_p_Account_p_void__p_void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_Account_p_void__void[] = {  {&_swigt__p_f_p_Account_p_void__void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_GNCLot_p_void__gboolean[] = {  {&_swigt__p_f_p_GNCLot_p_void__gboolean, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_GNCLot_p_void__p_void[] = {  {&_swigt__p_f_p_GNCLot_p_void__p_void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_GNCPrice_p_void__gboolean[] = {  {&_swigt__p_f_p_GNCPrice_p_void__gboolean, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_QofInstance_p_void__void[] = {  {&_swigt__p_f_p_QofInstance_p_void__void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_gnc_commodity_p_void__gboolean[] = {  {&_swigt__p_f_p_gnc_commodity_p_void__gboolean, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_f_p_q_const__char_double__void[] = {  {&_swigt__p_f_p_q_const__char_double__void, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gboolean[] = {  {&_swigt__p_gboolean, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gconstpointer[] = {  {&_swigt__p_gconstpointer, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gnc_commodity[] = {  {&_swigt__p_gnc_commodity, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gnc_commodity_namespace[] = {  {&_swigt__p_gnc_commodity_namespace, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gnc_commodity_table[] = {  {&_swigt__p_gnc_commodity_table, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gnc_price_db_s[] = {  {&_swigt__p_gnc_price_db_s, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gnc_quote_source[] = {  {&_swigt__p_gnc_quote_source, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_guint32[] = {  {&_swigt__p_guint32, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_guint8[] = {  {&_swigt__p_guint8, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_gunichar[] = {  {&_swigt__p_gunichar, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_imap_info[] = {  {&_swigt__p_imap_info, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_int[] = {  {&_swigt__p_int, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_long_long[] = {  {&_swigt__p_long_long, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_GList[] = {  {&_swigt__p_p_GList, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_Transaction[] = {  {&_swigt__p_p_Transaction, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_short[] = {  {&_swigt__p_short, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_signed_char[] = {  {&_swigt__p_signed_char, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_time64[] = {  {&_swigt__p_time64, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_unsigned_char[] = {  {&_swigt__p_unsigned_char, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_unsigned_int[] = {  {&_swigt__p_unsigned_int, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_unsigned_long_long[] = {  {&_swigt__p_unsigned_long_long, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_unsigned_short[] = {  {&_swigt__p_unsigned_short, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_void[] = {  {&_swigt__p_void, 0, 0, 0},{0, 0, 0, 0}};

static swig_cast_info *swig_cast_initial[] = {
  _swigc__p_Account,
  _swigc__p_AccountClass,
  _swigc__p_AccountList,
  _swigc__p_FILE,
  _swigc__p_GCompareFunc,
  _swigc__p_GDate,
  _swigc__p_GHashTable,
  _swigc__p_GList,
  _swigc__p_GNCAccountType,
  _swigc__p_GNCLot,
  _swigc__p_GNCNumericErrorCode,
  _swigc__p_GNCPlaceholderType,
  _swigc__p_GNCPolicy,
  _swigc__p_GNCPrice,
  _swigc__p_GSList,
  _swigc__p_GType,
  _swigc__p_GValue,
  _swigc__p_GncAmountType,
  _swigc__p_GncBillTermType,
  _swigc__p_GncDiscountHow,
  _swigc__p_GncEntryPaymentType,
  _swigc__p_GncImportMatchMap,
  _swigc__p_GncInvoiceType,
  _swigc__p_GncLotClass,
  _swigc__p_GncOrder,
  _swigc__p_GncOwnerType,
  _swigc__p_GncTaxIncluded,
  _swigc__p_LotList,
  _swigc__p_PriceRemoveKeepOptions,
  _swigc__p_PriceRemoveSourceFlags,
  _swigc__p_PriceSource,
  _swigc__p_QofBackend,
  _swigc__p_QofBackendError,
  _swigc__p_QofBook,
  _swigc__p_QofCharMatch,
  _swigc__p_QofCollection_s,
  _swigc__p_QofDateMatch,
  _swigc__p_QofGuidMatch,
  _swigc__p_QofInstance,
  _swigc__p_QofInstanceClass,
  _swigc__p_QofNumericMatch,
  _swigc__p_QofParam,
  _swigc__p_QofQueryCompare,
  _swigc__p_QofQueryOp,
  _swigc__p_QofSessionImpl,
  _swigc__p_QofStringMatch,
  _swigc__p_QofType,
  _swigc__p_QuoteSourceType,
  _swigc__p_Split,
  _swigc__p_SplitList,
  _swigc__p_Transaction,
  _swigc__p_TransactionCallback,
  _swigc__p__GncCommodityClass,
  _swigc__p__GncCommodityNamespaceClass,
  _swigc__p__GncPriceClass,
  _swigc__p__GncPriceDBClass,
  _swigc__p__QofQuery,
  _swigc__p__QofQueryPredData,
  _swigc__p__SplitClass,
  _swigc__p__TransactionClass,
  _swigc__p__gncAccountValue,
  _swigc__p__gncAddress,
  _swigc__p__gncAddressClass,
  _swigc__p__gncBillTerm,
  _swigc__p__gncBillTermClass,
  _swigc__p__gncCustomer,
  _swigc__p__gncCustomerClass,
  _swigc__p__gncEmployee,
  _swigc__p__gncEmployeeClass,
  _swigc__p__gncEntry,
  _swigc__p__gncEntryClass,
  _swigc__p__gncGuid,
  _swigc__p__gncInvoice,
  _swigc__p__gncInvoiceClass,
  _swigc__p__gncJob,
  _swigc__p__gncJobClass,
  _swigc__p__gncOwner,
  _swigc__p__gncTaxTable,
  _swigc__p__gncTaxTableClass,
  _swigc__p__gncTaxTableEntry,
  _swigc__p__gncVendor,
  _swigc__p__gncVendorClass,
  _swigc__p__gnc_monetary,
  _swigc__p__gnc_numeric,
  _swigc__p_char,
  _swigc__p_f_p_Account_p_void__p_void,
  _swigc__p_f_p_Account_p_void__void,
  _swigc__p_f_p_GNCLot_p_void__gboolean,
  _swigc__p_f_p_GNCLot_p_void__p_void,
  _swigc__p_f_p_GNCPrice_p_void__gboolean,
  _swigc__p_f_p_QofInstance_p_void__void,
  _swigc__p_f_p_gnc_commodity_p_void__gboolean,
  _swigc__p_f_p_q_const__char_double__void,
  _swigc__p_gboolean,
  _swigc__p_gconstpointer,
  _swigc__p_gnc_commodity,
  _swigc__p_gnc_commodity_namespace,
  _swigc__p_gnc_commodity_table,
  _swigc__p_gnc_price_db_s,
  _swigc__p_gnc_quote_source,
  _swigc__p_guint32,
  _swigc__p_guint8,
  _swigc__p_gunichar,
  _swigc__p_imap_info,
  _swigc__p_int,
  _swigc__p_long_long,
  _swigc__p_p_GList,
  _swigc__p_p_Transaction,
  _swigc__p_short,
  _swigc__p_signed_char,
  _swigc__p_time64,
  _swigc__p_unsigned_char,
  _swigc__p_unsigned_int,
  _swigc__p_unsigned_long_long,
  _swigc__p_unsigned_short,
  _swigc__p_void,
};


/* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */

static swig_const_info swig_const_table[] = {
{0, 0, 0, 0.0, 0, 0}};

#ifdef __cplusplus
}
#endif
/* -----------------------------------------------------------------------------
 * Type initialization:
 * This problem is tough by the requirement that no dynamic
 * memory is used. Also, since swig_type_info structures store pointers to
 * 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 statically to an initial
 * array. We just loop through that array, and handle each type individually.
 * First we lookup if this type has been already loaded, and if so, use the
 * loaded structure instead of the generated one. Then we have to fill in the
 * 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 init;
  
  /* 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);
  } else {
    /* the interpreter has loaded a SWIG module, but has it loaded this one? */
    iter=module_head;
    do {
      if (iter==&swig_module) {
        /* Our module is already in the list, so there's nothing more to do. */
        return;
      }
      iter=iter->next;
    } while (iter!= module_head);
    
    /* otherwise we must add our module into the list */
    swig_module.next = module_head->next;
    module_head->next = &swig_module;
  }
  
  /* When multiple interpreters are used, a module could have already been initialized in
       a different interpreter, but not yet have a pointer in this interpreter.
       In this case, we do not want to continue adding types... everything should be
       set up already */
  if (init == 0) return;
  
  /* Now work on filling in swig_module.types */
#ifdef SWIGRUNTIME_DEBUG
  printf("SWIG_InitializeModule: size %lu\n", (unsigned long)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 %lu %s\n", (unsigned long)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 %lu %s\n", (unsigned long)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
  
  /* Python-specific SWIG API */
#define SWIG_newvarlink()                             SWIG_Python_newvarlink()
#define SWIG_addvarlink(p, name, get_attr, set_attr)  SWIG_Python_addvarlink(p, name, get_attr, set_attr)
#define SWIG_InstallConstants(d, constants)           SWIG_Python_InstallConstants(d, constants)
  
  /* -----------------------------------------------------------------------------
   * global variable support code.
   * ----------------------------------------------------------------------------- */
  
  typedef struct swig_globalvar {
    char       *name;                  /* Name of global variable */
    PyObject *(*get_attr)(void);       /* Return the current value */
    int       (*set_attr)(PyObject *); /* Set the value */
    struct swig_globalvar *next;
  } swig_globalvar;
  
  typedef struct swig_varlinkobject {
    PyObject_HEAD
    swig_globalvar *vars;
  } swig_varlinkobject;
  
  SWIGINTERN PyObject *
  swig_varlink_repr(swig_varlinkobject *SWIGUNUSEDPARM(v)) {
#if PY_VERSION_HEX >= 0x03000000
    return PyUnicode_InternFromString("<Swig global variables>");
#else
    return PyString_FromString("<Swig global variables>");
#endif
  }
  
  SWIGINTERN PyObject *
  swig_varlink_str(swig_varlinkobject *v) {
#if PY_VERSION_HEX >= 0x03000000
    PyObject *str = PyUnicode_InternFromString("(");
    PyObject *tail;
    PyObject *joined;
    swig_globalvar *var;
    for (var = v->vars; var; var=var->next) {
      tail = PyUnicode_FromString(var->name);
      joined = PyUnicode_Concat(str, tail);
      Py_DecRef(str);
      Py_DecRef(tail);
      str = joined;
      if (var->next) {
        tail = PyUnicode_InternFromString(", ");
        joined = PyUnicode_Concat(str, tail);
        Py_DecRef(str);
        Py_DecRef(tail);
        str = joined;
      }
    }
    tail = PyUnicode_InternFromString(")");
    joined = PyUnicode_Concat(str, tail);
    Py_DecRef(str);
    Py_DecRef(tail);
    str = joined;
#else
    PyObject *str = PyString_FromString("(");
    swig_globalvar *var;
    for (var = v->vars; var; var=var->next) {
      PyString_ConcatAndDel(&str,PyString_FromString(var->name));
      if (var->next) PyString_ConcatAndDel(&str,PyString_FromString(", "));
    }
    PyString_ConcatAndDel(&str,PyString_FromString(")"));
#endif
    return str;
  }
  
  SWIGINTERN void
  swig_varlink_dealloc(swig_varlinkobject *v) {
    swig_globalvar *var = v->vars;
    while (var) {
      swig_globalvar *n = var->next;
      free(var->name);
      free(var);
      var = n;
    }
  }
  
  SWIGINTERN PyObject *
  swig_varlink_getattr(swig_varlinkobject *v, char *n) {
    PyObject *res = NULL;
    swig_globalvar *var = v->vars;
    while (var) {
      if (strcmp(var->name,n) == 0) {
        res = (*var->get_attr)();
        break;
      }
      var = var->next;
    }
    if (res == NULL && !PyErr_Occurred()) {
      PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n);
    }
    return res;
  }
  
  SWIGINTERN int
  swig_varlink_setattr(swig_varlinkobject *v, char *n, PyObject *p) {
    int res = 1;
    swig_globalvar *var = v->vars;
    while (var) {
      if (strcmp(var->name,n) == 0) {
        res = (*var->set_attr)(p);
        break;
      }
      var = var->next;
    }
    if (res == 1 && !PyErr_Occurred()) {
      PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n);
    }
    return res;
  }
  
  SWIGINTERN PyTypeObject*
  swig_varlink_type(void) {
    static char varlink__doc__[] = "Swig var link object";
    static PyTypeObject varlink_type;
    static int type_init = 0;
    if (!type_init) {
      const PyTypeObject tmp = {
#if PY_VERSION_HEX >= 0x03000000
        PyVarObject_HEAD_INIT(NULL, 0)
#else
        PyObject_HEAD_INIT(NULL)
        0,                                  /* ob_size */
#endif
        "swigvarlink",                      /* tp_name */
        sizeof(swig_varlinkobject),         /* tp_basicsize */
        0,                                  /* tp_itemsize */
        (destructor) swig_varlink_dealloc,  /* tp_dealloc */
        0,                                  /* tp_print */
        (getattrfunc) swig_varlink_getattr, /* tp_getattr */
        (setattrfunc) swig_varlink_setattr, /* tp_setattr */
        0,                                  /* tp_compare */
        (reprfunc) swig_varlink_repr,       /* tp_repr */
        0,                                  /* tp_as_number */
        0,                                  /* tp_as_sequence */
        0,                                  /* tp_as_mapping */
        0,                                  /* tp_hash */
        0,                                  /* tp_call */
        (reprfunc) swig_varlink_str,        /* tp_str */
        0,                                  /* tp_getattro */
        0,                                  /* tp_setattro */
        0,                                  /* tp_as_buffer */
        0,                                  /* tp_flags */
        varlink__doc__,                     /* tp_doc */
        0,                                  /* tp_traverse */
        0,                                  /* tp_clear */
        0,                                  /* tp_richcompare */
        0,                                  /* tp_weaklistoffset */
        0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */
        0,                                  /* tp_del */
        0,                                  /* tp_version_tag */
#if PY_VERSION_HEX >= 0x03040000
        0,                                  /* tp_finalize */
#endif
#ifdef COUNT_ALLOCS
        0,                                  /* tp_allocs */
        0,                                  /* tp_frees */
        0,                                  /* tp_maxalloc */
        0,                                  /* tp_prev */
        0                                   /* tp_next */
#endif
      };
      varlink_type = tmp;
      type_init = 1;
      if (PyType_Ready(&varlink_type) < 0)
      return NULL;
    }
    return &varlink_type;
  }
  
  /* Create a variable linking object for use later */
  SWIGINTERN PyObject *
  SWIG_Python_newvarlink(void) {
    swig_varlinkobject *result = PyObject_NEW(swig_varlinkobject, swig_varlink_type());
    if (result) {
      result->vars = 0;
    }
    return ((PyObject*) result);
  }
  
  SWIGINTERN void 
  SWIG_Python_addvarlink(PyObject *p, const char *name, PyObject *(*get_attr)(void), int (*set_attr)(PyObject *p)) {
    swig_varlinkobject *v = (swig_varlinkobject *) p;
    swig_globalvar *gv = (swig_globalvar *) malloc(sizeof(swig_globalvar));
    if (gv) {
      size_t size = strlen(name)+1;
      gv->name = (char *)malloc(size);
      if (gv->name) {
        memcpy(gv->name, name, size);
        gv->get_attr = get_attr;
        gv->set_attr = set_attr;
        gv->next = v->vars;
      }
    }
    v->vars = gv;
  }
  
  SWIGINTERN PyObject *
  SWIG_globals(void) {
    static PyObject *globals = 0;
    if (!globals) {
      globals = SWIG_newvarlink();
    }
    return globals;
  }
  
  /* -----------------------------------------------------------------------------
   * constants/methods manipulation
   * ----------------------------------------------------------------------------- */
  
  /* Install Constants */
  SWIGINTERN void
  SWIG_Python_InstallConstants(PyObject *d, swig_const_info constants[]) {
    PyObject *obj = 0;
    size_t i;
    for (i = 0; constants[i].type; ++i) {
      switch(constants[i].type) {
      case SWIG_PY_POINTER:
        obj = SWIG_InternalNewPointerObj(constants[i].pvalue, *(constants[i]).ptype,0);
        break;
      case SWIG_PY_BINARY:
        obj = SWIG_NewPackedObj(constants[i].pvalue, constants[i].lvalue, *(constants[i].ptype));
        break;
      default:
        obj = 0;
        break;
      }
      if (obj) {
        PyDict_SetItemString(d, constants[i].name, obj);
        Py_DECREF(obj);
      }
    }
  }
  
  /* -----------------------------------------------------------------------------*/
  /* Fix SwigMethods to carry the callback ptrs when needed */
  /* -----------------------------------------------------------------------------*/
  
  SWIGINTERN void
  SWIG_Python_FixMethods(PyMethodDef *methods,
    swig_const_info *const_table,
    swig_type_info **types,
    swig_type_info **types_initial) {
    size_t i;
    for (i = 0; methods[i].ml_name; ++i) {
      const char *c = methods[i].ml_doc;
      if (!c) continue;
      c = strstr(c, "swig_ptr: ");
      if (c) {
        int j;
        swig_const_info *ci = 0;
        const char *name = c + 10;
        for (j = 0; const_table[j].type; ++j) {
          if (strncmp(const_table[j].name, name, 
              strlen(const_table[j].name)) == 0) {
            ci = &(const_table[j]);
            break;
          }
        }
        if (ci) {
          void *ptr = (ci->type == SWIG_PY_POINTER) ? ci->pvalue : 0;
          if (ptr) {
            size_t shift = (ci->ptype) - types;
            swig_type_info *ty = types_initial[shift];
            size_t ldoc = (c - methods[i].ml_doc);
            size_t lptr = strlen(ty->name)+2*sizeof(void*)+2;
            char *ndoc = (char*)malloc(ldoc + lptr + 10);
            if (ndoc) {
              char *buff = ndoc;
              memcpy(buff, methods[i].ml_doc, ldoc);
              buff += ldoc;
              memcpy(buff, "swig_ptr: ", 10);
              buff += 10;
              SWIG_PackVoidPtr(buff, ptr, ty->name, lptr);
              methods[i].ml_doc = ndoc;
            }
          }
        }
      }
    }
  } 
  
  /* -----------------------------------------------------------------------------
   * Method creation and docstring support functions
   * ----------------------------------------------------------------------------- */
  
  /* -----------------------------------------------------------------------------
   * Function to find the method definition with the correct docstring for the
   * proxy module as opposed to the low-level API
   * ----------------------------------------------------------------------------- */
  
  SWIGINTERN PyMethodDef *SWIG_PythonGetProxyDoc(const char *name) {
    /* Find the function in the modified method table */
    size_t offset = 0;
    int found = 0;
    while (SwigMethods_proxydocs[offset].ml_meth != NULL) {
      if (strcmp(SwigMethods_proxydocs[offset].ml_name, name) == 0) {
        found = 1;
        break;
      }
      offset++;
    }
    /* Use the copy with the modified docstring if available */
    return found ? &SwigMethods_proxydocs[offset] : NULL;
  }
  
  /* -----------------------------------------------------------------------------
   * Wrapper of PyInstanceMethod_New() used in Python 3
   * It is exported to the generated module, used for -fastproxy
   * ----------------------------------------------------------------------------- */
  
  SWIGINTERN PyObject *SWIG_PyInstanceMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func) {
    if (PyCFunction_Check(func)) {
      PyCFunctionObject *funcobj = (PyCFunctionObject *)func;
      PyMethodDef *ml = SWIG_PythonGetProxyDoc(funcobj->m_ml->ml_name);
      if (ml)
      func = PyCFunction_NewEx(ml, funcobj->m_self, funcobj->m_module);
    }
#if PY_VERSION_HEX >= 0x03000000
    return PyInstanceMethod_New(func);
#else
    return PyMethod_New(func, NULL, NULL);
#endif
  }
  
  /* -----------------------------------------------------------------------------
   * Wrapper of PyStaticMethod_New()
   * It is exported to the generated module, used for -fastproxy
   * ----------------------------------------------------------------------------- */
  
  SWIGINTERN PyObject *SWIG_PyStaticMethod_New(PyObject *SWIGUNUSEDPARM(self), PyObject *func) {
    if (PyCFunction_Check(func)) {
      PyCFunctionObject *funcobj = (PyCFunctionObject *)func;
      PyMethodDef *ml = SWIG_PythonGetProxyDoc(funcobj->m_ml->ml_name);
      if (ml)
      func = PyCFunction_NewEx(ml, funcobj->m_self, funcobj->m_module);
    }
    return PyStaticMethod_New(func);
  }
  
#ifdef __cplusplus
}
#endif

/* -----------------------------------------------------------------------------*
 *  Partial Init method
 * -----------------------------------------------------------------------------*/

#ifdef __cplusplus
extern "C"
#endif

SWIGEXPORT 
#if PY_VERSION_HEX >= 0x03000000
PyObject*
#else
void
#endif
SWIG_init(void) {
  PyObject *m, *d, *md, *globals;
  
#if PY_VERSION_HEX >= 0x03000000
  static struct PyModuleDef SWIG_module = {
    PyModuleDef_HEAD_INIT,
    SWIG_name,
    NULL,
    -1,
    SwigMethods,
    NULL,
    NULL,
    NULL,
    NULL
  };
#endif
  
#if defined(SWIGPYTHON_BUILTIN)
  static SwigPyClientData SwigPyObject_clientdata = {
    0, 0, 0, 0, 0, 0, 0
  };
  static PyGetSetDef this_getset_def = {
    (char *)"this", &SwigPyBuiltin_ThisClosure, NULL, NULL, NULL
  };
  static SwigPyGetSet thisown_getset_closure = {
    SwigPyObject_own,
    SwigPyObject_own
  };
  static PyGetSetDef thisown_getset_def = {
    (char *)"thisown", SwigPyBuiltin_GetterClosure, SwigPyBuiltin_SetterClosure, NULL, &thisown_getset_closure
  };
  PyTypeObject *builtin_pytype;
  int builtin_base_count;
  swig_type_info *builtin_basetype;
  PyObject *tuple;
  PyGetSetDescrObject *static_getset;
  PyTypeObject *metatype;
  PyTypeObject *swigpyobject;
  SwigPyClientData *cd;
  PyObject *public_interface, *public_symbol;
  PyObject *this_descr;
  PyObject *thisown_descr;
  PyObject *self = 0;
  int i;
  
  (void)builtin_pytype;
  (void)builtin_base_count;
  (void)builtin_basetype;
  (void)tuple;
  (void)static_getset;
  (void)self;
  
  /* Metaclass is used to implement static member variables */
  metatype = SwigPyObjectType();
  assert(metatype);
#endif
  
  (void)globals;
  
  /* Create singletons now to avoid potential deadlocks with multi-threaded usage after module initialization */
  SWIG_This();
  SWIG_Python_TypeCache();
  SwigPyPacked_type();
#ifndef SWIGPYTHON_BUILTIN
  SwigPyObject_type();
#endif
  
  /* Fix SwigMethods to carry the callback ptrs when needed */
  SWIG_Python_FixMethods(SwigMethods, swig_const_table, swig_types, swig_type_initial);
  
#if PY_VERSION_HEX >= 0x03000000
  m = PyModule_Create(&SWIG_module);
#else
  m = Py_InitModule(SWIG_name, SwigMethods);
#endif
  
  md = d = PyModule_GetDict(m);
  (void)md;
  
  SWIG_InitializeModule(0);
  
#ifdef SWIGPYTHON_BUILTIN
  swigpyobject = SwigPyObject_TypeOnce();
  
  SwigPyObject_stype = SWIG_MangledTypeQuery("_p_SwigPyObject");
  assert(SwigPyObject_stype);
  cd = (SwigPyClientData*) SwigPyObject_stype->clientdata;
  if (!cd) {
    SwigPyObject_stype->clientdata = &SwigPyObject_clientdata;
    SwigPyObject_clientdata.pytype = swigpyobject;
  } else if (swigpyobject->tp_basicsize != cd->pytype->tp_basicsize) {
    PyErr_SetString(PyExc_RuntimeError, "Import error: attempted to load two incompatible swig-generated modules.");
# if PY_VERSION_HEX >= 0x03000000
    return NULL;
# else
    return;
# endif
  }
  
  /* All objects have a 'this' attribute */
  this_descr = PyDescr_NewGetSet(SwigPyObject_type(), &this_getset_def);
  (void)this_descr;
  
  /* All objects have a 'thisown' attribute */
  thisown_descr = PyDescr_NewGetSet(SwigPyObject_type(), &thisown_getset_def);
  (void)thisown_descr;
  
  public_interface = PyList_New(0);
  public_symbol = 0;
  (void)public_symbol;
  
  PyDict_SetItemString(md, "__all__", public_interface);
  Py_DECREF(public_interface);
  for (i = 0; SwigMethods[i].ml_name != NULL; ++i)
  SwigPyBuiltin_AddPublicSymbol(public_interface, SwigMethods[i].ml_name);
  for (i = 0; swig_const_table[i].name != 0; ++i)
  SwigPyBuiltin_AddPublicSymbol(public_interface, swig_const_table[i].name);
#endif
  
  SWIG_InstallConstants(d,swig_const_table);
  
  SWIG_Python_SetConstant(d, "CREC",SWIG_From_char((char)('c')));
  SWIG_Python_SetConstant(d, "YREC",SWIG_From_char((char)('y')));
  SWIG_Python_SetConstant(d, "FREC",SWIG_From_char((char)('f')));
  SWIG_Python_SetConstant(d, "NREC",SWIG_From_char((char)('n')));
  SWIG_Python_SetConstant(d, "VREC",SWIG_From_char((char)('v')));
  SWIG_Python_SetConstant(d, "SPLIT_DATE_RECONCILED",SWIG_FromCharPtr("date-reconciled"));
  SWIG_Python_SetConstant(d, "SPLIT_BALANCE",SWIG_FromCharPtr("balance"));
  SWIG_Python_SetConstant(d, "SPLIT_CLEARED_BALANCE",SWIG_FromCharPtr("cleared-balance"));
  SWIG_Python_SetConstant(d, "SPLIT_RECONCILED_BALANCE",SWIG_FromCharPtr("reconciled-balance"));
  SWIG_Python_SetConstant(d, "SPLIT_MEMO",SWIG_FromCharPtr("memo"));
  SWIG_Python_SetConstant(d, "SPLIT_ACTION",SWIG_FromCharPtr("action"));
  SWIG_Python_SetConstant(d, "SPLIT_RECONCILE",SWIG_FromCharPtr("reconcile-flag"));
  SWIG_Python_SetConstant(d, "SPLIT_AMOUNT",SWIG_FromCharPtr("amount"));
  SWIG_Python_SetConstant(d, "SPLIT_SHARE_PRICE",SWIG_FromCharPtr("share-price"));
  SWIG_Python_SetConstant(d, "SPLIT_VALUE",SWIG_FromCharPtr("value"));
  SWIG_Python_SetConstant(d, "SPLIT_TYPE",SWIG_FromCharPtr("type"));
  SWIG_Python_SetConstant(d, "SPLIT_VOIDED_AMOUNT",SWIG_FromCharPtr("voided-amount"));
  SWIG_Python_SetConstant(d, "SPLIT_VOIDED_VALUE",SWIG_FromCharPtr("voided-value"));
  SWIG_Python_SetConstant(d, "SPLIT_LOT",SWIG_FromCharPtr("lot"));
  SWIG_Python_SetConstant(d, "SPLIT_TRANS",SWIG_FromCharPtr("trans"));
  SWIG_Python_SetConstant(d, "SPLIT_ACCOUNT",SWIG_FromCharPtr("account"));
  SWIG_Python_SetConstant(d, "SPLIT_ACCOUNT_GUID",SWIG_FromCharPtr("account-guid"));
  SWIG_Python_SetConstant(d, "SPLIT_ACCT_FULLNAME",SWIG_FromCharPtr("acct-fullname"));
  SWIG_Python_SetConstant(d, "SPLIT_CORR_ACCT_NAME",SWIG_FromCharPtr("corr-acct-fullname"));
  SWIG_Python_SetConstant(d, "SPLIT_CORR_ACCT_CODE",SWIG_FromCharPtr("corr-acct-code"));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_INVALID",SWIG_From_int((int)(ACCT_TYPE_INVALID)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_NONE",SWIG_From_int((int)(ACCT_TYPE_NONE)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_BANK",SWIG_From_int((int)(ACCT_TYPE_BANK)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_CASH",SWIG_From_int((int)(ACCT_TYPE_CASH)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_CREDIT",SWIG_From_int((int)(ACCT_TYPE_CREDIT)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_ASSET",SWIG_From_int((int)(ACCT_TYPE_ASSET)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_LIABILITY",SWIG_From_int((int)(ACCT_TYPE_LIABILITY)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_STOCK",SWIG_From_int((int)(ACCT_TYPE_STOCK)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_MUTUAL",SWIG_From_int((int)(ACCT_TYPE_MUTUAL)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_CURRENCY",SWIG_From_int((int)(ACCT_TYPE_CURRENCY)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_INCOME",SWIG_From_int((int)(ACCT_TYPE_INCOME)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_EXPENSE",SWIG_From_int((int)(ACCT_TYPE_EXPENSE)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_EQUITY",SWIG_From_int((int)(ACCT_TYPE_EQUITY)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_RECEIVABLE",SWIG_From_int((int)(ACCT_TYPE_RECEIVABLE)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_PAYABLE",SWIG_From_int((int)(ACCT_TYPE_PAYABLE)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_ROOT",SWIG_From_int((int)(ACCT_TYPE_ROOT)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_TRADING",SWIG_From_int((int)(ACCT_TYPE_TRADING)));
  SWIG_Python_SetConstant(d, "NUM_ACCOUNT_TYPES",SWIG_From_int((int)(NUM_ACCOUNT_TYPES)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_CHECKING",SWIG_From_int((int)(ACCT_TYPE_CHECKING)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_SAVINGS",SWIG_From_int((int)(ACCT_TYPE_SAVINGS)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_MONEYMRKT",SWIG_From_int((int)(ACCT_TYPE_MONEYMRKT)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_CREDITLINE",SWIG_From_int((int)(ACCT_TYPE_CREDITLINE)));
  SWIG_Python_SetConstant(d, "ACCT_TYPE_LAST",SWIG_From_int((int)(ACCT_TYPE_LAST)));
  SWIG_Python_SetConstant(d, "PLACEHOLDER_NONE",SWIG_From_int((int)(PLACEHOLDER_NONE)));
  SWIG_Python_SetConstant(d, "PLACEHOLDER_THIS",SWIG_From_int((int)(PLACEHOLDER_THIS)));
  SWIG_Python_SetConstant(d, "PLACEHOLDER_CHILD",SWIG_From_int((int)(PLACEHOLDER_CHILD)));
  SWIG_Python_SetConstant(d, "ACCOUNT_KVP",SWIG_FromCharPtr("kvp"));
  SWIG_Python_SetConstant(d, "ACCOUNT_NAME_",SWIG_FromCharPtr("name"));
  SWIG_Python_SetConstant(d, "ACCOUNT_CODE_",SWIG_FromCharPtr("code"));
  SWIG_Python_SetConstant(d, "ACCOUNT_DESCRIPTION_",SWIG_FromCharPtr("desc"));
  SWIG_Python_SetConstant(d, "ACCOUNT_COLOR_",SWIG_FromCharPtr("color"));
  SWIG_Python_SetConstant(d, "ACCOUNT_FILTER_",SWIG_FromCharPtr("filter"));
  SWIG_Python_SetConstant(d, "ACCOUNT_SORT_ORDER_",SWIG_FromCharPtr("sort-order"));
  SWIG_Python_SetConstant(d, "ACCOUNT_SORT_REVERSED_",SWIG_FromCharPtr("sort-reversed"));
  SWIG_Python_SetConstant(d, "ACCOUNT_NOTES_",SWIG_FromCharPtr("notes"));
  SWIG_Python_SetConstant(d, "ACCOUNT_BALANCE_",SWIG_FromCharPtr("balance"));
  SWIG_Python_SetConstant(d, "ACCOUNT_NOCLOSING_",SWIG_FromCharPtr("noclosing"));
  SWIG_Python_SetConstant(d, "ACCOUNT_CLEARED_",SWIG_FromCharPtr("cleared"));
  SWIG_Python_SetConstant(d, "ACCOUNT_RECONCILED_",SWIG_FromCharPtr("reconciled"));
  SWIG_Python_SetConstant(d, "ACCOUNT_PRESENT_",SWIG_FromCharPtr("present"));
  SWIG_Python_SetConstant(d, "ACCOUNT_FUTURE_MINIMUM_",SWIG_FromCharPtr("future-minimum"));
  SWIG_Python_SetConstant(d, "ACCOUNT_TAX_RELATED",SWIG_FromCharPtr("tax-related-p"));
  SWIG_Python_SetConstant(d, "ACCOUNT_TYPE_",SWIG_FromCharPtr("account-type"));
  SWIG_Python_SetConstant(d, "ACCOUNT_SCU",SWIG_FromCharPtr("smallest-commodity-unit"));
  SWIG_Python_SetConstant(d, "ACCOUNT_NSCU",SWIG_FromCharPtr("non-standard-scu"));
  SWIG_Python_SetConstant(d, "ACCOUNT_PARENT",SWIG_FromCharPtr("parent-account"));
  SWIG_Python_SetConstant(d, "ACCOUNT_MATCH_ALL_TYPE",SWIG_FromCharPtr("account-match-all"));
  SWIG_Python_SetConstant(d, "TXN_TYPE_NONE",SWIG_From_char((char)('\0')));
  SWIG_Python_SetConstant(d, "TXN_TYPE_INVOICE",SWIG_From_char((char)('I')));
  SWIG_Python_SetConstant(d, "TXN_TYPE_PAYMENT",SWIG_From_char((char)('P')));
  SWIG_Python_SetConstant(d, "TXN_TYPE_LINK",SWIG_From_char((char)('L')));
  SWIG_Python_SetConstant(d, "TRANS_KVP",SWIG_FromCharPtr("kvp"));
  SWIG_Python_SetConstant(d, "TRANS_NUM",SWIG_FromCharPtr("num"));
  SWIG_Python_SetConstant(d, "TRANS_DESCRIPTION",SWIG_FromCharPtr("desc"));
  SWIG_Python_SetConstant(d, "TRANS_DATE_ENTERED",SWIG_FromCharPtr("date-entered"));
  SWIG_Python_SetConstant(d, "TRANS_DATE_POSTED",SWIG_FromCharPtr("date-posted"));
  SWIG_Python_SetConstant(d, "TRANS_DATE_DUE",SWIG_FromCharPtr("date-due"));
  SWIG_Python_SetConstant(d, "TRANS_IMBALANCE",SWIG_FromCharPtr("trans-imbalance"));
  SWIG_Python_SetConstant(d, "TRANS_IS_BALANCED",SWIG_FromCharPtr("trans-balanced?"));
  SWIG_Python_SetConstant(d, "TRANS_IS_CLOSING",SWIG_FromCharPtr("trans-is-closing?"));
  SWIG_Python_SetConstant(d, "TRANS_NOTES",SWIG_FromCharPtr("notes"));
  SWIG_Python_SetConstant(d, "TRANS_ASSOCIATION",SWIG_FromCharPtr("assoc"));
  SWIG_Python_SetConstant(d, "TRANS_TYPE",SWIG_FromCharPtr("type"));
  SWIG_Python_SetConstant(d, "TRANS_VOID_STATUS",SWIG_FromCharPtr("void-p"));
  SWIG_Python_SetConstant(d, "TRANS_VOID_REASON",SWIG_FromCharPtr("void-reason"));
  SWIG_Python_SetConstant(d, "TRANS_VOID_TIME",SWIG_FromCharPtr("void-time"));
  SWIG_Python_SetConstant(d, "TRANS_SPLITLIST",SWIG_FromCharPtr("split-list"));
  SWIG_Python_SetConstant(d, "RECONCILED_MATCH_TYPE",SWIG_FromCharPtr("reconciled-match"));
  SWIG_Python_SetConstant(d, "LOT_IS_CLOSED",SWIG_FromCharPtr("is-closed?"));
  SWIG_Python_SetConstant(d, "LOT_BALANCE",SWIG_FromCharPtr("balance"));
  SWIG_Python_SetConstant(d, "LOT_TITLE",SWIG_FromCharPtr("lot-title"));
  SWIG_Python_SetConstant(d, "LOT_NOTES",SWIG_FromCharPtr("notes"));
  SWIG_Python_SetConstant(d, "QOF_MOD_BACKEND",SWIG_FromCharPtr("qof.backend"));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_NO_ERR",SWIG_From_int((int)(ERR_BACKEND_NO_ERR)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_NO_HANDLER",SWIG_From_int((int)(ERR_BACKEND_NO_HANDLER)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_NO_BACKEND",SWIG_From_int((int)(ERR_BACKEND_NO_BACKEND)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_BAD_URL",SWIG_From_int((int)(ERR_BACKEND_BAD_URL)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_NO_SUCH_DB",SWIG_From_int((int)(ERR_BACKEND_NO_SUCH_DB)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_CANT_CONNECT",SWIG_From_int((int)(ERR_BACKEND_CANT_CONNECT)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_CONN_LOST",SWIG_From_int((int)(ERR_BACKEND_CONN_LOST)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_LOCKED",SWIG_From_int((int)(ERR_BACKEND_LOCKED)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_STORE_EXISTS",SWIG_From_int((int)(ERR_BACKEND_STORE_EXISTS)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_READONLY",SWIG_From_int((int)(ERR_BACKEND_READONLY)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_TOO_NEW",SWIG_From_int((int)(ERR_BACKEND_TOO_NEW)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_DATA_CORRUPT",SWIG_From_int((int)(ERR_BACKEND_DATA_CORRUPT)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_SERVER_ERR",SWIG_From_int((int)(ERR_BACKEND_SERVER_ERR)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_ALLOC",SWIG_From_int((int)(ERR_BACKEND_ALLOC)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_PERM",SWIG_From_int((int)(ERR_BACKEND_PERM)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_MODIFIED",SWIG_From_int((int)(ERR_BACKEND_MODIFIED)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_MOD_DESTROY",SWIG_From_int((int)(ERR_BACKEND_MOD_DESTROY)));
  SWIG_Python_SetConstant(d, "ERR_BACKEND_MISC",SWIG_From_int((int)(ERR_BACKEND_MISC)));
  SWIG_Python_SetConstant(d, "ERR_QOF_OVERFLOW",SWIG_From_int((int)(ERR_QOF_OVERFLOW)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_FILE_BAD_READ",SWIG_From_int((int)(ERR_FILEIO_FILE_BAD_READ)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_FILE_EMPTY",SWIG_From_int((int)(ERR_FILEIO_FILE_EMPTY)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_FILE_LOCKERR",SWIG_From_int((int)(ERR_FILEIO_FILE_LOCKERR)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_FILE_NOT_FOUND",SWIG_From_int((int)(ERR_FILEIO_FILE_NOT_FOUND)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_FILE_TOO_OLD",SWIG_From_int((int)(ERR_FILEIO_FILE_TOO_OLD)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_UNKNOWN_FILE_TYPE",SWIG_From_int((int)(ERR_FILEIO_UNKNOWN_FILE_TYPE)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_PARSE_ERROR",SWIG_From_int((int)(ERR_FILEIO_PARSE_ERROR)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_BACKUP_ERROR",SWIG_From_int((int)(ERR_FILEIO_BACKUP_ERROR)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_WRITE_ERROR",SWIG_From_int((int)(ERR_FILEIO_WRITE_ERROR)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_READ_ERROR",SWIG_From_int((int)(ERR_FILEIO_READ_ERROR)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_NO_ENCODING",SWIG_From_int((int)(ERR_FILEIO_NO_ENCODING)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_FILE_EACCES",SWIG_From_int((int)(ERR_FILEIO_FILE_EACCES)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_RESERVED_WRITE",SWIG_From_int((int)(ERR_FILEIO_RESERVED_WRITE)));
  SWIG_Python_SetConstant(d, "ERR_FILEIO_FILE_UPGRADE",SWIG_From_int((int)(ERR_FILEIO_FILE_UPGRADE)));
  SWIG_Python_SetConstant(d, "ERR_NETIO_SHORT_READ",SWIG_From_int((int)(ERR_NETIO_SHORT_READ)));
  SWIG_Python_SetConstant(d, "ERR_NETIO_WRONG_CONTENT_TYPE",SWIG_From_int((int)(ERR_NETIO_WRONG_CONTENT_TYPE)));
  SWIG_Python_SetConstant(d, "ERR_NETIO_NOT_GNCXML",SWIG_From_int((int)(ERR_NETIO_NOT_GNCXML)));
  SWIG_Python_SetConstant(d, "ERR_SQL_MISSING_DATA",SWIG_From_int((int)(ERR_SQL_MISSING_DATA)));
  SWIG_Python_SetConstant(d, "ERR_SQL_DB_TOO_OLD",SWIG_From_int((int)(ERR_SQL_DB_TOO_OLD)));
  SWIG_Python_SetConstant(d, "ERR_SQL_DB_TOO_NEW",SWIG_From_int((int)(ERR_SQL_DB_TOO_NEW)));
  SWIG_Python_SetConstant(d, "ERR_SQL_DB_BUSY",SWIG_From_int((int)(ERR_SQL_DB_BUSY)));
  SWIG_Python_SetConstant(d, "ERR_SQL_BAD_DBI",SWIG_From_int((int)(ERR_SQL_BAD_DBI)));
  SWIG_Python_SetConstant(d, "ERR_SQL_DBI_UNTESTABLE",SWIG_From_int((int)(ERR_SQL_DBI_UNTESTABLE)));
  SWIG_Python_SetConstant(d, "ERR_RPC_HOST_UNK",SWIG_From_int((int)(ERR_RPC_HOST_UNK)));
  SWIG_Python_SetConstant(d, "ERR_RPC_CANT_BIND",SWIG_From_int((int)(ERR_RPC_CANT_BIND)));
  SWIG_Python_SetConstant(d, "ERR_RPC_CANT_ACCEPT",SWIG_From_int((int)(ERR_RPC_CANT_ACCEPT)));
  SWIG_Python_SetConstant(d, "ERR_RPC_NO_CONNECTION",SWIG_From_int((int)(ERR_RPC_NO_CONNECTION)));
  SWIG_Python_SetConstant(d, "ERR_RPC_BAD_VERSION",SWIG_From_int((int)(ERR_RPC_BAD_VERSION)));
  SWIG_Python_SetConstant(d, "ERR_RPC_FAILED",SWIG_From_int((int)(ERR_RPC_FAILED)));
  SWIG_Python_SetConstant(d, "ERR_RPC_NOT_ADDED",SWIG_From_int((int)(ERR_RPC_NOT_ADDED)));
  SWIG_Python_SetConstant(d, "QOF_MOD_SESSION",SWIG_FromCharPtr("qof.session"));
  SWIG_Python_SetConstant(d, "QOF_STDOUT",SWIG_FromCharPtr(">"));
  SWIG_Python_SetConstant(d, "QOF_ID_NULL",SWIG_FromCharPtr("null"));
  SWIG_Python_SetConstant(d, "QOF_ID_BOOK",SWIG_FromCharPtr("Book"));
  SWIG_Python_SetConstant(d, "QOF_ID_SESSION",SWIG_FromCharPtr("Session"));
  SWIG_Python_SetConstant(d, "QOF_MOD_QUERY",SWIG_FromCharPtr("qof.query"));
  SWIG_Python_SetConstant(d, "QOF_QUERY_AND",SWIG_From_int((int)(QOF_QUERY_AND)));
  SWIG_Python_SetConstant(d, "QOF_QUERY_OR",SWIG_From_int((int)(QOF_QUERY_OR)));
  SWIG_Python_SetConstant(d, "QOF_QUERY_NAND",SWIG_From_int((int)(QOF_QUERY_NAND)));
  SWIG_Python_SetConstant(d, "QOF_QUERY_NOR",SWIG_From_int((int)(QOF_QUERY_NOR)));
  SWIG_Python_SetConstant(d, "QOF_QUERY_XOR",SWIG_From_int((int)(QOF_QUERY_XOR)));
  SWIG_Python_SetConstant(d, "QUERY_DEFAULT_SORT",SWIG_FromCharPtr("QofQueryDefaultSort"));
  SWIG_Python_SetConstant(d, "QOF_PARAM_BOOK",SWIG_FromCharPtr("book"));
  SWIG_Python_SetConstant(d, "QOF_PARAM_GUID",SWIG_FromCharPtr("guid"));
  SWIG_Python_SetConstant(d, "QOF_PARAM_KVP",SWIG_FromCharPtr("kvp"));
  SWIG_Python_SetConstant(d, "QOF_PARAM_ACTIVE",SWIG_FromCharPtr("active"));
  SWIG_Python_SetConstant(d, "QOF_PARAM_VERSION",SWIG_FromCharPtr("version"));
  SWIG_Python_SetConstant(d, "QOF_COMPARE_LT",SWIG_From_int((int)(QOF_COMPARE_LT)));
  SWIG_Python_SetConstant(d, "QOF_COMPARE_LTE",SWIG_From_int((int)(QOF_COMPARE_LTE)));
  SWIG_Python_SetConstant(d, "QOF_COMPARE_EQUAL",SWIG_From_int((int)(QOF_COMPARE_EQUAL)));
  SWIG_Python_SetConstant(d, "QOF_COMPARE_GT",SWIG_From_int((int)(QOF_COMPARE_GT)));
  SWIG_Python_SetConstant(d, "QOF_COMPARE_GTE",SWIG_From_int((int)(QOF_COMPARE_GTE)));
  SWIG_Python_SetConstant(d, "QOF_COMPARE_NEQ",SWIG_From_int((int)(QOF_COMPARE_NEQ)));
  SWIG_Python_SetConstant(d, "QOF_COMPARE_CONTAINS",SWIG_From_int((int)(QOF_COMPARE_CONTAINS)));
  SWIG_Python_SetConstant(d, "QOF_COMPARE_NCONTAINS",SWIG_From_int((int)(QOF_COMPARE_NCONTAINS)));
  SWIG_Python_SetConstant(d, "QOF_STRING_MATCH_NORMAL",SWIG_From_int((int)(QOF_STRING_MATCH_NORMAL)));
  SWIG_Python_SetConstant(d, "QOF_STRING_MATCH_CASEINSENSITIVE",SWIG_From_int((int)(QOF_STRING_MATCH_CASEINSENSITIVE)));
  SWIG_Python_SetConstant(d, "QOF_DATE_MATCH_NORMAL",SWIG_From_int((int)(QOF_DATE_MATCH_NORMAL)));
  SWIG_Python_SetConstant(d, "QOF_DATE_MATCH_DAY",SWIG_From_int((int)(QOF_DATE_MATCH_DAY)));
  SWIG_Python_SetConstant(d, "QOF_NUMERIC_MATCH_DEBIT",SWIG_From_int((int)(QOF_NUMERIC_MATCH_DEBIT)));
  SWIG_Python_SetConstant(d, "QOF_NUMERIC_MATCH_CREDIT",SWIG_From_int((int)(QOF_NUMERIC_MATCH_CREDIT)));
  SWIG_Python_SetConstant(d, "QOF_NUMERIC_MATCH_ANY",SWIG_From_int((int)(QOF_NUMERIC_MATCH_ANY)));
  SWIG_Python_SetConstant(d, "QOF_GUID_MATCH_ANY",SWIG_From_int((int)(QOF_GUID_MATCH_ANY)));
  SWIG_Python_SetConstant(d, "QOF_GUID_MATCH_NONE",SWIG_From_int((int)(QOF_GUID_MATCH_NONE)));
  SWIG_Python_SetConstant(d, "QOF_GUID_MATCH_NULL",SWIG_From_int((int)(QOF_GUID_MATCH_NULL)));
  SWIG_Python_SetConstant(d, "QOF_GUID_MATCH_ALL",SWIG_From_int((int)(QOF_GUID_MATCH_ALL)));
  SWIG_Python_SetConstant(d, "QOF_GUID_MATCH_LIST_ANY",SWIG_From_int((int)(QOF_GUID_MATCH_LIST_ANY)));
  SWIG_Python_SetConstant(d, "QOF_CHAR_MATCH_ANY",SWIG_From_int((int)(QOF_CHAR_MATCH_ANY)));
  SWIG_Python_SetConstant(d, "QOF_CHAR_MATCH_NONE",SWIG_From_int((int)(QOF_CHAR_MATCH_NONE)));
  SWIG_Python_SetConstant(d, "GUID_DATA_SIZE",SWIG_From_int((int)(16)));
  SWIG_Python_SetConstant(d, "GUID_ENCODING_LENGTH",SWIG_From_int((int)(32)));
  SWIG_Python_SetConstant(d, "GNC_NUMERIC_RND_MASK",SWIG_From_int((int)(0x0000000f)));
  SWIG_Python_SetConstant(d, "GNC_NUMERIC_DENOM_MASK",SWIG_From_int((int)(0x000000f0)));
  SWIG_Python_SetConstant(d, "GNC_NUMERIC_SIGFIGS_MASK",SWIG_From_int((int)(0x0000ff00)));
  SWIG_Python_SetConstant(d, "GNC_HOW_RND_FLOOR",SWIG_From_int((int)(GNC_HOW_RND_FLOOR)));
  SWIG_Python_SetConstant(d, "GNC_HOW_RND_CEIL",SWIG_From_int((int)(GNC_HOW_RND_CEIL)));
  SWIG_Python_SetConstant(d, "GNC_HOW_RND_TRUNC",SWIG_From_int((int)(GNC_HOW_RND_TRUNC)));
  SWIG_Python_SetConstant(d, "GNC_HOW_RND_PROMOTE",SWIG_From_int((int)(GNC_HOW_RND_PROMOTE)));
  SWIG_Python_SetConstant(d, "GNC_HOW_RND_ROUND_HALF_DOWN",SWIG_From_int((int)(GNC_HOW_RND_ROUND_HALF_DOWN)));
  SWIG_Python_SetConstant(d, "GNC_HOW_RND_ROUND_HALF_UP",SWIG_From_int((int)(GNC_HOW_RND_ROUND_HALF_UP)));
  SWIG_Python_SetConstant(d, "GNC_HOW_RND_ROUND",SWIG_From_int((int)(GNC_HOW_RND_ROUND)));
  SWIG_Python_SetConstant(d, "GNC_HOW_RND_NEVER",SWIG_From_int((int)(GNC_HOW_RND_NEVER)));
  SWIG_Python_SetConstant(d, "GNC_HOW_DENOM_EXACT",SWIG_From_int((int)(GNC_HOW_DENOM_EXACT)));
  SWIG_Python_SetConstant(d, "GNC_HOW_DENOM_REDUCE",SWIG_From_int((int)(GNC_HOW_DENOM_REDUCE)));
  SWIG_Python_SetConstant(d, "GNC_HOW_DENOM_LCD",SWIG_From_int((int)(GNC_HOW_DENOM_LCD)));
  SWIG_Python_SetConstant(d, "GNC_HOW_DENOM_FIXED",SWIG_From_int((int)(GNC_HOW_DENOM_FIXED)));
  SWIG_Python_SetConstant(d, "GNC_HOW_DENOM_SIGFIG",SWIG_From_int((int)(GNC_HOW_DENOM_SIGFIG)));
  SWIG_Python_SetConstant(d, "GNC_ERROR_OK",SWIG_From_int((int)(GNC_ERROR_OK)));
  SWIG_Python_SetConstant(d, "GNC_ERROR_ARG",SWIG_From_int((int)(GNC_ERROR_ARG)));
  SWIG_Python_SetConstant(d, "GNC_ERROR_OVERFLOW",SWIG_From_int((int)(GNC_ERROR_OVERFLOW)));
  SWIG_Python_SetConstant(d, "GNC_ERROR_DENOM_DIFF",SWIG_From_int((int)(GNC_ERROR_DENOM_DIFF)));
  SWIG_Python_SetConstant(d, "GNC_ERROR_REMAINDER",SWIG_From_int((int)(GNC_ERROR_REMAINDER)));
  SWIG_Python_SetConstant(d, "GNC_DENOM_AUTO",SWIG_From_int((int)(0)));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_TABLE",SWIG_FromCharPtr("gnc_commodity_table"));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_NS_LEGACY",SWIG_FromCharPtr("GNC_LEGACY_CURRENCIES"));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_NS_TEMPLATE",SWIG_FromCharPtr("template"));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_NS_ISO",SWIG_FromCharPtr("ISO4217"));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_NS_CURRENCY",SWIG_FromCharPtr("CURRENCY"));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_NS_NASDAQ",SWIG_FromCharPtr("NASDAQ"));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_NS_NYSE",SWIG_FromCharPtr("NYSE"));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_NS_EUREX",SWIG_FromCharPtr("EUREX"));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_NS_MUTUAL",SWIG_FromCharPtr("FUND"));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_NS_AMEX",SWIG_FromCharPtr("AMEX"));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_NS_ASX",SWIG_FromCharPtr("ASX"));
  SWIG_Python_SetConstant(d, "GNC_COMMODITY_MAX_FRACTION",SWIG_From_int((int)(1000000000)));
  SWIG_Python_SetConstant(d, "SOURCE_SINGLE",SWIG_From_int((int)(SOURCE_SINGLE)));
  SWIG_Python_SetConstant(d, "SOURCE_MULTI",SWIG_From_int((int)(SOURCE_MULTI)));
  SWIG_Python_SetConstant(d, "SOURCE_UNKNOWN",SWIG_From_int((int)(SOURCE_UNKNOWN)));
  SWIG_Python_SetConstant(d, "SOURCE_MAX",SWIG_From_int((int)(SOURCE_MAX)));
  SWIG_Python_SetConstant(d, "SOURCE_CURRENCY",SWIG_From_int((int)(SOURCE_CURRENCY)));
  SWIG_Python_SetConstant(d, "GNC_ID_OWNER",SWIG_FromCharPtr("gncOwner"));
  SWIG_Python_SetConstant(d, "GNC_OWNER_NONE",SWIG_From_int((int)(GNC_OWNER_NONE)));
  SWIG_Python_SetConstant(d, "GNC_OWNER_UNDEFINED",SWIG_From_int((int)(GNC_OWNER_UNDEFINED)));
  SWIG_Python_SetConstant(d, "GNC_OWNER_CUSTOMER",SWIG_From_int((int)(GNC_OWNER_CUSTOMER)));
  SWIG_Python_SetConstant(d, "GNC_OWNER_JOB",SWIG_From_int((int)(GNC_OWNER_JOB)));
  SWIG_Python_SetConstant(d, "GNC_OWNER_VENDOR",SWIG_From_int((int)(GNC_OWNER_VENDOR)));
  SWIG_Python_SetConstant(d, "GNC_OWNER_EMPLOYEE",SWIG_From_int((int)(GNC_OWNER_EMPLOYEE)));
  SWIG_Python_SetConstant(d, "OWNER_TYPE",SWIG_FromCharPtr("type"));
  SWIG_Python_SetConstant(d, "OWNER_TYPE_STRING",SWIG_FromCharPtr("type-string"));
  SWIG_Python_SetConstant(d, "OWNER_CUSTOMER",SWIG_FromCharPtr("customer"));
  SWIG_Python_SetConstant(d, "OWNER_JOB",SWIG_FromCharPtr("job"));
  SWIG_Python_SetConstant(d, "OWNER_VENDOR",SWIG_FromCharPtr("vendor"));
  SWIG_Python_SetConstant(d, "OWNER_EMPLOYEE",SWIG_FromCharPtr("employee"));
  SWIG_Python_SetConstant(d, "OWNER_PARENT",SWIG_FromCharPtr("parent"));
  SWIG_Python_SetConstant(d, "OWNER_PARENTG",SWIG_FromCharPtr("parent-guid"));
  SWIG_Python_SetConstant(d, "OWNER_NAME",SWIG_FromCharPtr("name"));
  SWIG_Python_SetConstant(d, "OWNER_FROM_LOT",SWIG_FromCharPtr("owner-from-lot"));
  SWIG_Python_SetConstant(d, "GNC_ID_CUSTOMER",SWIG_FromCharPtr("gncCustomer"));
  SWIG_Python_SetConstant(d, "CUSTOMER_ID",SWIG_FromCharPtr("id"));
  SWIG_Python_SetConstant(d, "CUSTOMER_NAME",SWIG_FromCharPtr("name"));
  SWIG_Python_SetConstant(d, "CUSTOMER_ADDR",SWIG_FromCharPtr("addr"));
  SWIG_Python_SetConstant(d, "CUSTOMER_SHIPADDR",SWIG_FromCharPtr("shipaddr"));
  SWIG_Python_SetConstant(d, "CUSTOMER_NOTES",SWIG_FromCharPtr("notes"));
  SWIG_Python_SetConstant(d, "CUSTOMER_DISCOUNT",SWIG_FromCharPtr("amount of discount"));
  SWIG_Python_SetConstant(d, "CUSTOMER_CREDIT",SWIG_FromCharPtr("amount of credit"));
  SWIG_Python_SetConstant(d, "CUSTOMER_TT_OVER",SWIG_FromCharPtr("tax table override"));
  SWIG_Python_SetConstant(d, "CUSTOMER_TAX_INC",SWIG_FromCharPtr("customer_tax_included"));
  SWIG_Python_SetConstant(d, "CUSTOMER_TERMS",SWIG_FromCharPtr("customer_terms"));
  SWIG_Python_SetConstant(d, "CUSTOMER_ACTIVE",SWIG_FromCharPtr("customer_is_active"));
  SWIG_Python_SetConstant(d, "CUSTOMER_SLOTS",SWIG_FromCharPtr("customer_values"));
  SWIG_Python_SetConstant(d, "GNC_ID_EMPLOYEE",SWIG_FromCharPtr("gncEmployee"));
  SWIG_Python_SetConstant(d, "EMPLOYEE_ID",SWIG_FromCharPtr("id"));
  SWIG_Python_SetConstant(d, "EMPLOYEE_USERNAME",SWIG_FromCharPtr("username"));
  SWIG_Python_SetConstant(d, "EMPLOYEE_NAME",SWIG_FromCharPtr("name"));
  SWIG_Python_SetConstant(d, "EMPLOYEE_ADDR",SWIG_FromCharPtr("addr"));
  SWIG_Python_SetConstant(d, "EMPLOYEE_LANGUAGE",SWIG_FromCharPtr("native language"));
  SWIG_Python_SetConstant(d, "EMPLOYEE_ACL",SWIG_FromCharPtr("acl"));
  SWIG_Python_SetConstant(d, "EMPLOYEE_WORKDAY",SWIG_FromCharPtr("workday"));
  SWIG_Python_SetConstant(d, "EMPLOYEE_RATE",SWIG_FromCharPtr("rate"));
  SWIG_Python_SetConstant(d, "EMPLOYEE_CC",SWIG_FromCharPtr("credit_card_account"));
  SWIG_Python_SetConstant(d, "GNC_ID_VENDOR",SWIG_FromCharPtr("gncVendor"));
  SWIG_Python_SetConstant(d, "VENDOR_ID",SWIG_FromCharPtr("id"));
  SWIG_Python_SetConstant(d, "VENDOR_NAME",SWIG_FromCharPtr("name"));
  SWIG_Python_SetConstant(d, "VENDOR_ADDR",SWIG_FromCharPtr("addr"));
  SWIG_Python_SetConstant(d, "VENDOR_NOTES",SWIG_FromCharPtr("vendor_notes"));
  SWIG_Python_SetConstant(d, "VENDOR_TERMS",SWIG_FromCharPtr("vendor_terms"));
  SWIG_Python_SetConstant(d, "VENDOR_TAX_INC",SWIG_FromCharPtr("vendor_tax_included"));
  SWIG_Python_SetConstant(d, "VENDOR_ACTIVE",SWIG_FromCharPtr("vendor_is_active"));
  SWIG_Python_SetConstant(d, "VENDOR_TAX_OVERRIDE",SWIG_FromCharPtr("override_tax_table"));
  SWIG_Python_SetConstant(d, "VENDOR_TAX_TABLE",SWIG_FromCharPtr("vendor_tax_table"));
  SWIG_Python_SetConstant(d, "GNC_ADDRESS_MODULE_NAME",SWIG_FromCharPtr("gncAddress"));
  SWIG_Python_SetConstant(d, "GNC_ID_ADDRESS",SWIG_FromCharPtr("gncAddress"));
  SWIG_Python_SetConstant(d, "ADDRESS_NAME",SWIG_FromCharPtr("name"));
  SWIG_Python_SetConstant(d, "ADDRESS_ONE",SWIG_FromCharPtr("number"));
  SWIG_Python_SetConstant(d, "ADDRESS_TWO",SWIG_FromCharPtr("street"));
  SWIG_Python_SetConstant(d, "ADDRESS_THREE",SWIG_FromCharPtr("locality"));
  SWIG_Python_SetConstant(d, "ADDRESS_FOUR",SWIG_FromCharPtr("city"));
  SWIG_Python_SetConstant(d, "ADDRESS_PHONE",SWIG_FromCharPtr("phone"));
  SWIG_Python_SetConstant(d, "ADDRESS_FAX",SWIG_FromCharPtr("fax"));
  SWIG_Python_SetConstant(d, "ADDRESS_EMAIL",SWIG_FromCharPtr("email"));
  SWIG_Python_SetConstant(d, "ADDRESS_OWNER",SWIG_FromCharPtr("owner"));
  SWIG_Python_SetConstant(d, "GNC_ID_BILLTERM",SWIG_FromCharPtr("gncBillTerm"));
  SWIG_Python_SetConstant(d, "GNC_BILLTERM_NAME",SWIG_FromCharPtr("name"));
  SWIG_Python_SetConstant(d, "GNC_BILLTERM_DESC",SWIG_FromCharPtr("description"));
  SWIG_Python_SetConstant(d, "GNC_BILLTERM_DUEDAYS",SWIG_FromCharPtr("number of days due"));
  SWIG_Python_SetConstant(d, "GNC_BILLTERM_DISCDAYS",SWIG_FromCharPtr("number of discounted days"));
  SWIG_Python_SetConstant(d, "GNC_BILLTERM_CUTOFF",SWIG_FromCharPtr("cut off"));
  SWIG_Python_SetConstant(d, "GNC_BILLTERM_TYPE",SWIG_FromCharPtr("bill type"));
  SWIG_Python_SetConstant(d, "GNC_BILLTERM_DISCOUNT",SWIG_FromCharPtr("amount of discount"));
  SWIG_Python_SetConstant(d, "GNC_BILLTERM_REFCOUNT",SWIG_FromCharPtr("reference count"));
  SWIG_Python_SetConstant(d, "GNC_TERM_TYPE_DAYS",SWIG_From_int((int)(GNC_TERM_TYPE_DAYS)));
  SWIG_Python_SetConstant(d, "GNC_TERM_TYPE_PROXIMO",SWIG_From_int((int)(GNC_TERM_TYPE_PROXIMO)));
  SWIG_Python_SetConstant(d, "GNC_ID_INVOICE",SWIG_FromCharPtr("gncInvoice"));
  SWIG_Python_SetConstant(d, "GNC_INVOICE_UNDEFINED",SWIG_From_int((int)(GNC_INVOICE_UNDEFINED)));
  SWIG_Python_SetConstant(d, "GNC_INVOICE_CUST_INVOICE",SWIG_From_int((int)(GNC_INVOICE_CUST_INVOICE)));
  SWIG_Python_SetConstant(d, "GNC_INVOICE_VEND_INVOICE",SWIG_From_int((int)(GNC_INVOICE_VEND_INVOICE)));
  SWIG_Python_SetConstant(d, "GNC_INVOICE_EMPL_INVOICE",SWIG_From_int((int)(GNC_INVOICE_EMPL_INVOICE)));
  SWIG_Python_SetConstant(d, "GNC_INVOICE_CUST_CREDIT_NOTE",SWIG_From_int((int)(GNC_INVOICE_CUST_CREDIT_NOTE)));
  SWIG_Python_SetConstant(d, "GNC_INVOICE_VEND_CREDIT_NOTE",SWIG_From_int((int)(GNC_INVOICE_VEND_CREDIT_NOTE)));
  SWIG_Python_SetConstant(d, "GNC_INVOICE_EMPL_CREDIT_NOTE",SWIG_From_int((int)(GNC_INVOICE_EMPL_CREDIT_NOTE)));
  SWIG_Python_SetConstant(d, "GNC_INVOICE_NUM_TYPES",SWIG_From_int((int)(GNC_INVOICE_NUM_TYPES)));
  SWIG_Python_SetConstant(d, "INVOICE_ID",SWIG_FromCharPtr("id"));
  SWIG_Python_SetConstant(d, "INVOICE_OWNER",SWIG_FromCharPtr("owner"));
  SWIG_Python_SetConstant(d, "INVOICE_OPENED",SWIG_FromCharPtr("date_opened"));
  SWIG_Python_SetConstant(d, "INVOICE_POSTED",SWIG_FromCharPtr("date_posted"));
  SWIG_Python_SetConstant(d, "INVOICE_DUE",SWIG_FromCharPtr("date_due"));
  SWIG_Python_SetConstant(d, "INVOICE_IS_POSTED",SWIG_FromCharPtr("is_posted?"));
  SWIG_Python_SetConstant(d, "INVOICE_IS_PAID",SWIG_FromCharPtr("is_paid?"));
  SWIG_Python_SetConstant(d, "INVOICE_TERMS",SWIG_FromCharPtr("terms"));
  SWIG_Python_SetConstant(d, "INVOICE_BILLINGID",SWIG_FromCharPtr("billing_id"));
  SWIG_Python_SetConstant(d, "INVOICE_NOTES",SWIG_FromCharPtr("notes"));
  SWIG_Python_SetConstant(d, "INVOICE_ACC",SWIG_FromCharPtr("account"));
  SWIG_Python_SetConstant(d, "INVOICE_POST_TXN",SWIG_FromCharPtr("posted_txn"));
  SWIG_Python_SetConstant(d, "INVOICE_POST_LOT",SWIG_FromCharPtr("posted_lot"));
  SWIG_Python_SetConstant(d, "INVOICE_IS_CN",SWIG_FromCharPtr("credit_note"));
  SWIG_Python_SetConstant(d, "INVOICE_TYPE",SWIG_FromCharPtr("type"));
  SWIG_Python_SetConstant(d, "INVOICE_TYPE_STRING",SWIG_FromCharPtr("type_string"));
  SWIG_Python_SetConstant(d, "INVOICE_BILLTO",SWIG_FromCharPtr("bill-to"));
  SWIG_Python_SetConstant(d, "INVOICE_ENTRIES",SWIG_FromCharPtr("list_of_entries"));
  SWIG_Python_SetConstant(d, "INVOICE_JOB",SWIG_FromCharPtr("invoice_job"));
  SWIG_Python_SetConstant(d, "INVOICE_FROM_LOT",SWIG_FromCharPtr("invoice-from-lot"));
  SWIG_Python_SetConstant(d, "INVOICE_FROM_TXN",SWIG_FromCharPtr("invoice-from-txn"));
  SWIG_Python_SetConstant(d, "GNC_ID_JOB",SWIG_FromCharPtr("gncJob"));
  SWIG_Python_SetConstant(d, "JOB_ID",SWIG_FromCharPtr("id"));
  SWIG_Python_SetConstant(d, "JOB_NAME",SWIG_FromCharPtr("name"));
  SWIG_Python_SetConstant(d, "JOB_REFERENCE",SWIG_FromCharPtr("reference"));
  SWIG_Python_SetConstant(d, "JOB_RATE",SWIG_FromCharPtr("rate"));
  SWIG_Python_SetConstant(d, "JOB_OWNER",SWIG_FromCharPtr("owner"));
  SWIG_Python_SetConstant(d, "Q_JOB_OWNER",SWIG_FromCharPtr("owner_collection"));
  SWIG_Python_SetConstant(d, "JOB_ACTIVE",SWIG_FromCharPtr("active"));
  SWIG_Python_SetConstant(d, "GNC_PAYMENT_CASH",SWIG_From_int((int)(GNC_PAYMENT_CASH)));
  SWIG_Python_SetConstant(d, "GNC_PAYMENT_CARD",SWIG_From_int((int)(GNC_PAYMENT_CARD)));
  SWIG_Python_SetConstant(d, "GNC_DISC_PRETAX",SWIG_From_int((int)(GNC_DISC_PRETAX)));
  SWIG_Python_SetConstant(d, "GNC_DISC_SAMETIME",SWIG_From_int((int)(GNC_DISC_SAMETIME)));
  SWIG_Python_SetConstant(d, "GNC_DISC_POSTTAX",SWIG_From_int((int)(GNC_DISC_POSTTAX)));
  SWIG_Python_SetConstant(d, "GNC_ID_ENTRY",SWIG_FromCharPtr("gncEntry"));
  SWIG_Python_SetConstant(d, "ENTRY_DATE",SWIG_FromCharPtr("date"));
  SWIG_Python_SetConstant(d, "ENTRY_DATE_ENTERED",SWIG_FromCharPtr("date-entered"));
  SWIG_Python_SetConstant(d, "ENTRY_DESC",SWIG_FromCharPtr("desc"));
  SWIG_Python_SetConstant(d, "ENTRY_ACTION",SWIG_FromCharPtr("action"));
  SWIG_Python_SetConstant(d, "ENTRY_NOTES",SWIG_FromCharPtr("notes"));
  SWIG_Python_SetConstant(d, "ENTRY_QTY",SWIG_FromCharPtr("qty"));
  SWIG_Python_SetConstant(d, "ENTRY_IPRICE",SWIG_FromCharPtr("iprice"));
  SWIG_Python_SetConstant(d, "ENTRY_IACCT",SWIG_FromCharPtr("invoice-account"));
  SWIG_Python_SetConstant(d, "ENTRY_BACCT",SWIG_FromCharPtr("bill-account"));
  SWIG_Python_SetConstant(d, "ENTRY_BPRICE",SWIG_FromCharPtr("bprice"));
  SWIG_Python_SetConstant(d, "ENTRY_BILLABLE",SWIG_FromCharPtr("billable?"));
  SWIG_Python_SetConstant(d, "ENTRY_BILLTO",SWIG_FromCharPtr("bill-to"));
  SWIG_Python_SetConstant(d, "ENTRY_ORDER",SWIG_FromCharPtr("order"));
  SWIG_Python_SetConstant(d, "ENTRY_INVOICE",SWIG_FromCharPtr("invoice"));
  SWIG_Python_SetConstant(d, "ENTRY_BILL",SWIG_FromCharPtr("bill"));
  SWIG_Python_SetConstant(d, "ENTRY_INV_DISC_TYPE",SWIG_FromCharPtr("discount-type"));
  SWIG_Python_SetConstant(d, "ENTRY_INV_DISC_HOW",SWIG_FromCharPtr("discount-method"));
  SWIG_Python_SetConstant(d, "ENTRY_INV_TAXABLE",SWIG_FromCharPtr("invoice-taxable"));
  SWIG_Python_SetConstant(d, "ENTRY_BILL_TAXABLE",SWIG_FromCharPtr("bill-taxable"));
  SWIG_Python_SetConstant(d, "ENTRY_INV_TAX_INC",SWIG_FromCharPtr("invoice-tax-included"));
  SWIG_Python_SetConstant(d, "ENTRY_BILL_TAX_INC",SWIG_FromCharPtr("bill-tax-included"));
  SWIG_Python_SetConstant(d, "ENTRY_INV_DISCOUNT",SWIG_FromCharPtr("invoice-discount"));
  SWIG_Python_SetConstant(d, "ENTRY_BILL_PAY_TYPE",SWIG_FromCharPtr("bill-payment-type"));
  SWIG_Python_SetConstant(d, "GNC_AMT_TYPE_VALUE",SWIG_From_int((int)(GNC_AMT_TYPE_VALUE)));
  SWIG_Python_SetConstant(d, "GNC_AMT_TYPE_PERCENT",SWIG_From_int((int)(GNC_AMT_TYPE_PERCENT)));
  SWIG_Python_SetConstant(d, "GNC_TAXINCLUDED_YES",SWIG_From_int((int)(GNC_TAXINCLUDED_YES)));
  SWIG_Python_SetConstant(d, "GNC_TAXINCLUDED_NO",SWIG_From_int((int)(GNC_TAXINCLUDED_NO)));
  SWIG_Python_SetConstant(d, "GNC_TAXINCLUDED_USEGLOBAL",SWIG_From_int((int)(GNC_TAXINCLUDED_USEGLOBAL)));
  SWIG_Python_SetConstant(d, "GNC_ID_TAXTABLE",SWIG_FromCharPtr("gncTaxTable"));
  SWIG_Python_SetConstant(d, "GNC_TT_NAME",SWIG_FromCharPtr("tax table name"));
  SWIG_Python_SetConstant(d, "GNC_TT_REFCOUNT",SWIG_FromCharPtr("reference count"));
  SWIG_Python_SetConstant(d, "PRICE_SOURCE_EDIT_DLG",SWIG_From_int((int)(PRICE_SOURCE_EDIT_DLG)));
  SWIG_Python_SetConstant(d, "PRICE_SOURCE_FQ",SWIG_From_int((int)(PRICE_SOURCE_FQ)));
  SWIG_Python_SetConstant(d, "PRICE_SOURCE_USER_PRICE",SWIG_From_int((int)(PRICE_SOURCE_USER_PRICE)));
  SWIG_Python_SetConstant(d, "PRICE_SOURCE_XFER_DLG_VAL",SWIG_From_int((int)(PRICE_SOURCE_XFER_DLG_VAL)));
  SWIG_Python_SetConstant(d, "PRICE_SOURCE_SPLIT_REG",SWIG_From_int((int)(PRICE_SOURCE_SPLIT_REG)));
  SWIG_Python_SetConstant(d, "PRICE_SOURCE_STOCK_SPLIT",SWIG_From_int((int)(PRICE_SOURCE_STOCK_SPLIT)));
  SWIG_Python_SetConstant(d, "PRICE_SOURCE_INVOICE",SWIG_From_int((int)(PRICE_SOURCE_INVOICE)));
  SWIG_Python_SetConstant(d, "PRICE_SOURCE_TEMP",SWIG_From_int((int)(PRICE_SOURCE_TEMP)));
  SWIG_Python_SetConstant(d, "PRICE_SOURCE_INVALID",SWIG_From_int((int)(PRICE_SOURCE_INVALID)));
  SWIG_Python_SetConstant(d, "PRICE_TYPE_LAST",SWIG_FromCharPtr("last"));
  SWIG_Python_SetConstant(d, "PRICE_TYPE_UNK",SWIG_FromCharPtr("unknown"));
  SWIG_Python_SetConstant(d, "PRICE_TYPE_TRN",SWIG_FromCharPtr("transaction"));
  SWIG_Python_SetConstant(d, "CURRENCY_DENOM",SWIG_From_int((int)(10000)));
  SWIG_Python_SetConstant(d, "COMMODITY_DENOM_MULT",SWIG_From_int((int)(10000)));
  SWIG_Python_SetConstant(d, "PRICE_REMOVE_SOURCE_FQ",SWIG_From_int((int)(PRICE_REMOVE_SOURCE_FQ)));
  SWIG_Python_SetConstant(d, "PRICE_REMOVE_SOURCE_USER",SWIG_From_int((int)(PRICE_REMOVE_SOURCE_USER)));
  SWIG_Python_SetConstant(d, "PRICE_REMOVE_SOURCE_APP",SWIG_From_int((int)(PRICE_REMOVE_SOURCE_APP)));
  SWIG_Python_SetConstant(d, "PRICE_REMOVE_SOURCE_COMM",SWIG_From_int((int)(PRICE_REMOVE_SOURCE_COMM)));
  SWIG_Python_SetConstant(d, "PRICE_REMOVE_KEEP_NONE",SWIG_From_int((int)(PRICE_REMOVE_KEEP_NONE)));
  SWIG_Python_SetConstant(d, "PRICE_REMOVE_KEEP_LAST_WEEKLY",SWIG_From_int((int)(PRICE_REMOVE_KEEP_LAST_WEEKLY)));
  SWIG_Python_SetConstant(d, "PRICE_REMOVE_KEEP_LAST_MONTHLY",SWIG_From_int((int)(PRICE_REMOVE_KEEP_LAST_MONTHLY)));
  SWIG_Python_SetConstant(d, "PRICE_REMOVE_KEEP_LAST_QUARTERLY",SWIG_From_int((int)(PRICE_REMOVE_KEEP_LAST_QUARTERLY)));
  SWIG_Python_SetConstant(d, "PRICE_REMOVE_KEEP_LAST_PERIOD",SWIG_From_int((int)(PRICE_REMOVE_KEEP_LAST_PERIOD)));
  SWIG_Python_SetConstant(d, "PRICE_REMOVE_KEEP_SCALED",SWIG_From_int((int)(PRICE_REMOVE_KEEP_SCALED)));
  SWIG_Python_SetConstant(d, "PRICE_COMMODITY",SWIG_FromCharPtr("price-commodity"));
  SWIG_Python_SetConstant(d, "PRICE_CURRENCY",SWIG_FromCharPtr("price-currency"));
  SWIG_Python_SetConstant(d, "PRICE_DATE",SWIG_FromCharPtr("price-date"));
  SWIG_Python_SetConstant(d, "PRICE_SOURCE",SWIG_FromCharPtr("price-source"));
  SWIG_Python_SetConstant(d, "PRICE_TYPE",SWIG_FromCharPtr("price-type"));
  SWIG_Python_SetConstant(d, "PRICE_VALUE",SWIG_FromCharPtr("price-value"));
  
  gnc_environment_setup();
  qof_log_init();
  qof_init();
  qof_query_init();
  gnc_module_system_init();
  char * no_args[1] = {
    NULL 
  };
  gnc_engine_init(0, no_args);
  gnc_prefs_init();
  
#if PY_VERSION_HEX >= 0x03000000
  return m;
#else
  return;
#endif
}

