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

#define SWIGPYTHON

#ifdef __cplusplus
template<class T> class SwigValueWrapper {
    T *tt;
public:
    SwigValueWrapper() : tt(0) { }
    SwigValueWrapper(const SwigValueWrapper<T>& rhs) : tt(new T(*rhs.tt)) { }
    SwigValueWrapper(const T& t) : tt(new T(t)) { }
    ~SwigValueWrapper() { delete tt; } 
    SwigValueWrapper& operator=(const T& t) { delete tt; tt = new T(t); return *this; }
    operator T&() const { return *tt; }
    T *operator&() { return tt; }
private:
    SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
};
#endif

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

/* template workaround for compilers that cannot correctly implement the C++ standard */
#ifndef SWIGTEMPLATEDISAMBIGUATOR
#  if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
#    define SWIGTEMPLATEDISAMBIGUATOR template
#  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__) || defined(__ICC)
#   define SWIGUNUSED __attribute__ ((unused)) 
# else
#   define 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 for Windows DLLs */
#ifndef SWIGEXPORT
# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
#   if defined(STATIC_LINKED)
#     define SWIGEXPORT
#   else
#     define SWIGEXPORT __declspec(dllexport)
#   endif
# else
#   define SWIGEXPORT
# endif
#endif

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



#include <Python.h>

/***********************************************************************
 * swigrun.swg
 *
 *     This file contains generic CAPI 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 "2"

/* 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 is strictly necessary, ie, if you have problems
  with your compiler or so.
*/

#ifndef SWIGRUNTIME
# define SWIGRUNTIME SWIGINTERN
#endif

#ifndef SWIGRUNTIMEINLINE
# define SWIGRUNTIMEINLINE SWIGRUNTIME SWIGINLINE
#endif

#include <string.h>

#ifdef __cplusplus
extern "C" {
#endif

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

/* Structure to store inforomation 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 */
} 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 (int)(*f1 - *f2);
  }
  return (l1 - f1) - (l2 - f2);
}

/*
  Check type equivalence in a name list like <name1>|<name2>|...
  Return 0 if not equal, 1 if equal
*/
SWIGRUNTIME int
SWIG_TypeEquiv(const char *nb, const char *tb) {
  int equiv = 0;
  const char* te = tb + strlen(tb);
  const char* ne = nb;
  while (!equiv && *ne) {
    for (nb = ne; *ne; ++ne) {
      if (*ne == '|') break;
    }
    equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
    if (*ne) ++ne;
  }
  return equiv;
}

/*
  Check type equivalence in a name list like <name1>|<name2>|...
  Return 0 if equal, -1 if nb < tb, 1 if nb > tb
*/
SWIGRUNTIME int
SWIG_TypeCompare(const char *nb, const char *tb) {
  int equiv = 0;
  const char* te = tb + strlen(tb);
  const char* ne = nb;
  while (!equiv && *ne) {
    for (nb = ne; *ne; ++ne) {
      if (*ne == '|') break;
    }
    equiv = (SWIG_TypeNameComp(nb, ne, tb, te) == 0) ? 1 : 0;
    if (*ne) ++ne;
  }
  return equiv;
}


/* think of this as a c++ template<> or a scheme macro */
#define SWIG_TypeCheck_Template(comparison, ty)         \
  if (ty) {                                             \
    swig_cast_info *iter = ty->cast;                    \
    while (iter) {                                      \
      if (comparison) {                                 \
        if (iter == ty->cast) return iter;              \
        /* Move iter to the top of the linked list */   \
        iter->prev->next = iter->next;                  \
        if (iter->next)                                 \
          iter->next->prev = iter->prev;                \
        iter->next = ty->cast;                          \
        iter->prev = 0;                                 \
        if (ty->cast) ty->cast->prev = iter;            \
        ty->cast = iter;                                \
        return iter;                                    \
      }                                                 \
      iter = iter->next;                                \
    }                                                   \
  }                                                     \
  return 0

/*
  Check the typename
*/
SWIGRUNTIME swig_cast_info *
SWIG_TypeCheck(const char *c, swig_type_info *ty) {
  SWIG_TypeCheck_Template(strcmp(iter->type->name, c) == 0, ty);
}

/* Same as previous function, except strcmp is replaced with a pointer comparison */
SWIGRUNTIME swig_cast_info *
SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *into) {
  SWIG_TypeCheck_Template(iter->type == from, into);
}

/*
  Cast a pointer up an inheritance hierarchy
*/
SWIGRUNTIMEINLINE void *
SWIG_TypeCast(swig_cast_info *ty, void *ptr) {
  return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr);
}

/* 
   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->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) {
  if (!ti->clientdata) {
    swig_cast_info *cast = ti->cast;
    /* if (ti->clientdata == clientdata) return; */
    ti->clientdata = clientdata;
    
    while (cast) {
      if (!cast->converter)
	SWIG_TypeClientData(cast->type, clientdata);
      cast = cast->next;
    }
  }
}

/*
  Search for a swig_type_info structure only by mangled name
  Search is a O(log #types)
  
  We start searching at module start, and finish searching when start == end.  
  Note: if start == end at the beginning of the function, we go all the way around
  the circular list.
*/
SWIGRUNTIME swig_type_info *
SWIG_MangledTypeQueryModule(swig_module_info *start, 
                            swig_module_info *end, 
		            const char *name) {
  swig_module_info *iter = start;
  do {
    if (iter->size) {
      register size_t l = 0;
      register size_t r = iter->size - 1;
      do {
	/* since l+r >= 0, we can (>> 1) instead (/ 2) */
	register size_t i = (l + r) >> 1; 
	const char *iname = iter->types[i]->name;
	if (iname) {
	  register int compare = strcmp(name, iname);
	  if (compare == 0) {	    
	    return iter->types[i];
	  } else if (compare < 0) {
	    if (i) {
	      r = i - 1;
	    } else {
	      break;
	    }
	  } else if (compare > 0) {
	    l = i + 1;
	  }
	} else {
	  break; /* should never happen */
	}
      } while (l <= r);
    }
    iter = iter->next;
  } while (iter != end);
  return 0;
}

/*
  Search for a swig_type_info structure for either a mangled name or a human readable name.
  It first searches the mangled names of the types, which is a O(log #types)
  If a type is not found it then searches the human readable names, which is O(#types).
  
  We start searching at module start, and finish searching when start == end.  
  Note: if start == end at the beginning of the function, we go all the way around
  the circular list.
*/
SWIGRUNTIME swig_type_info *
SWIG_TypeQueryModule(swig_module_info *start, 
                     swig_module_info *end, 
		     const char *name) {
  /* STEP 1: Search the name field using binary search */
  swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
  if (ret) {
    return ret;
  } else {
    /* STEP 2: If the type hasn't been found, do a complete search
       of the str field (the human readable name) */
    swig_module_info *iter = start;
    do {
      register size_t i = 0;
      for (; i < iter->size; ++i) {
	if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
	  return iter->types[i];
      }
      iter = iter->next;
    } while (iter != end);
  }
  
  /* neither found a match */
  return 0;
}


/* 
   Pack binary data into a string
*/
SWIGRUNTIME char *
SWIG_PackData(char *c, void *ptr, size_t sz) {
  static const char hex[17] = "0123456789abcdef";
  register const unsigned char *u = (unsigned char *) ptr;
  register const unsigned char *eu =  u + sz;
  for (; u != eu; ++u) {
    register unsigned char uu = *u;
    *(c++) = hex[(uu & 0xf0) >> 4];
    *(c++) = hex[uu & 0xf];
  }
  return c;
}

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

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

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

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

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

#ifdef __cplusplus
}
#endif

/* -----------------------------------------------------------------------------
 * SWIG API. Portion that goes into the runtime
 * ----------------------------------------------------------------------------- */

#ifdef __cplusplus
extern "C" {
#endif

/* -----------------------------------------------------------------------------
 * for internal method declarations
 * ----------------------------------------------------------------------------- */

#ifndef SWIGINTERN
#  define SWIGINTERN static SWIGUNUSED
#endif

#ifndef SWIGINTERNINLINE
#  define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
#endif

/*
  Exception handling in wrappers
*/
#define SWIG_fail                goto fail
#define SWIG_arg_fail(arg)       SWIG_Python_ArgFail(arg)
#define SWIG_append_errmsg(msg)   SWIG_Python_AddErrMesg(msg,0)
#define SWIG_preppend_errmsg(msg) SWIG_Python_AddErrMesg(msg,1)
#define SWIG_type_error(type,obj) SWIG_Python_TypeError(type,obj)
#define SWIG_null_ref(type)       SWIG_Python_NullRef(type)

/*
  Contract support
*/
#define SWIG_contract_assert(expr, msg) \
 if (!(expr)) { PyErr_SetString(PyExc_RuntimeError, (char *) msg ); goto fail; } else

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

/* Constant Types */
#define SWIG_PY_INT     1
#define SWIG_PY_FLOAT   2
#define SWIG_PY_STRING  3
#define SWIG_PY_POINTER 4
#define SWIG_PY_BINARY  5

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


/* -----------------------------------------------------------------------------
 * Alloc. memory flags
 * ----------------------------------------------------------------------------- */
#define SWIG_OLDOBJ  1
#define SWIG_NEWOBJ  SWIG_OLDOBJ + 1
#define SWIG_PYSTR   SWIG_NEWOBJ + 1

#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.
 *
 * Author : David Beazley (beazley@cs.uchicago.edu)
 ************************************************************************/

/* Common SWIG API */
#define SWIG_ConvertPtr(obj, pp, type, flags)    SWIG_Python_ConvertPtr(obj, pp, type, flags)
#define SWIG_NewPointerObj(p, type, flags)       SWIG_Python_NewPointerObj(p, type, flags)
#define SWIG_MustGetPtr(p, type, argnum, flags)  SWIG_Python_MustGetPtr(p, type, argnum, flags)
 

/* Python-specific SWIG API */
#define SWIG_ConvertPacked(obj, ptr, sz, ty, flags)   SWIG_Python_ConvertPacked(obj, ptr, sz, ty, flags)
#define SWIG_NewPackedObj(ptr, sz, type)              SWIG_Python_NewPackedObj(ptr, sz, type)

/* Runtime API */
#define SWIG_GetModule(clientdata) SWIG_Python_GetModule()
#define SWIG_SetModule(clientdata, pointer) SWIG_Python_SetModule(pointer)

/* -----------------------------------------------------------------------------
 * Pointer declarations
 * ----------------------------------------------------------------------------- */
/*
  Use SWIG_NO_COBJECT_TYPES to force the use of strings to represent
  C/C++ pointers in the python side. Very useful for debugging, but
  not always safe.
*/
#if !defined(SWIG_NO_COBJECT_TYPES) && !defined(SWIG_COBJECT_TYPES)
#  define SWIG_COBJECT_TYPES
#endif

/* Flags for pointer conversion */
#define SWIG_POINTER_EXCEPTION     0x1
#define SWIG_POINTER_DISOWN        0x2


/* Add PyOS_snprintf for old Pythons */
#if PY_VERSION_HEX < 0x02020000
#define PyOS_snprintf snprintf
#endif

#ifdef __cplusplus
extern "C" {
#endif

/* -----------------------------------------------------------------------------
 * Create a new pointer string 
 * ----------------------------------------------------------------------------- */
#ifndef SWIG_BUFFER_SIZE
#define SWIG_BUFFER_SIZE 1024
#endif

#if defined(SWIG_COBJECT_TYPES)
#if !defined(SWIG_COBJECT_PYTHON)
/* -----------------------------------------------------------------------------
 * Implements a simple Swig Object type, and use it instead of PyCObject
 * ----------------------------------------------------------------------------- */

typedef struct {
  PyObject_HEAD
  void *ptr;
  const char *desc;
} PySwigObject;

/* Declarations for objects of type PySwigObject */

SWIGRUNTIME int
PySwigObject_print(PySwigObject *v, FILE *fp, int flags)
{
  char result[SWIG_BUFFER_SIZE];
  flags = flags;
  if (SWIG_PackVoidPtr(result, v->ptr, v->desc, sizeof(result))) {
    fputs("<Swig Object at ", fp); fputs(result, fp); fputs(">", fp);
    return 0; 
  } else {
    return 1; 
  }
}
  
SWIGRUNTIME PyObject *
PySwigObject_repr(PySwigObject *v)
{
  char result[SWIG_BUFFER_SIZE];
  return SWIG_PackVoidPtr(result, v->ptr, v->desc, sizeof(result)) ?
    PyString_FromFormat("<Swig Object at %s>", result) : 0;
}

SWIGRUNTIME PyObject *
PySwigObject_str(PySwigObject *v)
{
  char result[SWIG_BUFFER_SIZE];
  return SWIG_PackVoidPtr(result, v->ptr, v->desc, sizeof(result)) ?
    PyString_FromString(result) : 0;
}

SWIGRUNTIME PyObject *
PySwigObject_long(PySwigObject *v)
{
  return PyLong_FromVoidPtr(v->ptr);
}

SWIGRUNTIME PyObject *
PySwigObject_format(const char* fmt, PySwigObject *v)
{
  PyObject *res = NULL;
  PyObject *args = PyTuple_New(1);
  if (args && (PyTuple_SetItem(args, 0, PySwigObject_long(v)) == 0)) {
    PyObject *ofmt = PyString_FromString(fmt);
    if (ofmt) {
      res = PyString_Format(ofmt,args);
      Py_DECREF(ofmt);
    }
    Py_DECREF(args);
  }  
  return res;
}

SWIGRUNTIME PyObject *
PySwigObject_oct(PySwigObject *v)
{
  return PySwigObject_format("%o",v);
}

SWIGRUNTIME PyObject *
PySwigObject_hex(PySwigObject *v)
{
  return PySwigObject_format("%x",v);
}

SWIGRUNTIME int
PySwigObject_compare(PySwigObject *v, PySwigObject *w)
{
  int c = strcmp(v->desc, w->desc);
  if (c) {
    return (c > 0) ? 1 : -1;
  } else {
    void *i = v->ptr;
    void *j = w->ptr;
    return (i < j) ? -1 : ((i > j) ? 1 : 0);
  }
}

SWIGRUNTIME void
PySwigObject_dealloc(PySwigObject *self)
{
  PyObject_DEL(self);
}

SWIGRUNTIME PyTypeObject*
PySwigObject_type(void) {
  static char pyswigobject_type__doc__[] = 
    "Swig object carries a C/C++ instance pointer";
  
  static PyNumberMethods PySwigObject_as_number = {
    (binaryfunc)0, /*nb_add*/
    (binaryfunc)0, /*nb_subtract*/
    (binaryfunc)0, /*nb_multiply*/
    (binaryfunc)0, /*nb_divide*/
    (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*/
    (coercion)0,   /*nb_coerce*/
    (unaryfunc)PySwigObject_long, /*nb_int*/
    (unaryfunc)PySwigObject_long, /*nb_long*/
    (unaryfunc)0,                 /*nb_float*/
    (unaryfunc)PySwigObject_oct,  /*nb_oct*/
    (unaryfunc)PySwigObject_hex,  /*nb_hex*/
#if PY_VERSION_HEX >= 0x02000000
    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_inplace_true_divide */ 
#endif
  };

  static PyTypeObject pyswigobject_type
#if !defined(__cplusplus)
  ;  
  static int type_init = 0;
  if (!type_init) {
    PyTypeObject tmp
#endif
    = {
    PyObject_HEAD_INIT(&PyType_Type)
    0,					/*ob_size*/
    (char *)"PySwigObject",		/*tp_name*/
    sizeof(PySwigObject),		/*tp_basicsize*/
    0,					/*tp_itemsize*/
    /* methods */
    (destructor)PySwigObject_dealloc,	/*tp_dealloc*/
    (printfunc)PySwigObject_print,	/*tp_print*/
    (getattrfunc)0,			/*tp_getattr*/
    (setattrfunc)0,			/*tp_setattr*/
    (cmpfunc)PySwigObject_compare,	/*tp_compare*/
    (reprfunc)PySwigObject_repr,	/*tp_repr*/
    &PySwigObject_as_number,	        /*tp_as_number*/
    0,					/*tp_as_sequence*/
    0,					/*tp_as_mapping*/
    (hashfunc)0,			/*tp_hash*/
    (ternaryfunc)0,			/*tp_call*/
    (reprfunc)PySwigObject_str,		/*tp_str*/
    /* Space for future expansion */
    0,0,0,0,
    pyswigobject_type__doc__, 	        /* Documentation string */
#if PY_VERSION_HEX >= 0x02000000
    0,                                  /* tp_traverse */
    0,                                  /* tp_clear */
#endif
#if PY_VERSION_HEX >= 0x02010000
    0,                                  /* tp_richcompare */
    0,                                  /* tp_weaklistoffset */
#endif
#if PY_VERSION_HEX >= 0x02020000
    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */
#endif
#if PY_VERSION_HEX >= 0x02030000
    0,                                  /* tp_del */
#endif
#ifdef COUNT_ALLOCS
    0,0,0,0                             /* tp_alloc -> tp_next */
#endif
    };
#if !defined(__cplusplus)
    pyswigobject_type = tmp;
    type_init = 1;
  }
#endif
  return &pyswigobject_type;
}

SWIGRUNTIME PyObject *
PySwigObject_FromVoidPtrAndDesc(void *ptr, const char *desc)
{
  PySwigObject *self = PyObject_NEW(PySwigObject, PySwigObject_type());
  if (self) {
    self->ptr = ptr;
    self->desc = desc;
  }
  return (PyObject *)self;
}

SWIGRUNTIMEINLINE void *
PySwigObject_AsVoidPtr(PyObject *self)
{
  return ((PySwigObject *)self)->ptr;
}

SWIGRUNTIMEINLINE const char *
PySwigObject_GetDesc(PyObject *self)
{
  return ((PySwigObject *)self)->desc;
}

SWIGRUNTIMEINLINE int
PySwigObject_Check(PyObject *op) {
  return ((op)->ob_type == PySwigObject_type()) 
    || (strcmp((op)->ob_type->tp_name,"PySwigObject") == 0);
}

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

typedef struct {
  PyObject_HEAD
  void *pack;
  const char *desc;
  size_t size;
} PySwigPacked;

SWIGRUNTIME int
PySwigPacked_print(PySwigPacked *v, FILE *fp, int flags)
{
  char result[SWIG_BUFFER_SIZE];
  flags = flags;
  fputs("<Swig Packed ", fp); 
  if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))) {
    fputs("at ", fp); 
    fputs(result, fp); 
  }
  fputs(v->desc,fp); 
  fputs(">", fp);
  return 0; 
}
  
SWIGRUNTIME PyObject *
PySwigPacked_repr(PySwigPacked *v)
{
  char result[SWIG_BUFFER_SIZE];
  if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))) {
    return PyString_FromFormat("<Swig Packed at %s%s>", result, v->desc);
  } else {
    return PyString_FromFormat("<Swig Packed %s>", v->desc);
  }  
}

SWIGRUNTIME PyObject *
PySwigPacked_str(PySwigPacked *v)
{
  char result[SWIG_BUFFER_SIZE];
  if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))){
    return PyString_FromFormat("%s%s", result, v->desc);
  } else {
    return PyString_FromFormat("%s", v->desc);
  }  
}

SWIGRUNTIME int
PySwigPacked_compare(PySwigPacked *v, PySwigPacked *w)
{
  int c = strcmp(v->desc, w->desc);
  if (c) {
    return (c > 0) ? 1 : -1;
  } else {
    size_t i = v->size;
    size_t j = w->size;
    int s = (i < j) ? -1 : ((i > j) ? 1 : 0);
    return s ? s : strncmp((char *)v->pack, (char *)w->pack, 2*v->size);
  }
}

SWIGRUNTIME void
PySwigPacked_dealloc(PySwigPacked *self)
{
  free(self->pack);
  PyObject_DEL(self);
}

SWIGRUNTIME PyTypeObject*
PySwigPacked_type(void) {
  static char pyswigpacked_type__doc__[] = 
    "Swig object carries a C/C++ instance pointer";
  static PyTypeObject pyswigpacked_type
#if !defined(__cplusplus)
  ;
  static int type_init = 0;  
  if (!type_init) {
    PyTypeObject tmp
#endif
    = {
    PyObject_HEAD_INIT(&PyType_Type)
    0,					/*ob_size*/
    (char *)"PySwigPacked",		/*tp_name*/
    sizeof(PySwigPacked),		/*tp_basicsize*/
    0,					/*tp_itemsize*/
    /* methods */
    (destructor)PySwigPacked_dealloc,	/*tp_dealloc*/
    (printfunc)PySwigPacked_print,	/*tp_print*/
    (getattrfunc)0,			/*tp_getattr*/
    (setattrfunc)0,			/*tp_setattr*/
    (cmpfunc)PySwigPacked_compare,	/*tp_compare*/
    (reprfunc)PySwigPacked_repr,	/*tp_repr*/
    0,	                                /*tp_as_number*/
    0,					/*tp_as_sequence*/
    0,					/*tp_as_mapping*/
    (hashfunc)0,			/*tp_hash*/
    (ternaryfunc)0,			/*tp_call*/
    (reprfunc)PySwigPacked_str,		/*tp_str*/
    /* Space for future expansion */
    0,0,0,0,
    pyswigpacked_type__doc__, 	        /* Documentation string */
#if PY_VERSION_HEX >= 0x02000000
    0,                                  /* tp_traverse */
    0,                                  /* tp_clear */
#endif
#if PY_VERSION_HEX >= 0x02010000
    0,                                  /* tp_richcompare */
    0,                                  /* tp_weaklistoffset */
#endif
#if PY_VERSION_HEX >= 0x02020000         
    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */
#endif
#if PY_VERSION_HEX >= 0x02030000
    0,                                  /* tp_del */
#endif
#ifdef COUNT_ALLOCS
    0,0,0,0                             /* tp_alloc -> tp_next */
#endif
    };
#if !defined(__cplusplus)
    pyswigpacked_type = tmp;
    type_init = 1;
  }
#endif
  return &pyswigpacked_type;
}

SWIGRUNTIME PyObject *
PySwigPacked_FromDataAndDesc(void *ptr, size_t size, const char *desc)
{
  PySwigPacked *self = PyObject_NEW(PySwigPacked, PySwigPacked_type());
  if (self == NULL) {
    return NULL;
  } else {
    void *pack = malloc(size);
    if (pack) {
      memcpy(pack, ptr, size);
      self->pack = pack;
      self->desc = desc;
      self->size = size;
      return (PyObject *) self;
    }
    return NULL;
  }
}

SWIGRUNTIMEINLINE const char *
PySwigPacked_UnpackData(PyObject *obj, void *ptr, size_t size)
{
  PySwigPacked *self = (PySwigPacked *)obj;
  if (self->size != size) return 0;
  memcpy(ptr, self->pack, size);
  return self->desc;
}

SWIGRUNTIMEINLINE const char *
PySwigPacked_GetDesc(PyObject *self)
{
  return ((PySwigPacked *)self)->desc;
}

SWIGRUNTIMEINLINE int
PySwigPacked_Check(PyObject *op) {
  return ((op)->ob_type == PySwigPacked_type()) 
    || (strcmp((op)->ob_type->tp_name,"PySwigPacked") == 0);
}

#else
/* -----------------------------------------------------------------------------
 * Use the old Python PyCObject instead of PySwigObject
 * ----------------------------------------------------------------------------- */

#define PySwigObject_GetDesc(obj)	           PyCObject_GetDesc(obj)
#define PySwigObject_Check(obj)	           PyCObject_Check(obj)
#define PySwigObject_AsVoidPtr(obj)	   PyCObject_AsVoidPtr(obj)
#define PySwigObject_FromVoidPtrAndDesc(p, d)  PyCObject_FromVoidPtrAndDesc(p, d, NULL)

#endif

#endif

/* -----------------------------------------------------------------------------
 * errors manipulation
 * ----------------------------------------------------------------------------- */

SWIGRUNTIME void
SWIG_Python_TypeError(const char *type, PyObject *obj)
{
  if (type) {
#if defined(SWIG_COBJECT_TYPES)
    if (obj && PySwigObject_Check(obj)) {
      const char *otype = (const char *) PySwigObject_GetDesc(obj);
      if (otype) {
	PyErr_Format(PyExc_TypeError, "a '%s' is expected, 'PySwigObject(%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 ? PyString_AsString(str) : 0;
	if (cstr) {
	  PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s(%s)' is received",
		       type, otype, 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");
  }
}

SWIGRUNTIMEINLINE void
SWIG_Python_NullRef(const char *type)
{
  if (type) {
    PyErr_Format(PyExc_TypeError, "null reference of type '%s' was received",type);
  } else {
    PyErr_Format(PyExc_TypeError, "null reference was received");
  }
}

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);
      Py_XINCREF(type);
      PyErr_Clear();
      if (infront) {
	PyErr_Format(type, "%s %s", mesg, PyString_AsString(old_str));
      } else {
	PyErr_Format(type, "%s %s", PyString_AsString(old_str), mesg);
      }
      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;
  }
}


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

/* Convert a pointer value */
SWIGRUNTIME int
SWIG_Python_ConvertPtr(PyObject *obj, void **ptr, swig_type_info *ty, int flags) {
  swig_cast_info *tc;
  const char *c = 0;
  static PyObject *SWIG_this = 0;
  int    newref = 0;
  PyObject  *pyobj = 0;
  void *vptr;
  
  if (!obj) return 0;
  if (obj == Py_None) {
    *ptr = 0;
    return 0;
  }

#ifdef SWIG_COBJECT_TYPES
  if (!(PySwigObject_Check(obj))) {
    if (!SWIG_this)
      SWIG_this = PyString_FromString("this");
    pyobj = obj;
    obj = PyObject_GetAttr(obj,SWIG_this);
    newref = 1;
    if (!obj) goto type_error;
    if (!PySwigObject_Check(obj)) {
      Py_DECREF(obj);
      goto type_error;
    }
  }  
  vptr = PySwigObject_AsVoidPtr(obj);
  c = (const char *) PySwigObject_GetDesc(obj);
  if (newref) { Py_DECREF(obj); }
  goto type_check;
#else
  if (!(PyString_Check(obj))) {
    if (!SWIG_this)
      SWIG_this = PyString_FromString("this");
    pyobj = obj;
    obj = PyObject_GetAttr(obj,SWIG_this);
    newref = 1;
    if (!obj) goto type_error;
    if (!PyString_Check(obj)) {
      Py_DECREF(obj);
      goto type_error;
    }
  } 
  c = PyString_AS_STRING(obj);
  /* Pointer values must start with leading underscore */
  c = SWIG_UnpackVoidPtr(c, &vptr, ty->name);
  if (newref) { Py_DECREF(obj); }
  if (!c) goto type_error;
#endif

type_check:
  if (ty) {
    tc = SWIG_TypeCheck(c,ty);
    if (!tc) goto type_error;
    *ptr = SWIG_TypeCast(tc,vptr);
  } else {
    *ptr = vptr;
  }
  if ((pyobj) && (flags & SWIG_POINTER_DISOWN)) {
    PyObject_SetAttrString(pyobj,(char*)"thisown",Py_False);
  }
  return 0;

type_error:
  PyErr_Clear();
  if (pyobj && !obj) {    
    obj = pyobj;
    if (PyCFunction_Check(obj)) {
      /* here we get the method pointer for callbacks */
      char *doc = (((PyCFunctionObject *)obj) -> m_ml -> ml_doc);
      c = doc ? strstr(doc, "swig_ptr: ") : 0;
      if (c) {
	c = ty ? SWIG_UnpackVoidPtr(c + 10, &vptr, ty->name) : 0;
	if (!c) goto type_error;
	goto type_check;
      }
    }
  }
  if (flags & SWIG_POINTER_EXCEPTION) {
    if (ty) {
      SWIG_Python_TypeError(SWIG_TypePrettyName(ty), obj);
    } else {
      SWIG_Python_TypeError("C/C++ pointer", obj);
    }
  }
  return -1;
}

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

/* Convert a packed value value */
SWIGRUNTIME int
SWIG_Python_ConvertPacked(PyObject *obj, void *ptr, size_t sz, swig_type_info *ty, int flags) {
  swig_cast_info *tc;
  const char *c = 0;

#if defined(SWIG_COBJECT_TYPES) && !defined(SWIG_COBJECT_PYTHON)
  c = PySwigPacked_UnpackData(obj, ptr, sz);
#else
  if ((!obj) || (!PyString_Check(obj))) goto type_error;
  c = PyString_AS_STRING(obj);
  /* Pointer values must start with leading underscore */
  c = SWIG_UnpackDataName(c, ptr, sz, ty->name);
#endif
  if (!c) goto type_error;
  if (ty) {
    tc = SWIG_TypeCheck(c,ty);
    if (!tc) goto type_error;
  }
  return 0;

type_error:
  PyErr_Clear();
  if (flags & SWIG_POINTER_EXCEPTION) {
    if (ty) {
      SWIG_Python_TypeError(SWIG_TypePrettyName(ty), obj);
    } else {
      SWIG_Python_TypeError("C/C++ packed data", obj);
    }
  }
  return -1;
}  

/* Create a new array object */
SWIGRUNTIME PyObject *
SWIG_Python_NewPointerObj(void *ptr, swig_type_info *type, int own) {
  PyObject *robj = 0;
  if (!type) {
    if (!PyErr_Occurred()) {
      PyErr_Format(PyExc_TypeError, "Swig: null type passed to NewPointerObj");
    }
    return robj;
  }
  if (!ptr) {
    Py_INCREF(Py_None);
    return Py_None;
  }
#ifdef SWIG_COBJECT_TYPES
  robj = PySwigObject_FromVoidPtrAndDesc((void *) ptr, (char *)type->name);
#else
  {
    char result[SWIG_BUFFER_SIZE];
    robj = SWIG_PackVoidPtr(result, ptr, type->name, sizeof(result)) ?
      PyString_FromString(result) : 0;
  }
#endif
  if (!robj || (robj == Py_None)) return robj;
  if (type->clientdata) {
    PyObject *inst;
    PyObject *args = Py_BuildValue((char*)"(O)", robj);
    Py_DECREF(robj);
    inst = PyObject_CallObject((PyObject *) type->clientdata, args);
    Py_DECREF(args);
    if (inst) {
      if (own) {
        PyObject_SetAttrString(inst,(char*)"thisown",Py_True);
      }
      robj = inst;
    }
  }
  return robj;
}

SWIGRUNTIME PyObject *
SWIG_Python_NewPackedObj(void *ptr, size_t sz, swig_type_info *type) {
  PyObject *robj = 0;
  if (!ptr) {
    Py_INCREF(Py_None);
    return Py_None;
  }
#if defined(SWIG_COBJECT_TYPES) && !defined(SWIG_COBJECT_PYTHON)
  robj = PySwigPacked_FromDataAndDesc((void *) ptr, sz, (char *)type->name);
#else
  {
    char result[SWIG_BUFFER_SIZE];
    robj = SWIG_PackDataName(result, ptr, sz, type->name, sizeof(result)) ?
      PyString_FromString(result) : 0;
  }
#endif
  return robj;
}

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

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

SWIGRUNTIME swig_module_info *
SWIG_Python_GetModule(void) {
  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 = PyCObject_Import((char*)"swig_runtime_data" SWIG_RUNTIME_VERSION,
				    (char*)"type_pointer" SWIG_TYPE_TABLE_NAME);
    if (PyErr_Occurred()) {
      PyErr_Clear();
      type_pointer = (void *)0;
    }
  }
#endif
  return (swig_module_info *) type_pointer;
}

SWIGRUNTIME void
SWIG_Python_SetModule(swig_module_info *swig_module) {
  static PyMethodDef swig_empty_runtime_method_table[] = { {NULL, NULL, 0, NULL} };/* Sentinel */

  PyObject *module = Py_InitModule((char*)"swig_runtime_data" SWIG_RUNTIME_VERSION,
				   swig_empty_runtime_method_table);
  PyObject *pointer = PyCObject_FromVoidPtr((void *) swig_module, NULL);
  if (pointer && module) {
    PyModule_AddObject(module, (char*)"type_pointer" SWIG_TYPE_TABLE_NAME, pointer);
  }
}

#ifdef __cplusplus
}
#endif


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

#define SWIGTYPE_p_GIntBig swig_types[0]
#define SWIGTYPE_p_OGRDataSourceShadow swig_types[1]
#define SWIGTYPE_p_OGRDriverShadow swig_types[2]
#define SWIGTYPE_p_OGRFeatureDefnShadow swig_types[3]
#define SWIGTYPE_p_OGRFeatureShadow swig_types[4]
#define SWIGTYPE_p_OGRFieldDefnShadow swig_types[5]
#define SWIGTYPE_p_OGRGeometryShadow swig_types[6]
#define SWIGTYPE_p_OGRLayerShadow swig_types[7]
#define SWIGTYPE_p_OSRCoordinateTransformationShadow swig_types[8]
#define SWIGTYPE_p_OSRSpatialReferenceShadow swig_types[9]
#define SWIGTYPE_p_char swig_types[10]
#define SWIGTYPE_p_double swig_types[11]
#define SWIGTYPE_p_int swig_types[12]
#define SWIGTYPE_p_p_char swig_types[13]
#define SWIGTYPE_ptrdiff_t swig_types[14]
#define SWIGTYPE_size_t swig_types[15]
#define SWIGTYPE_std__ptrdiff_t swig_types[16]
#define SWIGTYPE_std__size_t swig_types[17]
static swig_type_info *swig_types[18];
static swig_module_info swig_module = {swig_types, 18, 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) -------- */


/*-----------------------------------------------
              @(target):= _ogr.so
  ------------------------------------------------*/
#define SWIG_init    init_ogr

#define SWIG_name    "_ogr"

#define  SWIG_MemoryError    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_UnknownError  99


SWIGINTERN void SWIG_exception_(int code, const char *msg) {
  switch(code) {
  case SWIG_MemoryError:
    PyErr_SetString(PyExc_MemoryError,msg);
    break;
  case SWIG_IOError:
    PyErr_SetString(PyExc_IOError,msg);
    break;
  case SWIG_RuntimeError:
    PyErr_SetString(PyExc_RuntimeError,msg);
    break;
  case SWIG_IndexError:
    PyErr_SetString(PyExc_IndexError,msg);
    break;
  case SWIG_TypeError:
    PyErr_SetString(PyExc_TypeError,msg);
    break;
  case SWIG_DivisionByZero:
    PyErr_SetString(PyExc_ZeroDivisionError,msg);
    break;
  case SWIG_OverflowError:
    PyErr_SetString(PyExc_OverflowError,msg);
    break;
  case SWIG_SyntaxError:
    PyErr_SetString(PyExc_SyntaxError,msg);
    break;
  case SWIG_ValueError:
    PyErr_SetString(PyExc_ValueError,msg);
    break;
  case SWIG_SystemError:
    PyErr_SetString(PyExc_SystemError,msg);
    break;
  default:
    PyErr_SetString(PyExc_RuntimeError,msg);
    break;
  }
}

#define SWIG_exception(a,b) { SWIG_exception_(a,b); SWIG_fail; }


#include <stdexcept>


  /*@/home/kruland/opt/share/swig/1.3.25/python/pymacros.swg,66,SWIG_define@*/
#define SWIG_From_int PyInt_FromLong
/*@@*/


SWIGINTERN PyObject *
SWIG_FromCharPtr(const char* cptr)
{ 
  if (cptr) {
    size_t size = strlen(cptr);
    if (size > INT_MAX) {
      return SWIG_NewPointerObj((char*)(cptr), 
				SWIG_TypeQuery("char *"), 0);
    } else {
      if (size != 0) {
	return PyString_FromStringAndSize(cptr, size);
      } else {
	return PyString_FromString(cptr);
      }
    }
  }
  Py_INCREF(Py_None);
  return Py_None;
}


#include <iostream>
using namespace std;

#include "ogr_api.h"
#include "ogr_core.h"
#include "cpl_port.h"
#include "cpl_string.h"

typedef void OSRSpatialReferenceShadow;
typedef void OGRDriverShadow;
typedef void OGRDataSourceShadow;
typedef void OGRLayerShadow;
typedef void OGRFeatureShadow;
typedef void OGRFeatureDefnShadow;
typedef void OGRGeometryShadow;
typedef void OSRCoordinateTransformationShadow;
typedef void OGRFieldDefnShadow;

const unsigned long wkb25bit = -2147483648;


/* returns SWIG_OLDOBJ if the input is a raw char*, SWIG_PYSTR if is a PyString */
SWIGINTERN int
SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize)
{
  static swig_type_info* pchar_info = 0;
  char* vptr = 0;
  if (!pchar_info) pchar_info = SWIG_TypeQuery("char *");
  if (SWIG_ConvertPtr(obj, (void**)&vptr, pchar_info, 0) != -1) {
    if (cptr) *cptr = vptr;
    if (psize) *psize = vptr ? (strlen(vptr) + 1) : 0;
    return SWIG_OLDOBJ;
  } else {
    PyErr_Clear();
    if (PyString_Check(obj)) {
      if (cptr) {
	*cptr = PyString_AS_STRING(obj);
	if (psize) {
	  *psize = PyString_GET_SIZE(obj) + 1;
	}
      }
      return SWIG_PYSTR;
    }
  }
  if (cptr) {
    SWIG_type_error("char *", obj);
  }
  return 0;
}


SWIGINTERNINLINE int
SWIG_AsCharPtr(PyObject *obj, char **val)
{
  if (SWIG_AsCharPtrAndSize(obj, val, (size_t*)(0))) {
    return 1;
  }
  if (val) {
    PyErr_Clear();
    SWIG_type_error("char *", obj);
  }
  return 0;
}

static OGRDataSourceShadow *OGRDriverShadow_CreateDataSource(OGRDriverShadow *self,char const *name,char **options=0){
    OGRDataSourceShadow *ds = (OGRDataSourceShadow*) OGR_Dr_CreateDataSource( self, name, options);
    return ds;
  }
static OGRDataSourceShadow *OGRDriverShadow_CopyDataSource(OGRDriverShadow *self,OGRDataSourceShadow *copy_ds,char const *name,char **options=0){
    OGRDataSourceShadow *ds = (OGRDataSourceShadow*) OGR_Dr_CopyDataSource(self, copy_ds, name, options);
    return ds;
  }

#include <limits.h>


SWIGINTERN int
  SWIG_CheckLongInRange(long value, long min_value, long max_value,
			const char *errmsg)
{
  if (value < min_value) {
    if (errmsg) {
      PyErr_Format(PyExc_OverflowError, 
		   "value %ld is less than '%s' minimum %ld", 
		   value, errmsg, min_value);
    }
    return 0;    
  } else if (value > max_value) {
    if (errmsg) {
      PyErr_Format(PyExc_OverflowError,
		   "value %ld is greater than '%s' maximum %ld", 
		   value, errmsg, max_value);
    }
    return 0;
  }
  return 1;
}


SWIGINTERN int
  SWIG_AsVal_long(PyObject * obj, long* val)
{
  if (PyInt_Check(obj)) {
    if (val) *val = PyInt_AS_LONG(obj);
    return 1;
  }
  if (PyLong_Check(obj)) {
    long v = PyLong_AsLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return 1;
    } else {
      if (!val) PyErr_Clear();
      return 0;
    }
  }
  if (val) {
    SWIG_type_error("long", obj);
  }
  return 0;
 }


#if INT_MAX != LONG_MAX
SWIGINTERN int
  SWIG_AsVal_int(PyObject *obj, int *val)
{ 
  const char* errmsg = val ? "int" : (char*)0;
  long v;
  if (SWIG_AsVal_long(obj, &v)) {
    if (SWIG_CheckLongInRange(v, INT_MIN,INT_MAX, errmsg)) {
      if (val) *val = (int)(v);
      return 1;
    } else {
      return 0;
    }
  } else {
    PyErr_Clear();
  }
  if (val) {
    SWIG_type_error(errmsg, obj);
  }
  return 0;    
}
#else
SWIGINTERNINLINE int
  SWIG_AsVal_int(PyObject *obj, int *val)
{
  return SWIG_AsVal_long(obj,(long*)val);
}
#endif


SWIGINTERNINLINE int
SWIG_As_int(PyObject* obj)
{
  int v;
  if (!SWIG_AsVal_int(obj, &v)) {
    /*
      this is needed to make valgrind/purify happier. 
     */
    memset((void*)&v, 0, sizeof(int));
  }
  return v;
}

  
SWIGINTERNINLINE int
SWIG_Check_int(PyObject* obj)
{
  return SWIG_AsVal_int(obj, (int*)0);
}

static OGRDataSourceShadow *OGRDriverShadow_Open(OGRDriverShadow *self,char const *name,int update=0){
    OGRDataSourceShadow* ds = (OGRDataSourceShadow*) OGR_Dr_Open(self, name, update);
    return ds;
  }
static int OGRDriverShadow_DeleteDataSource(OGRDriverShadow *self,char const *name){
    return OGR_Dr_DeleteDataSource( self, name );
  }
static int OGRDriverShadow_TestCapability(OGRDriverShadow *self,char const *cap){
    return OGR_Dr_TestCapability(self, cap);
  }
static char const *OGRDriverShadow_GetName(OGRDriverShadow *self){
    return OGR_Dr_GetName( self );
  }
static void OGRDataSourceShadow_Destroy(OGRDataSourceShadow *self){
    OGR_DS_Destroy(self);
  }
static void OGRDataSourceShadow_Release(OGRDataSourceShadow *self){
    OGRReleaseDataSource(self);
  }
static int OGRDataSourceShadow_Reference(OGRDataSourceShadow *self){
    return OGR_DS_Reference(self);
  }
static int OGRDataSourceShadow_Dereference(OGRDataSourceShadow *self){
    return OGR_DS_Dereference(self);
  }
static int OGRDataSourceShadow_GetRefCount(OGRDataSourceShadow *self){
    return OGR_DS_GetRefCount(self);
  }
static int OGRDataSourceShadow_GetSummaryRefCount(OGRDataSourceShadow *self){
    return OGR_DS_GetSummaryRefCount(self);
  }
static int OGRDataSourceShadow_GetLayerCount(OGRDataSourceShadow *self){
    return OGR_DS_GetLayerCount(self);
  }
static char const *OGRDataSourceShadow_GetName(OGRDataSourceShadow *self){
    return OGR_DS_GetName(self);
  }
static OGRErr OGRDataSourceShadow_DeleteLayer(OGRDataSourceShadow *self,int index){
    return OGR_DS_DeleteLayer(self, index);
  }

static char const *
OGRErrMessages( int rc ) {
  switch( rc ) {
  case 0:
    return "OGR Error %d: None";
  case 1:
    return "OGR Error %d: Not enough data";
  case 2:
    return "OGR Error %d: Unsupported geometry type";
  case 3:
    return "OGR Error %d: Unsupported operation";
  case 4:
    return "OGR Error %d: Corrupt data";
  case 5:
    return "OGR Error %d: General Error";
  case 6:
    return "OGR Error %d: Unsupported SRS";
  default:
    return "OGR Error %d: Unknown";
  }
}

static OGRLayerShadow *OGRDataSourceShadow_CreateLayer(OGRDataSourceShadow *self,char const *name,OSRSpatialReferenceShadow *reference=NULL,OGRwkbGeometryType geom_type=wkbUnknown,char **options=0){
    OGRLayerShadow* layer = (OGRLayerShadow*) OGR_DS_CreateLayer( self,
                                                        name,
                                                        reference,
                                                        geom_type,
                                                        options);
    return layer;
  }
static OGRLayerShadow *OGRDataSourceShadow_CopyLayer(OGRDataSourceShadow *self,OGRLayerShadow *src_layer,char const *new_name,char **options=0){
    OGRLayerShadow* layer = (OGRLayerShadow*) OGR_DS_CopyLayer( self,
                                                      src_layer,
                                                      new_name,
                                                      options);
    return layer;
  }
static OGRLayerShadow *OGRDataSourceShadow_GetLayerByIndex(OGRDataSourceShadow *self,int index=0){
    OGRLayerShadow* layer = (OGRLayerShadow*) OGR_DS_GetLayer(self, index);
    return layer;
  }
static OGRLayerShadow *OGRDataSourceShadow_GetLayerByName(OGRDataSourceShadow *self,char const *layer_name){
    OGRLayerShadow* layer = (OGRLayerShadow*) OGR_DS_GetLayerByName(self, layer_name);
    return layer;
  }
static int OGRDataSourceShadow_TestCapability(OGRDataSourceShadow *self,char const *cap){
    return OGR_DS_TestCapability(self, cap);
  }
static OGRLayerShadow *OGRDataSourceShadow_ExecuteSQL(OGRDataSourceShadow *self,char const *statement,OGRGeometryShadow *geom=NULL,char const *dialect=""){
    OGRLayerShadow* layer = (OGRLayerShadow*) OGR_DS_ExecuteSQL((OGRDataSourceShadow*)self,
                                                      statement,
                                                      geom,
                                                      dialect);
    return layer;
  }
static void OGRDataSourceShadow_ReleaseResultSet(OGRDataSourceShadow *self,OGRLayerShadow *layer){
    OGR_DS_ReleaseResultSet(self, layer);
  }
static int OGRLayerShadow_Reference(OGRLayerShadow *self){
    return OGR_L_Reference(self);
  }
static int OGRLayerShadow_Dereference(OGRLayerShadow *self){
    return OGR_L_Dereference(self);
  }
static int OGRLayerShadow_GetRefCount(OGRLayerShadow *self){
    return OGR_L_GetRefCount(self);
  }
static void OGRLayerShadow_SetSpatialFilter(OGRLayerShadow *self,OGRGeometryShadow *filter){
    OGR_L_SetSpatialFilter (self, filter);
  }

SWIGINTERN int
  SWIG_AsVal_double(PyObject *obj, double *val)
{
  if (PyFloat_Check(obj)) {
    if (val) *val = PyFloat_AS_DOUBLE(obj);
    return 1;
  }  
  if (PyInt_Check(obj)) {
    if (val) *val = PyInt_AS_LONG(obj);
    return 1;
  }
  if (PyLong_Check(obj)) {
    double v = PyLong_AsDouble(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return 1;
    } else {
      if (!val) PyErr_Clear();
      return 0;
    }
  }
  if (val) {
    SWIG_type_error("double", obj);
  }
  return 0;
}


SWIGINTERNINLINE double
SWIG_As_double(PyObject* obj)
{
  double v;
  if (!SWIG_AsVal_double(obj, &v)) {
    /*
      this is needed to make valgrind/purify happier. 
     */
    memset((void*)&v, 0, sizeof(double));
  }
  return v;
}

  
SWIGINTERNINLINE int
SWIG_Check_double(PyObject* obj)
{
  return SWIG_AsVal_double(obj, (double*)0);
}

static void OGRLayerShadow_SetSpatialFilterRect(OGRLayerShadow *self,double minx,double miny,double maxx,double maxy){
    OGR_L_SetSpatialFilterRect(self, minx, miny, maxx, maxy);                          
  }
static OGRGeometryShadow *OGRLayerShadow_GetSpatialFilter(OGRLayerShadow *self){
    return (OGRGeometryShadow *) OGR_L_GetSpatialFilter(self);
  }
static OGRErr OGRLayerShadow_SetAttributeFilter(OGRLayerShadow *self,char *filter_string){
    OGRErr err = OGR_L_SetAttributeFilter((OGRLayerShadow*)self, filter_string);
    if (err != 0) {
      throw err;
    } 
    return 0;
  }
static void OGRLayerShadow_ResetReading(OGRLayerShadow *self){
    OGR_L_ResetReading(self);
  }
static char const *OGRLayerShadow_GetName(OGRLayerShadow *self){
    return OGR_FD_GetName(OGR_L_GetLayerDefn(self));
  }

SWIGINTERNINLINE long
SWIG_As_long(PyObject* obj)
{
  long v;
  if (!SWIG_AsVal_long(obj, &v)) {
    /*
      this is needed to make valgrind/purify happier. 
     */
    memset((void*)&v, 0, sizeof(long));
  }
  return v;
}

  
SWIGINTERNINLINE int
SWIG_Check_long(PyObject* obj)
{
  return SWIG_AsVal_long(obj, (long*)0);
}

static OGRFeatureShadow *OGRLayerShadow_GetFeature(OGRLayerShadow *self,long fid){
    return (OGRFeatureShadow*) OGR_L_GetFeature(self, fid);
  }
static OGRFeatureShadow *OGRLayerShadow_GetNextFeature(OGRLayerShadow *self){
    return (OGRFeatureShadow*) OGR_L_GetNextFeature(self);
  }
static OGRErr OGRLayerShadow_SetNextByIndex(OGRLayerShadow *self,long new_index){
    OGRErr err = OGR_L_SetNextByIndex(self, new_index);
    if (err != 0) {
      throw err;
    }
    return 0;
  }
static OGRErr OGRLayerShadow_SetFeature(OGRLayerShadow *self,OGRFeatureShadow *feature){
    OGRErr err = OGR_L_SetFeature(self, feature);
    if (err != 0) {
      throw err;
    }
    return 0;
  }
static OGRErr OGRLayerShadow_CreateFeature(OGRLayerShadow *self,OGRFeatureShadow *feature){
    OGRErr err = OGR_L_CreateFeature(self, feature);
    if (err != 0) {
      throw err;
    }
    return 0;
  }
static OGRErr OGRLayerShadow_DeleteFeature(OGRLayerShadow *self,long fid){
    OGRErr err = OGR_L_DeleteFeature(self, fid);
    if (err != 0) {
      throw err;
    }
    return 0;
  }
static OGRErr OGRLayerShadow_SyncToDisk(OGRLayerShadow *self){
    OGRErr err = OGR_L_SyncToDisk(self);
    if (err != 0) {
      throw err;
    }
    return 0;
  }
static OGRFeatureDefnShadow *OGRLayerShadow_GetLayerDefn(OGRLayerShadow *self){
    return (OGRFeatureDefnShadow*) OGR_L_GetLayerDefn(self);
  }
static int OGRLayerShadow_GetFeatureCount(OGRLayerShadow *self,int force=1){
    return OGR_L_GetFeatureCount(self, force);
  }

SWIGINTERN PyObject*
t_output_helper(PyObject* target, PyObject* o) {
  if (!target) {
    target = o;
  } else if (target == Py_None) {  
    Py_DECREF(target);
    target = o;
  } else {
    if (!PyList_Check(target)) {
      PyObject *o2 = target;
      target = PyList_New(1);
      PyList_SetItem(target, 0, o2);
    }
    PyList_Append(target,o);
    Py_DECREF(o);
    }
  return target;
}


static PyObject *
CreateTupleFromDoubleArray( double *first, unsigned int size ) {
  PyObject *out = PyTuple_New( size );
  for( unsigned int i=0; i<size; i++ ) {
    PyObject *val = PyFloat_FromDouble( *first );
    ++first;
    PyTuple_SetItem( out, i, val );
  }
  return out;
}

static void OGRLayerShadow_GetExtent(OGRLayerShadow *self,double argout[4],int force=1){
    OGRErr err = OGR_L_GetExtent(self, (OGREnvelope*)argout, force);
    if (err != 0)
      throw err;
  }
static int OGRLayerShadow_TestCapability(OGRLayerShadow *self,char const *cap){
    return OGR_L_TestCapability(self, cap);
  }
static OGRErr OGRLayerShadow_CreateField(OGRLayerShadow *self,OGRFieldDefnShadow *field_def,int approx_ok=1){
    OGRErr err = OGR_L_CreateField(self, field_def, approx_ok);
    if (err != 0)
      throw err;
    return 0;
  }
static OGRErr OGRLayerShadow_StartTransaction(OGRLayerShadow *self){
    OGRErr err = OGR_L_StartTransaction(self);
    if (err != 0)
      throw err;
    return 0;
  }
static OGRErr OGRLayerShadow_CommitTransaction(OGRLayerShadow *self){
    OGRErr err = OGR_L_CommitTransaction(self);
    if (err != 0)
      throw err;
    return 0;
  }
static OGRErr OGRLayerShadow_RollbackTransaction(OGRLayerShadow *self){
    OGRErr err = OGR_L_RollbackTransaction(self);
    if (err != 0)
      throw err;
    return 0;
  }
static OSRSpatialReferenceShadow *OGRLayerShadow_GetSpatialRef(OGRLayerShadow *self){
    return (OSRSpatialReferenceShadow*) OGR_L_GetSpatialRef(self);
  }
static GIntBig OGRLayerShadow_GetFeatureRead(OGRLayerShadow *self){
    return OGR_L_GetFeaturesRead(self);
  }
static OGRFeatureShadow *new_OGRFeatureShadow(OGRFeatureDefnShadow *feature_def=0){
    return (OGRFeatureShadow*) OGR_F_Create( feature_def );
  }
static void OGRFeatureShadow_Destroy(OGRFeatureShadow *self){
    OGR_F_Destroy(self);
  }
static OGRFeatureDefnShadow *OGRFeatureShadow_GetDefnRef(OGRFeatureShadow *self){
    return (OGRFeatureDefnShadow*) OGR_F_GetDefnRef(self);
  }
static OGRErr OGRFeatureShadow_SetGeometry(OGRFeatureShadow *self,OGRGeometryShadow *geom){
    OGRErr err = OGR_F_SetGeometry(self, geom);
    if (err != 0)
      throw err;
    return 0;
  }
static OGRErr OGRFeatureShadow_SetGeometryDirectly(OGRFeatureShadow *self,OGRGeometryShadow *geom){
    OGRErr err = OGR_F_SetGeometryDirectly(self, geom);
    if (err != 0)
      throw err;
    return 0;
  }
static OGRGeometryShadow *OGRFeatureShadow_GetGeometryRef(OGRFeatureShadow *self){
    return (OGRGeometryShadow*) OGR_F_GetGeometryRef(self);
  }
static OGRFeatureShadow *OGRFeatureShadow_Clone(OGRFeatureShadow *self){
    return (OGRFeatureShadow*) OGR_F_Clone(self);
  }
static int OGRFeatureShadow_Equal(OGRFeatureShadow *self,OGRFeatureShadow *feature){
    return OGR_F_Equal(self, feature);
  }
static int OGRFeatureShadow_GetFieldCount(OGRFeatureShadow *self){
    return OGR_F_GetFieldCount(self);
  }
static OGRFieldDefnShadow *OGRFeatureShadow_GetFieldDefnRef__SWIG_0(OGRFeatureShadow *self,int id){
    return (OGRFieldDefnShadow *) OGR_F_GetFieldDefnRef(self, id);
  }
static OGRFieldDefnShadow *OGRFeatureShadow_GetFieldDefnRef__SWIG_1(OGRFeatureShadow *self,char const *name){
    return (OGRFieldDefnShadow *) OGR_F_GetFieldDefnRef(self, OGR_F_GetFieldIndex(self, name));
  }
static char const *OGRFeatureShadow_GetFieldAsString__SWIG_0(OGRFeatureShadow *self,int id){
    return (const char *) OGR_F_GetFieldAsString(self, id);
  }
static char const *OGRFeatureShadow_GetFieldAsString__SWIG_1(OGRFeatureShadow *self,char const *name){
    return (const char *) OGR_F_GetFieldAsString(self, OGR_F_GetFieldIndex(self, name));
  }
static int OGRFeatureShadow_GetFieldAsInteger__SWIG_0(OGRFeatureShadow *self,int id){
    return OGR_F_GetFieldAsInteger(self, id);
  }
static int OGRFeatureShadow_GetFieldAsInteger__SWIG_1(OGRFeatureShadow *self,char const *name){
    return OGR_F_GetFieldAsInteger(self, OGR_F_GetFieldIndex(self, name));
  }
static double OGRFeatureShadow_GetFieldAsDouble__SWIG_0(OGRFeatureShadow *self,int id){
    return OGR_F_GetFieldAsDouble(self, id);
  }

  /*@/home/kruland/opt/share/swig/1.3.25/python/pymacros.swg,66,SWIG_define@*/
#define SWIG_From_double PyFloat_FromDouble
/*@@*/

static double OGRFeatureShadow_GetFieldAsDouble__SWIG_1(OGRFeatureShadow *self,char const *name){
    return OGR_F_GetFieldAsDouble(self, OGR_F_GetFieldIndex(self, name));
  }
static int OGRFeatureShadow_IsFieldSet__SWIG_0(OGRFeatureShadow *self,int id){
    return OGR_F_IsFieldSet(self, id);
  }
static int OGRFeatureShadow_IsFieldSet__SWIG_1(OGRFeatureShadow *self,char const *name){
    return OGR_F_IsFieldSet(self, OGR_F_GetFieldIndex(self, name));
  }
static int OGRFeatureShadow_GetFieldIndex(OGRFeatureShadow *self,char const *name){
    return OGR_F_GetFieldIndex(self, name);
  }
static int OGRFeatureShadow_GetFID(OGRFeatureShadow *self){
    return OGR_F_GetFID(self);
  }
static OGRErr OGRFeatureShadow_SetFID(OGRFeatureShadow *self,int fid){
    OGRErr err = OGR_F_SetFID(self, fid);
    if (err != 0)
      throw err;
    return 0;
  }
static void OGRFeatureShadow_DumpReadable(OGRFeatureShadow *self){
    OGR_F_DumpReadable(self, NULL);
  }
static void OGRFeatureShadow_UnsetField__SWIG_0(OGRFeatureShadow *self,int id){
    OGR_F_UnsetField(self, id);
  }
static void OGRFeatureShadow_UnsetField__SWIG_1(OGRFeatureShadow *self,char const *name){
    OGR_F_UnsetField(self, OGR_F_GetFieldIndex(self, name));
  }
static void OGRFeatureShadow_SetField__SWIG_0(OGRFeatureShadow *self,int id,char const *value){
    OGR_F_SetFieldString(self, id, value);
  }
static void OGRFeatureShadow_SetField__SWIG_1(OGRFeatureShadow *self,char const *name,char const *value){
    OGR_F_SetFieldString(self, OGR_F_GetFieldIndex(self, name), value);
  }
static OGRErr OGRFeatureShadow_SetFrom(OGRFeatureShadow *self,OGRFeatureShadow *other,int forgiving=1){
    OGRErr err = OGR_F_SetFrom(self, other, forgiving);
    if (err != 0)
      throw err;
    return 0;
  }
static char const *OGRFeatureShadow_GetStyleString(OGRFeatureShadow *self){
    return (const char*) OGR_F_GetStyleString(self);
  }
static void OGRFeatureShadow_SetStyleString(OGRFeatureShadow *self,char const *the_string){
    OGR_F_SetStyleString(self, the_string);
  }
static OGRFieldType OGRFeatureShadow_GetFieldType__SWIG_0(OGRFeatureShadow *self,int id){
    return (OGRFieldType) OGR_Fld_GetType( OGR_F_GetFieldDefnRef( self, id));
  }
static OGRFieldType OGRFeatureShadow_GetFieldType__SWIG_1(OGRFeatureShadow *self,char const *name,char const *value){
    return (OGRFieldType) OGR_Fld_GetType( 
                            OGR_F_GetFieldDefnRef( self,  
                                                   OGR_F_GetFieldIndex(self, 
                                                                       name)
                                                  )
                                          );
    
  }
static OGRFeatureDefnShadow *new_OGRFeatureDefnShadow(char const *name=NULL){
    return (OGRFeatureDefnShadow* )OGR_FD_Create(name);
  }
static void OGRFeatureDefnShadow_Destroy(OGRFeatureDefnShadow *self){
    OGR_FD_Destroy(self);
  }
static char const *OGRFeatureDefnShadow_GetName(OGRFeatureDefnShadow *self){
    return OGR_FD_GetName(self);
  }
static int OGRFeatureDefnShadow_GetFieldCount(OGRFeatureDefnShadow *self){
    return OGR_FD_GetFieldCount(self);
  }
static OGRFieldDefnShadow *OGRFeatureDefnShadow_GetFieldDefn(OGRFeatureDefnShadow *self,int i){
    return (OGRFieldDefnShadow*) OGR_FD_GetFieldDefn(self, i);
  }
static int OGRFeatureDefnShadow_GetFieldIndex(OGRFeatureDefnShadow *self,char const *name){
    return OGR_FD_GetFieldIndex(self, name);
  }
static void OGRFeatureDefnShadow_AddFieldDefn(OGRFeatureDefnShadow *self,OGRFieldDefnShadow *defn){
    OGR_FD_AddFieldDefn(self, defn);
  }
static OGRwkbGeometryType OGRFeatureDefnShadow_GetGeomType(OGRFeatureDefnShadow *self){
    return (OGRwkbGeometryType) OGR_FD_GetGeomType(self);
  }
static void OGRFeatureDefnShadow_SetGeomType(OGRFeatureDefnShadow *self,OGRwkbGeometryType geom_type){
    OGR_FD_SetGeomType(self, geom_type);
  }
static int OGRFeatureDefnShadow_Reference(OGRFeatureDefnShadow *self){
    return OGR_FD_Reference(self);
  }
static int OGRFeatureDefnShadow_Dereference(OGRFeatureDefnShadow *self){
    return OGR_FD_Dereference(self);
  }
static int OGRFeatureDefnShadow_GetReferenceCount(OGRFeatureDefnShadow *self){
    return OGR_FD_GetReferenceCount(self);
  }
static OGRFieldDefnShadow *new_OGRFieldDefnShadow(char const *name="unnamed",OGRFieldType field_type=OFTString){
    return (OGRFieldDefnShadow*) OGR_Fld_Create(name, field_type);
  }
static void OGRFieldDefnShadow_Destroy(OGRFieldDefnShadow *self){
    OGR_Fld_Destroy(self);
  }
static char const *OGRFieldDefnShadow_GetName(OGRFieldDefnShadow *self){
    return (const char *) OGR_Fld_GetNameRef(self);
  }
static char const *OGRFieldDefnShadow_GetNameRef(OGRFieldDefnShadow *self){
    return (const char *) OGR_Fld_GetNameRef(self);
  }
static void OGRFieldDefnShadow_SetName(OGRFieldDefnShadow *self,char const *name){
    OGR_Fld_SetName(self, name);
  }
static OGRFieldType OGRFieldDefnShadow_GetType(OGRFieldDefnShadow *self){
    return OGR_Fld_GetType(self);
  }
static void OGRFieldDefnShadow_SetType(OGRFieldDefnShadow *self,OGRFieldType type){
    OGR_Fld_SetType(self, type);
  }
static OGRJustification OGRFieldDefnShadow_GetJustify(OGRFieldDefnShadow *self){
    return OGR_Fld_GetJustify(self);
  }
static void OGRFieldDefnShadow_SetJustify(OGRFieldDefnShadow *self,OGRJustification justify){
    OGR_Fld_SetJustify(self, justify);
  }
static int OGRFieldDefnShadow_GetWidth(OGRFieldDefnShadow *self){
    return OGR_Fld_GetWidth(self);
  }
static void OGRFieldDefnShadow_SetWidth(OGRFieldDefnShadow *self,int width){
    OGR_Fld_SetWidth(self, width);
  }
static int OGRFieldDefnShadow_GetPrecision(OGRFieldDefnShadow *self){
    return OGR_Fld_GetPrecision(self);
  }
static void OGRFieldDefnShadow_SetPrecision(OGRFieldDefnShadow *self,int precision){
    OGR_Fld_SetPrecision(self, precision);
  }

  OGRGeometryShadow* CreateGeometryFromWkb( int len, char *bin_string, 
                                            OSRSpatialReferenceShadow *reference=NULL ) {
    void *geom;
    OGRErr err = OGR_G_CreateFromWkb( (unsigned char *) bin_string,
                                      reference,
                                      &geom,
                                      len );
    if (err != 0 )
       throw err;
    return (OGRGeometryShadow*) geom;
  }
 


  OGRGeometryShadow* CreateGeometryFromWkt( char **val, 
                                      OSRSpatialReferenceShadow *reference=NULL ) {
    void *geom;
    OGRErr err = OGR_G_CreateFromWkt(val,
                                      reference,
                                      &geom);
    if (err != 0 )
       throw err;
    return (OGRGeometryShadow*) geom;
  }
 


  OGRGeometryShadow *CreateGeometryFromGML( const char * input_string ) {
    OGRGeometryShadow* geom = (OGRGeometryShadow*)OGR_G_CreateFromGML(input_string);
    return geom;
  }
 

static OGRGeometryShadow *new_OGRGeometryShadow(OGRwkbGeometryType type=wkbUnknown,char *wkt=0,int wkb=0,char *wkb_buf=0,char *gml=0){
    if (type != wkbUnknown ) {
      return (OGRGeometryShadow*) OGR_G_CreateGeometry( type );
    }
    else if ( wkt != 0 ) {
      return CreateGeometryFromWkt( &wkt );
    }
    else if ( wkb != 0 ) {
      return CreateGeometryFromWkb( wkb, wkb_buf );
    }
    else if ( gml != 0 ) {
      return CreateGeometryFromGML( gml );
    }
    // throw?
    else return 0;
  }
static char const *OGRGeometryShadow_ExportToWkt(OGRGeometryShadow *self){
    char * output;
    OGRErr err = OGR_G_ExportToWkt(self, &output);
    if (err != 0) 
      throw err;
    return output;
  }
static OGRErr OGRGeometryShadow_ExportToWkb(OGRGeometryShadow *self,int *nLen,char **pBuf,OGRwkbByteOrder byte_order=wkbXDR){
    *nLen = OGR_G_WkbSize( self );
    *pBuf = (char *) malloc( *nLen * sizeof(unsigned char) );
    return OGR_G_ExportToWkb(self, byte_order, (unsigned char*) *pBuf );
  }
static char const *OGRGeometryShadow_ExportToGML(OGRGeometryShadow *self){
    return (const char *) OGR_G_ExportToGML(self);
  }
static void OGRGeometryShadow_AddPoint(OGRGeometryShadow *self,double x,double y,double z=0){
    OGR_G_AddPoint( self, x, y, z );
  }
static OGRErr OGRGeometryShadow_AddGeometryDirectly(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_AddGeometryDirectly( self, other );
  }
static OGRErr OGRGeometryShadow_AddGeometry(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_AddGeometry( self, other );
  }
static OGRGeometryShadow *OGRGeometryShadow_Clone(OGRGeometryShadow *self){
    return (OGRGeometryShadow*) OGR_G_Clone(self);
  }
static void OGRGeometryShadow_Destroy(OGRGeometryShadow *self){
    OGR_G_DestroyGeometry( self );
  }
static OGRwkbGeometryType OGRGeometryShadow_GetGeometryType(OGRGeometryShadow *self){
    return (OGRwkbGeometryType) OGR_G_GetGeometryType(self);
  }
static char const *OGRGeometryShadow_GetGeometryName(OGRGeometryShadow *self){
    return (const char *) OGR_G_GetGeometryName(self);
  }
static double OGRGeometryShadow_GetArea(OGRGeometryShadow *self){
    return OGR_G_GetArea(self);
  }
static int OGRGeometryShadow_GetPointCount(OGRGeometryShadow *self){
    return OGR_G_GetPointCount(self);
  }
static double OGRGeometryShadow_GetX(OGRGeometryShadow *self,int point=0){
    return OGR_G_GetX(self, point);
  }
static double OGRGeometryShadow_GetY(OGRGeometryShadow *self,int point=0){
    return OGR_G_GetY(self, point);
  }
static double OGRGeometryShadow_GetZ(OGRGeometryShadow *self,int point=0){
    return OGR_G_GetZ(self, point);
  }
static int OGRGeometryShadow_GetGeometryCount(OGRGeometryShadow *self){
    return OGR_G_GetGeometryCount(self);
  }
static void OGRGeometryShadow_SetPoint(OGRGeometryShadow *self,int point,double x,double y,double z=0){
    OGR_G_SetPoint(self, point, x, y, z);
  }
static OGRGeometryShadow *OGRGeometryShadow_GetGeometryRef(OGRGeometryShadow *self,int geom){
    return (OGRGeometryShadow*) OGR_G_GetGeometryRef(self, geom);
  }
static OGRGeometryShadow *OGRGeometryShadow_GetBoundary(OGRGeometryShadow *self){
    return (OGRGeometryShadow*) OGR_G_GetBoundary(self);
  }
static OGRGeometryShadow *OGRGeometryShadow_ConvexHull(OGRGeometryShadow *self){
    return (OGRGeometryShadow*) OGR_G_ConvexHull(self);
  }
static OGRGeometryShadow *OGRGeometryShadow_Buffer(OGRGeometryShadow *self,double distance,int quadsecs=30){
    return (OGRGeometryShadow*) OGR_G_Buffer( self, distance, quadsecs );
  }
static OGRGeometryShadow *OGRGeometryShadow_Intersection(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGRGeometryShadow*) OGR_G_Intersection( self, other );
  }
static OGRGeometryShadow *OGRGeometryShadow_Union(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGRGeometryShadow*) OGR_G_Union( self, other );
  }
static OGRGeometryShadow *OGRGeometryShadow_Difference(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGRGeometryShadow*) OGR_G_Difference( self, other );
  }
static OGRGeometryShadow *OGRGeometryShadow_SymmetricDifference(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGRGeometryShadow*) OGR_G_SymmetricDifference( self, other );
  }
static double OGRGeometryShadow_Distance(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_Distance(self, other);
  }
static void OGRGeometryShadow_Empty(OGRGeometryShadow *self){
    OGR_G_Empty(self);
  }
static int OGRGeometryShadow_Intersect(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_Intersect(self, other);
  }
static int OGRGeometryShadow_Equal(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_Equal(self, other);
  }
static int OGRGeometryShadow_Disjoint(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_Disjoint(self, other);
  }
static int OGRGeometryShadow_Touches(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_Touches(self, other);
  }
static int OGRGeometryShadow_Crosses(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_Crosses(self, other);
  }
static int OGRGeometryShadow_Within(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_Within(self, other);
  }
static int OGRGeometryShadow_Contains(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_Contains(self, other);
  }
static int OGRGeometryShadow_Overlaps(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_Overlaps(self, other);
  }
static OGRErr OGRGeometryShadow_TransformTo(OGRGeometryShadow *self,OSRSpatialReferenceShadow *reference){
    return OGR_G_TransformTo(self, reference);
  }
static OGRErr OGRGeometryShadow_Transform(OGRGeometryShadow *self,OSRCoordinateTransformationShadow *trans){
    return OGR_G_Transform(self, trans);
  }
static OSRSpatialReferenceShadow *OGRGeometryShadow_GetSpatialReference(OGRGeometryShadow *self){
    return (OSRSpatialReferenceShadow*)OGR_G_GetSpatialReference(self);
  }
static void OGRGeometryShadow_AssignSpatialReference(OGRGeometryShadow *self,OSRSpatialReferenceShadow *reference){
    OGR_G_AssignSpatialReference(self, reference);
  }
static void OGRGeometryShadow_CloseRings(OGRGeometryShadow *self){
    OGR_G_CloseRings(self);
  }
static void OGRGeometryShadow_FlattenTo2D(OGRGeometryShadow *self){
    OGR_G_FlattenTo2D(self);
  }
static void OGRGeometryShadow_GetEnvelope(OGRGeometryShadow *self,double argout[4]){
    OGR_G_GetEnvelope(self, (OGREnvelope*)argout);
  }
static OGRGeometryShadow *OGRGeometryShadow_Centroid(OGRGeometryShadow *self){
    OGRGeometryShadow *pt = new_OGRGeometryShadow( wkbPoint );
    OGRErr rcode = OGR_G_Centroid( self, pt );
    return pt;
  }
static int OGRGeometryShadow_WkbSize(OGRGeometryShadow *self){
    return OGR_G_WkbSize(self);
  }
static int OGRGeometryShadow_GetCoordinateDimension(OGRGeometryShadow *self){
    return OGR_G_GetCoordinateDimension(self);
  }
static int OGRGeometryShadow_GetDimension(OGRGeometryShadow *self){
    return OGR_G_GetDimension(self);
  }

char const *OGRDriverShadow_get_name( OGRDriverShadow *h ) {
  return OGR_Dr_GetName( h );
}

char const *OGRDataSourceShadow_get_name( OGRDataSourceShadow *h ) {
  return OGR_DS_GetName( h );
}

char const *OGRDriverShadow_name_get( OGRDriverShadow *h ) {
  return OGR_Dr_GetName( h );
}

char const *OGRDataSourceShadow_name_get( OGRDataSourceShadow *h ) {
  return OGR_DS_GetName( h );
}


OGRDriverShadow* GetDriverByName( char const *name ) {
  return (OGRDriverShadow*) OGRGetDriverByName( name );
}
  
OGRDriverShadow* GetDriver(int driver_number) {
  return (OGRDriverShadow*) OGRGetDriver(driver_number);
  

}


  OGRDataSourceShadow* GetOpenDS(int ds_number) {
    OGRDataSourceShadow* layer = (OGRDataSourceShadow*) OGRGetOpenDS(ds_number);
    return layer;
  }


  OGRDataSourceShadow *Open( const char * filename, int update=0 ) {
    OGRDataSourceShadow* ds = (OGRDataSourceShadow*)OGROpen(filename,update, NULL);
    return ds;
  }
 


  OGRDataSourceShadow *OpenShared( const char * filename, int update=0 ) {
    OGRDataSourceShadow* ds = (OGRDataSourceShadow*)OGROpenShared(filename,update, NULL);
    return ds;
  }
 

#ifdef __cplusplus
extern "C" {
#endif
static PyObject *_wrap_Driver_name_get(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Driver_name_get",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDriverShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRDriverShadow_name_get(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Driver_CreateDataSource(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    char **arg3 = (char **) 0 ;
    OGRDataSourceShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "name",(char *) "options", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|O:Driver_CreateDataSource",kwnames,&obj0,&obj1,&obj2)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDriverShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    if (obj2) {
        {
            /* %typemap(in) char **options */
            /* Check if is a list */
            if ( ! PySequence_Check(obj2)) {
                PyErr_SetString(PyExc_TypeError,"not a sequence");
                SWIG_fail;
            }
            
            int size = PySequence_Size(obj2);
            for (int i = 0; i < size; i++) {
                char *pszItem = NULL;
                if ( ! PyArg_Parse( PySequence_GetItem(obj2,i), "s", &pszItem ) ) {
                    PyErr_SetString(PyExc_TypeError,"sequence must contain strings");
                    SWIG_fail;
                }
                arg3 = CSLAddString( arg3, pszItem );
            }
        }
    }
    result = (OGRDataSourceShadow *)OGRDriverShadow_CreateDataSource(arg1,(char const *)arg2,arg3);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRDataSourceShadow, 1);
    {
        /* %typemap(freearg) char **options */
        CSLDestroy( arg3 );
    }
    return resultobj;
    fail:
    {
        /* %typemap(freearg) char **options */
        CSLDestroy( arg3 );
    }
    return NULL;
}


static PyObject *_wrap_Driver_CopyDataSource(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
    OGRDataSourceShadow *arg2 = (OGRDataSourceShadow *) 0 ;
    char *arg3 = (char *) 0 ;
    char **arg4 = (char **) 0 ;
    OGRDataSourceShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    PyObject * obj3 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "copy_ds",(char *) "name",(char *) "options", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OOO|O:Driver_CopyDataSource",kwnames,&obj0,&obj1,&obj2,&obj3)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDriverShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj2, (char**)&arg3)) {
        SWIG_arg_fail(3);SWIG_fail;
    }
    if (obj3) {
        {
            /* %typemap(in) char **options */
            /* Check if is a list */
            if ( ! PySequence_Check(obj3)) {
                PyErr_SetString(PyExc_TypeError,"not a sequence");
                SWIG_fail;
            }
            
            int size = PySequence_Size(obj3);
            for (int i = 0; i < size; i++) {
                char *pszItem = NULL;
                if ( ! PyArg_Parse( PySequence_GetItem(obj3,i), "s", &pszItem ) ) {
                    PyErr_SetString(PyExc_TypeError,"sequence must contain strings");
                    SWIG_fail;
                }
                arg4 = CSLAddString( arg4, pszItem );
            }
        }
    }
    result = (OGRDataSourceShadow *)OGRDriverShadow_CopyDataSource(arg1,arg2,(char const *)arg3,arg4);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRDataSourceShadow, 1);
    {
        /* %typemap(freearg) char **options */
        CSLDestroy( arg4 );
    }
    return resultobj;
    fail:
    {
        /* %typemap(freearg) char **options */
        CSLDestroy( arg4 );
    }
    return NULL;
}


static PyObject *_wrap_Driver_Open(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    int arg3 = (int) 0 ;
    OGRDataSourceShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "name",(char *) "update", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|O:Driver_Open",kwnames,&obj0,&obj1,&obj2)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDriverShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    if (obj2) {
        {
            arg3 = (int)(SWIG_As_int(obj2)); 
            if (SWIG_arg_fail(3)) SWIG_fail;
        }
    }
    result = (OGRDataSourceShadow *)OGRDriverShadow_Open(arg1,(char const *)arg2,arg3);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRDataSourceShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Driver_DeleteDataSource(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Driver_DeleteDataSource",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDriverShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (int)OGRDriverShadow_DeleteDataSource(arg1,(char const *)arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Driver_TestCapability(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Driver_TestCapability",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDriverShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (int)OGRDriverShadow_TestCapability(arg1,(char const *)arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Driver_GetName(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Driver_GetName",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDriverShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRDriverShadow_GetName(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject * Driver_swigregister(PyObject *, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_OGRDriverShadow, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_DataSource_name_get(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:DataSource_name_get",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRDataSourceShadow_name_get(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_Destroy(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:DataSource_Destroy",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRDataSourceShadow_Destroy(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_Release(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:DataSource_Release",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRDataSourceShadow_Release(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_Reference(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:DataSource_Reference",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRDataSourceShadow_Reference(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_Dereference(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:DataSource_Dereference",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRDataSourceShadow_Dereference(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_GetRefCount(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:DataSource_GetRefCount",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRDataSourceShadow_GetRefCount(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_GetSummaryRefCount(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:DataSource_GetSummaryRefCount",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRDataSourceShadow_GetSummaryRefCount(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_GetLayerCount(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:DataSource_GetLayerCount",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRDataSourceShadow_GetLayerCount(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_GetName(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:DataSource_GetName",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRDataSourceShadow_GetName(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_DeleteLayer(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    int arg2 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:DataSource_DeleteLayer",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (OGRErr)OGRDataSourceShadow_DeleteLayer(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_CreateLayer(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    OSRSpatialReferenceShadow *arg3 = (OSRSpatialReferenceShadow *) NULL ;
    OGRwkbGeometryType arg4 = (OGRwkbGeometryType) wkbUnknown ;
    char **arg5 = (char **) 0 ;
    OGRLayerShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    PyObject * obj3 = 0 ;
    PyObject * obj4 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "name",(char *) "reference",(char *) "geom_type",(char *) "options", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|OOO:DataSource_CreateLayer",kwnames,&obj0,&obj1,&obj2,&obj3,&obj4)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    if (obj2) {
        SWIG_Python_ConvertPtr(obj2, (void **)&arg3, SWIGTYPE_p_OSRSpatialReferenceShadow, SWIG_POINTER_EXCEPTION | 0);
        if (SWIG_arg_fail(3)) SWIG_fail;
    }
    if (obj3) {
        {
            arg4 = (OGRwkbGeometryType)(SWIG_As_int(obj3)); 
            if (SWIG_arg_fail(4)) SWIG_fail;
        }
    }
    if (obj4) {
        {
            /* %typemap(in) char **options */
            /* Check if is a list */
            if ( ! PySequence_Check(obj4)) {
                PyErr_SetString(PyExc_TypeError,"not a sequence");
                SWIG_fail;
            }
            
            int size = PySequence_Size(obj4);
            for (int i = 0; i < size; i++) {
                char *pszItem = NULL;
                if ( ! PyArg_Parse( PySequence_GetItem(obj4,i), "s", &pszItem ) ) {
                    PyErr_SetString(PyExc_TypeError,"sequence must contain strings");
                    SWIG_fail;
                }
                arg5 = CSLAddString( arg5, pszItem );
            }
        }
    }
    result = (OGRLayerShadow *)OGRDataSourceShadow_CreateLayer(arg1,(char const *)arg2,arg3,arg4,arg5);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRLayerShadow, 0);
    {
        /* %typemap(freearg) char **options */
        CSLDestroy( arg5 );
    }
    return resultobj;
    fail:
    {
        /* %typemap(freearg) char **options */
        CSLDestroy( arg5 );
    }
    return NULL;
}


static PyObject *_wrap_DataSource_CopyLayer(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    OGRLayerShadow *arg2 = (OGRLayerShadow *) 0 ;
    char *arg3 = (char *) 0 ;
    char **arg4 = (char **) 0 ;
    OGRLayerShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    PyObject * obj3 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "src_layer",(char *) "new_name",(char *) "options", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OOO|O:DataSource_CopyLayer",kwnames,&obj0,&obj1,&obj2,&obj3)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj2, (char**)&arg3)) {
        SWIG_arg_fail(3);SWIG_fail;
    }
    if (obj3) {
        {
            /* %typemap(in) char **options */
            /* Check if is a list */
            if ( ! PySequence_Check(obj3)) {
                PyErr_SetString(PyExc_TypeError,"not a sequence");
                SWIG_fail;
            }
            
            int size = PySequence_Size(obj3);
            for (int i = 0; i < size; i++) {
                char *pszItem = NULL;
                if ( ! PyArg_Parse( PySequence_GetItem(obj3,i), "s", &pszItem ) ) {
                    PyErr_SetString(PyExc_TypeError,"sequence must contain strings");
                    SWIG_fail;
                }
                arg4 = CSLAddString( arg4, pszItem );
            }
        }
    }
    result = (OGRLayerShadow *)OGRDataSourceShadow_CopyLayer(arg1,arg2,(char const *)arg3,arg4);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRLayerShadow, 0);
    {
        /* %typemap(freearg) char **options */
        CSLDestroy( arg4 );
    }
    return resultobj;
    fail:
    {
        /* %typemap(freearg) char **options */
        CSLDestroy( arg4 );
    }
    return NULL;
}


static PyObject *_wrap_DataSource_GetLayerByIndex(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    int arg2 = (int) 0 ;
    OGRLayerShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "index", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:DataSource_GetLayerByIndex",kwnames,&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (obj1) {
        {
            arg2 = (int)(SWIG_As_int(obj1)); 
            if (SWIG_arg_fail(2)) SWIG_fail;
        }
    }
    result = (OGRLayerShadow *)OGRDataSourceShadow_GetLayerByIndex(arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRLayerShadow, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_GetLayerByName(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    OGRLayerShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:DataSource_GetLayerByName",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (OGRLayerShadow *)OGRDataSourceShadow_GetLayerByName(arg1,(char const *)arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRLayerShadow, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_TestCapability(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:DataSource_TestCapability",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (int)OGRDataSourceShadow_TestCapability(arg1,(char const *)arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_ExecuteSQL(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    OGRGeometryShadow *arg3 = (OGRGeometryShadow *) NULL ;
    char *arg4 = (char *) "" ;
    OGRLayerShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    PyObject * obj3 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "statement",(char *) "geom",(char *) "dialect", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|OO:DataSource_ExecuteSQL",kwnames,&obj0,&obj1,&obj2,&obj3)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    if (obj2) {
        SWIG_Python_ConvertPtr(obj2, (void **)&arg3, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
        if (SWIG_arg_fail(3)) SWIG_fail;
    }
    if (obj3) {
        if (!SWIG_AsCharPtr(obj3, (char**)&arg4)) {
            SWIG_arg_fail(4);SWIG_fail;
        }
    }
    result = (OGRLayerShadow *)OGRDataSourceShadow_ExecuteSQL(arg1,(char const *)arg2,arg3,(char const *)arg4);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRLayerShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_DataSource_ReleaseResultSet(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
    OGRLayerShadow *arg2 = (OGRLayerShadow *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:DataSource_ReleaseResultSet",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRDataSourceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    OGRDataSourceShadow_ReleaseResultSet(arg1,arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * DataSource_swigregister(PyObject *, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_OGRDataSourceShadow, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_Layer_Reference(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_Reference",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRLayerShadow_Reference(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_Dereference(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_Dereference",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRLayerShadow_Dereference(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_GetRefCount(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_GetRefCount",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRLayerShadow_GetRefCount(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_SetSpatialFilter(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Layer_SetSpatialFilter",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    OGRLayerShadow_SetSpatialFilter(arg1,arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_SetSpatialFilterRect(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    double arg2 ;
    double arg3 ;
    double arg4 ;
    double arg5 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    PyObject * obj3 = 0 ;
    PyObject * obj4 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOOOO:Layer_SetSpatialFilterRect",&obj0,&obj1,&obj2,&obj3,&obj4)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (double)(SWIG_As_double(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    {
        arg3 = (double)(SWIG_As_double(obj2)); 
        if (SWIG_arg_fail(3)) SWIG_fail;
    }
    {
        arg4 = (double)(SWIG_As_double(obj3)); 
        if (SWIG_arg_fail(4)) SWIG_fail;
    }
    {
        arg5 = (double)(SWIG_As_double(obj4)); 
        if (SWIG_arg_fail(5)) SWIG_fail;
    }
    OGRLayerShadow_SetSpatialFilterRect(arg1,arg2,arg3,arg4,arg5);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_GetSpatialFilter(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_GetSpatialFilter",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRGeometryShadow *)OGRLayerShadow_GetSpatialFilter(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_SetAttributeFilter(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Layer_SetAttributeFilter",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (OGRErr)OGRLayerShadow_SetAttributeFilter(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_ResetReading(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_ResetReading",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRLayerShadow_ResetReading(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_GetName(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_GetName",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRLayerShadow_GetName(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_GetFeature(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    long arg2 ;
    OGRFeatureShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Layer_GetFeature",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (long)(SWIG_As_long(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (OGRFeatureShadow *)OGRLayerShadow_GetFeature(arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRFeatureShadow, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_GetNextFeature(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OGRFeatureShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_GetNextFeature",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRFeatureShadow *)OGRLayerShadow_GetNextFeature(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRFeatureShadow, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_SetNextByIndex(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    long arg2 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Layer_SetNextByIndex",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (long)(SWIG_As_long(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (OGRErr)OGRLayerShadow_SetNextByIndex(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_SetFeature(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OGRFeatureShadow *arg2 = (OGRFeatureShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Layer_SetFeature",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRErr)OGRLayerShadow_SetFeature(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_CreateFeature(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OGRFeatureShadow *arg2 = (OGRFeatureShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Layer_CreateFeature",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRErr)OGRLayerShadow_CreateFeature(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_DeleteFeature(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    long arg2 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Layer_DeleteFeature",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (long)(SWIG_As_long(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (OGRErr)OGRLayerShadow_DeleteFeature(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_SyncToDisk(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_SyncToDisk",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRErr)OGRLayerShadow_SyncToDisk(arg1);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_GetLayerDefn(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OGRFeatureDefnShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_GetLayerDefn",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRFeatureDefnShadow *)OGRLayerShadow_GetLayerDefn(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRFeatureDefnShadow, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_GetFeatureCount(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    int arg2 = (int) 1 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "force", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:Layer_GetFeatureCount",kwnames,&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (obj1) {
        {
            arg2 = (int)(SWIG_As_int(obj1)); 
            if (SWIG_arg_fail(2)) SWIG_fail;
        }
    }
    result = (int)OGRLayerShadow_GetFeatureCount(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_GetExtent(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    double *arg2 ;
    int arg3 = (int) 1 ;
    double argout2[4] ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "force", NULL 
    };
    
    {
        /* %typemap(in,numinputs=0) (double argout2[ANY]) */
        arg2 = argout2;
        resultobj = 0;
    }
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:Layer_GetExtent",kwnames,&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (obj1) {
        {
            arg3 = (int)(SWIG_As_int(obj1)); 
            if (SWIG_arg_fail(3)) SWIG_fail;
        }
    }
    OGRLayerShadow_GetExtent(arg1,arg2,arg3);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    {
        /* %typemap(argout) (double argout[ANY]) */
        PyObject *out = CreateTupleFromDoubleArray( arg2, 4 );
        resultobj = t_output_helper(resultobj,out);
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_TestCapability(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Layer_TestCapability",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (int)OGRLayerShadow_TestCapability(arg1,(char const *)arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_CreateField(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OGRFieldDefnShadow *arg2 = (OGRFieldDefnShadow *) 0 ;
    int arg3 = (int) 1 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "field_def",(char *) "approx_ok", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|O:Layer_CreateField",kwnames,&obj0,&obj1,&obj2)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    if (obj2) {
        {
            arg3 = (int)(SWIG_As_int(obj2)); 
            if (SWIG_arg_fail(3)) SWIG_fail;
        }
    }
    result = (OGRErr)OGRLayerShadow_CreateField(arg1,arg2,arg3);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_StartTransaction(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_StartTransaction",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRErr)OGRLayerShadow_StartTransaction(arg1);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_CommitTransaction(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_CommitTransaction",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRErr)OGRLayerShadow_CommitTransaction(arg1);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_RollbackTransaction(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_RollbackTransaction",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRErr)OGRLayerShadow_RollbackTransaction(arg1);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_GetSpatialRef(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    OSRSpatialReferenceShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_GetSpatialRef",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OSRSpatialReferenceShadow *)OGRLayerShadow_GetSpatialRef(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OSRSpatialReferenceShadow, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Layer_GetFeatureRead(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
    GIntBig result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Layer_GetFeatureRead",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRLayerShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = OGRLayerShadow_GetFeatureRead(arg1);
    
    {
        GIntBig * resultptr;
        resultptr = new GIntBig((GIntBig &)(result));
        resultobj = SWIG_NewPointerObj((void *)(resultptr), SWIGTYPE_p_GIntBig, 1);
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject * Layer_swigregister(PyObject *, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_OGRLayerShadow, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_new_Feature(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    OGRFeatureShadow *result;
    PyObject * obj0 = 0 ;
    char *kwnames[] = {
        (char *) "feature_def", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"|O:new_Feature",kwnames,&obj0)) goto fail;
    if (obj0) {
        SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
        if (SWIG_arg_fail(1)) SWIG_fail;
    }
    result = (OGRFeatureShadow *)new_OGRFeatureShadow(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRFeatureShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_Destroy(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Feature_Destroy",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRFeatureShadow_Destroy(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetDefnRef(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    OGRFeatureDefnShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Feature_GetDefnRef",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRFeatureDefnShadow *)OGRFeatureShadow_GetDefnRef(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRFeatureDefnShadow, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_SetGeometry(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_SetGeometry",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRErr)OGRFeatureShadow_SetGeometry(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_SetGeometryDirectly(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_SetGeometryDirectly",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRErr)OGRFeatureShadow_SetGeometryDirectly(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetGeometryRef(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Feature_GetGeometryRef",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRGeometryShadow *)OGRFeatureShadow_GetGeometryRef(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_Clone(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    OGRFeatureShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Feature_Clone",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRFeatureShadow *)OGRFeatureShadow_Clone(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRFeatureShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_Equal(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    OGRFeatureShadow *arg2 = (OGRFeatureShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_Equal",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (int)OGRFeatureShadow_Equal(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldCount(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Feature_GetFieldCount",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRFeatureShadow_GetFieldCount(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldDefnRef__SWIG_0(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    int arg2 ;
    OGRFieldDefnShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_GetFieldDefnRef",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (OGRFieldDefnShadow *)OGRFeatureShadow_GetFieldDefnRef__SWIG_0(arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRFieldDefnShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldDefnRef__SWIG_1(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    OGRFieldDefnShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_GetFieldDefnRef",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (OGRFieldDefnShadow *)OGRFeatureShadow_GetFieldDefnRef__SWIG_1(arg1,(char const *)arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRFieldDefnShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldDefnRef(PyObject *self, PyObject *args) {
    int argc;
    PyObject *argv[3];
    int ii;
    
    argc = PyObject_Length(args);
    for (ii = 0; (ii < argc) && (ii < 2); ii++) {
        argv[ii] = PyTuple_GetItem(args,ii);
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_Check_int(argv[1]);
            if (_v) {
                return _wrap_Feature_GetFieldDefnRef__SWIG_0(self,args);
            }
        }
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_AsCharPtr(argv[1], (char **)(0));
            if (_v) {
                return _wrap_Feature_GetFieldDefnRef__SWIG_1(self,args);
            }
        }
    }
    
    PyErr_SetString(PyExc_NotImplementedError,"No matching function for overloaded 'Feature_GetFieldDefnRef'");
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldAsString__SWIG_0(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    int arg2 ;
    char *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_GetFieldAsString",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (char *)OGRFeatureShadow_GetFieldAsString__SWIG_0(arg1,arg2);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldAsString__SWIG_1(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_GetFieldAsString",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (char *)OGRFeatureShadow_GetFieldAsString__SWIG_1(arg1,(char const *)arg2);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldAsString(PyObject *self, PyObject *args) {
    int argc;
    PyObject *argv[3];
    int ii;
    
    argc = PyObject_Length(args);
    for (ii = 0; (ii < argc) && (ii < 2); ii++) {
        argv[ii] = PyTuple_GetItem(args,ii);
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_Check_int(argv[1]);
            if (_v) {
                return _wrap_Feature_GetFieldAsString__SWIG_0(self,args);
            }
        }
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_AsCharPtr(argv[1], (char **)(0));
            if (_v) {
                return _wrap_Feature_GetFieldAsString__SWIG_1(self,args);
            }
        }
    }
    
    PyErr_SetString(PyExc_NotImplementedError,"No matching function for overloaded 'Feature_GetFieldAsString'");
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldAsInteger__SWIG_0(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    int arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_GetFieldAsInteger",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (int)OGRFeatureShadow_GetFieldAsInteger__SWIG_0(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldAsInteger__SWIG_1(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_GetFieldAsInteger",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (int)OGRFeatureShadow_GetFieldAsInteger__SWIG_1(arg1,(char const *)arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldAsInteger(PyObject *self, PyObject *args) {
    int argc;
    PyObject *argv[3];
    int ii;
    
    argc = PyObject_Length(args);
    for (ii = 0; (ii < argc) && (ii < 2); ii++) {
        argv[ii] = PyTuple_GetItem(args,ii);
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_Check_int(argv[1]);
            if (_v) {
                return _wrap_Feature_GetFieldAsInteger__SWIG_0(self,args);
            }
        }
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_AsCharPtr(argv[1], (char **)(0));
            if (_v) {
                return _wrap_Feature_GetFieldAsInteger__SWIG_1(self,args);
            }
        }
    }
    
    PyErr_SetString(PyExc_NotImplementedError,"No matching function for overloaded 'Feature_GetFieldAsInteger'");
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldAsDouble__SWIG_0(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    int arg2 ;
    double result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_GetFieldAsDouble",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (double)OGRFeatureShadow_GetFieldAsDouble__SWIG_0(arg1,arg2);
    
    {
        resultobj = SWIG_From_double((double)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldAsDouble__SWIG_1(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_GetFieldAsDouble",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (double)OGRFeatureShadow_GetFieldAsDouble__SWIG_1(arg1,(char const *)arg2);
    
    {
        resultobj = SWIG_From_double((double)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldAsDouble(PyObject *self, PyObject *args) {
    int argc;
    PyObject *argv[3];
    int ii;
    
    argc = PyObject_Length(args);
    for (ii = 0; (ii < argc) && (ii < 2); ii++) {
        argv[ii] = PyTuple_GetItem(args,ii);
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_Check_int(argv[1]);
            if (_v) {
                return _wrap_Feature_GetFieldAsDouble__SWIG_0(self,args);
            }
        }
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_AsCharPtr(argv[1], (char **)(0));
            if (_v) {
                return _wrap_Feature_GetFieldAsDouble__SWIG_1(self,args);
            }
        }
    }
    
    PyErr_SetString(PyExc_NotImplementedError,"No matching function for overloaded 'Feature_GetFieldAsDouble'");
    return NULL;
}


static PyObject *_wrap_Feature_IsFieldSet__SWIG_0(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    int arg2 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_IsFieldSet",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (int)OGRFeatureShadow_IsFieldSet__SWIG_0(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_IsFieldSet__SWIG_1(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_IsFieldSet",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (int)OGRFeatureShadow_IsFieldSet__SWIG_1(arg1,(char const *)arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_IsFieldSet(PyObject *self, PyObject *args) {
    int argc;
    PyObject *argv[3];
    int ii;
    
    argc = PyObject_Length(args);
    for (ii = 0; (ii < argc) && (ii < 2); ii++) {
        argv[ii] = PyTuple_GetItem(args,ii);
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_Check_int(argv[1]);
            if (_v) {
                return _wrap_Feature_IsFieldSet__SWIG_0(self,args);
            }
        }
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_AsCharPtr(argv[1], (char **)(0));
            if (_v) {
                return _wrap_Feature_IsFieldSet__SWIG_1(self,args);
            }
        }
    }
    
    PyErr_SetString(PyExc_NotImplementedError,"No matching function for overloaded 'Feature_IsFieldSet'");
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldIndex(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_GetFieldIndex",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (int)OGRFeatureShadow_GetFieldIndex(arg1,(char const *)arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFID(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Feature_GetFID",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRFeatureShadow_GetFID(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_SetFID(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    int arg2 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_SetFID",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (OGRErr)OGRFeatureShadow_SetFID(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_DumpReadable(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Feature_DumpReadable",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRFeatureShadow_DumpReadable(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_UnsetField__SWIG_0(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_UnsetField",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    OGRFeatureShadow_UnsetField__SWIG_0(arg1,arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_UnsetField__SWIG_1(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_UnsetField",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    OGRFeatureShadow_UnsetField__SWIG_1(arg1,(char const *)arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_UnsetField(PyObject *self, PyObject *args) {
    int argc;
    PyObject *argv[3];
    int ii;
    
    argc = PyObject_Length(args);
    for (ii = 0; (ii < argc) && (ii < 2); ii++) {
        argv[ii] = PyTuple_GetItem(args,ii);
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_Check_int(argv[1]);
            if (_v) {
                return _wrap_Feature_UnsetField__SWIG_0(self,args);
            }
        }
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_AsCharPtr(argv[1], (char **)(0));
            if (_v) {
                return _wrap_Feature_UnsetField__SWIG_1(self,args);
            }
        }
    }
    
    PyErr_SetString(PyExc_NotImplementedError,"No matching function for overloaded 'Feature_UnsetField'");
    return NULL;
}


static PyObject *_wrap_Feature_SetField__SWIG_0(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    int arg2 ;
    char *arg3 = (char *) 0 ;
    PyObject *str3 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOO:Feature_SetField",&obj0,&obj1,&obj2)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    {
        /* %typemap(in) (tostring argin) */
        str3 = PyObject_Str( obj2 );
        if ( str3 == 0 ) {
            PyErr_SetString( PyExc_RuntimeError, "Unable to format argument as string");
            SWIG_fail;
        }
        
        arg3 = PyString_AsString(str3); 
    }
    OGRFeatureShadow_SetField__SWIG_0(arg1,arg2,(char const *)arg3);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    {
        /* %typemap(freearg) (tostring argin) */
        Py_DECREF(str3);
    }
    return resultobj;
    fail:
    {
        /* %typemap(freearg) (tostring argin) */
        Py_DECREF(str3);
    }
    return NULL;
}


static PyObject *_wrap_Feature_SetField__SWIG_1(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    char *arg3 = (char *) 0 ;
    PyObject *str3 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOO:Feature_SetField",&obj0,&obj1,&obj2)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    {
        /* %typemap(in) (tostring argin) */
        str3 = PyObject_Str( obj2 );
        if ( str3 == 0 ) {
            PyErr_SetString( PyExc_RuntimeError, "Unable to format argument as string");
            SWIG_fail;
        }
        
        arg3 = PyString_AsString(str3); 
    }
    OGRFeatureShadow_SetField__SWIG_1(arg1,(char const *)arg2,(char const *)arg3);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    {
        /* %typemap(freearg) (tostring argin) */
        Py_DECREF(str3);
    }
    return resultobj;
    fail:
    {
        /* %typemap(freearg) (tostring argin) */
        Py_DECREF(str3);
    }
    return NULL;
}


static PyObject *_wrap_Feature_SetField(PyObject *self, PyObject *args) {
    int argc;
    PyObject *argv[4];
    int ii;
    
    argc = PyObject_Length(args);
    for (ii = 0; (ii < argc) && (ii < 3); ii++) {
        argv[ii] = PyTuple_GetItem(args,ii);
    }
    if (argc == 3) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_Check_int(argv[1]);
            if (_v) {
                {
                    /* %typemap(typecheck,precedence=SWIG_TYPECHECK_POINTER) (tostring argin) */
                    _v = 1;
                }
                if (_v) {
                    return _wrap_Feature_SetField__SWIG_0(self,args);
                }
            }
        }
    }
    if (argc == 3) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_AsCharPtr(argv[1], (char **)(0));
            if (_v) {
                {
                    /* %typemap(typecheck,precedence=SWIG_TYPECHECK_POINTER) (tostring argin) */
                    _v = 1;
                }
                if (_v) {
                    return _wrap_Feature_SetField__SWIG_1(self,args);
                }
            }
        }
    }
    
    PyErr_SetString(PyExc_NotImplementedError,"No matching function for overloaded 'Feature_SetField'");
    return NULL;
}


static PyObject *_wrap_Feature_SetFrom(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    OGRFeatureShadow *arg2 = (OGRFeatureShadow *) 0 ;
    int arg3 = (int) 1 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "other",(char *) "forgiving", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|O:Feature_SetFrom",kwnames,&obj0,&obj1,&obj2)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    if (obj2) {
        {
            arg3 = (int)(SWIG_As_int(obj2)); 
            if (SWIG_arg_fail(3)) SWIG_fail;
        }
    }
    result = (OGRErr)OGRFeatureShadow_SetFrom(arg1,arg2,arg3);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetStyleString(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Feature_GetStyleString",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRFeatureShadow_GetStyleString(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_SetStyleString(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_SetStyleString",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    OGRFeatureShadow_SetStyleString(arg1,(char const *)arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldType__SWIG_0(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    int arg2 ;
    OGRFieldType result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Feature_GetFieldType",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (OGRFieldType)OGRFeatureShadow_GetFieldType__SWIG_0(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldType__SWIG_1(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    char *arg3 = (char *) 0 ;
    OGRFieldType result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OOO:Feature_GetFieldType",&obj0,&obj1,&obj2)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    if (!SWIG_AsCharPtr(obj2, (char**)&arg3)) {
        SWIG_arg_fail(3);SWIG_fail;
    }
    result = (OGRFieldType)OGRFeatureShadow_GetFieldType__SWIG_1(arg1,(char const *)arg2,(char const *)arg3);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Feature_GetFieldType(PyObject *self, PyObject *args) {
    int argc;
    PyObject *argv[4];
    int ii;
    
    argc = PyObject_Length(args);
    for (ii = 0; (ii < argc) && (ii < 3); ii++) {
        argv[ii] = PyTuple_GetItem(args,ii);
    }
    if (argc == 2) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_Check_int(argv[1]);
            if (_v) {
                return _wrap_Feature_GetFieldType__SWIG_0(self,args);
            }
        }
    }
    if (argc == 3) {
        int _v;
        {
            void *ptr;
            if (SWIG_ConvertPtr(argv[0], &ptr, SWIGTYPE_p_OGRFeatureShadow, 0) == -1) {
                _v = 0;
                PyErr_Clear();
            } else {
                _v = 1;
            }
        }
        if (_v) {
            _v = SWIG_AsCharPtr(argv[1], (char **)(0));
            if (_v) {
                _v = SWIG_AsCharPtr(argv[2], (char **)(0));
                if (_v) {
                    return _wrap_Feature_GetFieldType__SWIG_1(self,args);
                }
            }
        }
    }
    
    PyErr_SetString(PyExc_NotImplementedError,"No matching function for overloaded 'Feature_GetFieldType'");
    return NULL;
}


static PyObject * Feature_swigregister(PyObject *, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_OGRFeatureShadow, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_new_FeatureDefn(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    char *arg1 = (char *) NULL ;
    OGRFeatureDefnShadow *result;
    PyObject * obj0 = 0 ;
    char *kwnames[] = {
        (char *) "name", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"|O:new_FeatureDefn",kwnames,&obj0)) goto fail;
    if (obj0) {
        if (!SWIG_AsCharPtr(obj0, (char**)&arg1)) {
            SWIG_arg_fail(1);SWIG_fail;
        }
    }
    result = (OGRFeatureDefnShadow *)new_OGRFeatureDefnShadow((char const *)arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRFeatureDefnShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FeatureDefn_Destroy(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FeatureDefn_Destroy",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRFeatureDefnShadow_Destroy(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FeatureDefn_GetName(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FeatureDefn_GetName",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRFeatureDefnShadow_GetName(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FeatureDefn_GetFieldCount(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FeatureDefn_GetFieldCount",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRFeatureDefnShadow_GetFieldCount(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FeatureDefn_GetFieldDefn(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    int arg2 ;
    OGRFieldDefnShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:FeatureDefn_GetFieldDefn",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (OGRFieldDefnShadow *)OGRFeatureDefnShadow_GetFieldDefn(arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRFieldDefnShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FeatureDefn_GetFieldIndex(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:FeatureDefn_GetFieldIndex",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    result = (int)OGRFeatureDefnShadow_GetFieldIndex(arg1,(char const *)arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FeatureDefn_AddFieldDefn(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    OGRFieldDefnShadow *arg2 = (OGRFieldDefnShadow *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:FeatureDefn_AddFieldDefn",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    OGRFeatureDefnShadow_AddFieldDefn(arg1,arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FeatureDefn_GetGeomType(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    OGRwkbGeometryType result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FeatureDefn_GetGeomType",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRwkbGeometryType)OGRFeatureDefnShadow_GetGeomType(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FeatureDefn_SetGeomType(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    OGRwkbGeometryType arg2 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:FeatureDefn_SetGeomType",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (OGRwkbGeometryType)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    OGRFeatureDefnShadow_SetGeomType(arg1,arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FeatureDefn_Reference(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FeatureDefn_Reference",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRFeatureDefnShadow_Reference(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FeatureDefn_Dereference(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FeatureDefn_Dereference",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRFeatureDefnShadow_Dereference(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FeatureDefn_GetReferenceCount(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FeatureDefn_GetReferenceCount",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFeatureDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRFeatureDefnShadow_GetReferenceCount(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject * FeatureDefn_swigregister(PyObject *, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_OGRFeatureDefnShadow, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_new_FieldDefn(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    char *arg1 = (char *) "unnamed" ;
    OGRFieldType arg2 = (OGRFieldType) OFTString ;
    OGRFieldDefnShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "name",(char *) "field_type", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"|OO:new_FieldDefn",kwnames,&obj0,&obj1)) goto fail;
    if (obj0) {
        if (!SWIG_AsCharPtr(obj0, (char**)&arg1)) {
            SWIG_arg_fail(1);SWIG_fail;
        }
    }
    if (obj1) {
        {
            arg2 = (OGRFieldType)(SWIG_As_int(obj1)); 
            if (SWIG_arg_fail(2)) SWIG_fail;
        }
    }
    result = (OGRFieldDefnShadow *)new_OGRFieldDefnShadow((char const *)arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRFieldDefnShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_Destroy(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FieldDefn_Destroy",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRFieldDefnShadow_Destroy(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_GetName(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FieldDefn_GetName",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRFieldDefnShadow_GetName(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_GetNameRef(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FieldDefn_GetNameRef",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRFieldDefnShadow_GetNameRef(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_SetName(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    char *arg2 = (char *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:FieldDefn_SetName",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
        SWIG_arg_fail(2);SWIG_fail;
    }
    OGRFieldDefnShadow_SetName(arg1,(char const *)arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_GetType(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    OGRFieldType result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FieldDefn_GetType",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRFieldType)OGRFieldDefnShadow_GetType(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_SetType(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    OGRFieldType arg2 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:FieldDefn_SetType",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (OGRFieldType)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    OGRFieldDefnShadow_SetType(arg1,arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_GetJustify(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    OGRJustification result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FieldDefn_GetJustify",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRJustification)OGRFieldDefnShadow_GetJustify(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_SetJustify(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    OGRJustification arg2 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:FieldDefn_SetJustify",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (OGRJustification)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    OGRFieldDefnShadow_SetJustify(arg1,arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_GetWidth(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FieldDefn_GetWidth",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRFieldDefnShadow_GetWidth(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_SetWidth(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:FieldDefn_SetWidth",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    OGRFieldDefnShadow_SetWidth(arg1,arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_GetPrecision(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:FieldDefn_GetPrecision",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRFieldDefnShadow_GetPrecision(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_FieldDefn_SetPrecision(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
    int arg2 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:FieldDefn_SetPrecision",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRFieldDefnShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    OGRFieldDefnShadow_SetPrecision(arg1,arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject * FieldDefn_swigregister(PyObject *, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_OGRFieldDefnShadow, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_CreateGeometryFromWkb(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    int arg1 ;
    char *arg2 = (char *) 0 ;
    OSRSpatialReferenceShadow *arg3 = (OSRSpatialReferenceShadow *) NULL ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "len",(char *) "reference", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:CreateGeometryFromWkb",kwnames,&obj0,&obj1)) goto fail;
    {
        /* %typemap(in,numinputs=1) (int nLen, char *pBuf ) */
        PyString_AsStringAndSize(obj0, &arg2, &arg1 );
    }
    if (obj1) {
        SWIG_Python_ConvertPtr(obj1, (void **)&arg3, SWIGTYPE_p_OSRSpatialReferenceShadow, SWIG_POINTER_EXCEPTION | 0);
        if (SWIG_arg_fail(3)) SWIG_fail;
    }
    result = (OGRGeometryShadow *)CreateGeometryFromWkb(arg1,arg2,arg3);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_CreateGeometryFromWkt(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    char **arg1 = (char **) 0 ;
    OSRSpatialReferenceShadow *arg2 = (OSRSpatialReferenceShadow *) NULL ;
    OGRGeometryShadow *result;
    char *val1 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "val",(char *) "reference", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:CreateGeometryFromWkt",kwnames,&obj0,&obj1)) goto fail;
    {
        /* %typemap(in) (char **ignorechange) */
        PyArg_Parse( obj0, "s", &val1 );
        arg1 = &val1;
    }
    if (obj1) {
        SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OSRSpatialReferenceShadow, SWIG_POINTER_EXCEPTION | 0);
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (OGRGeometryShadow *)CreateGeometryFromWkt(arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_CreateGeometryFromGML(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    char *arg1 = (char *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:CreateGeometryFromGML",&obj0)) goto fail;
    if (!SWIG_AsCharPtr(obj0, (char**)&arg1)) {
        SWIG_arg_fail(1);SWIG_fail;
    }
    result = (OGRGeometryShadow *)CreateGeometryFromGML((char const *)arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_new_Geometry(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRwkbGeometryType arg1 = (OGRwkbGeometryType) wkbUnknown ;
    char *arg2 = (char *) 0 ;
    int arg3 = (int) 0 ;
    char *arg4 = (char *) 0 ;
    char *arg5 = (char *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    PyObject * obj3 = 0 ;
    PyObject * obj4 = 0 ;
    char *kwnames[] = {
        (char *) "type",(char *) "wkt",(char *) "wkb",(char *) "wkb_buf",(char *) "gml", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"|OOOOO:new_Geometry",kwnames,&obj0,&obj1,&obj2,&obj3,&obj4)) goto fail;
    if (obj0) {
        {
            arg1 = (OGRwkbGeometryType)(SWIG_As_int(obj0)); 
            if (SWIG_arg_fail(1)) SWIG_fail;
        }
    }
    if (obj1) {
        if (!SWIG_AsCharPtr(obj1, (char**)&arg2)) {
            SWIG_arg_fail(2);SWIG_fail;
        }
    }
    if (obj2) {
        {
            arg3 = (int)(SWIG_As_int(obj2)); 
            if (SWIG_arg_fail(3)) SWIG_fail;
        }
    }
    if (obj3) {
        if (!SWIG_AsCharPtr(obj3, (char**)&arg4)) {
            SWIG_arg_fail(4);SWIG_fail;
        }
    }
    if (obj4) {
        if (!SWIG_AsCharPtr(obj4, (char**)&arg5)) {
            SWIG_arg_fail(5);SWIG_fail;
        }
    }
    result = (OGRGeometryShadow *)new_OGRGeometryShadow(arg1,arg2,arg3,arg4,arg5);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_ExportToWkt(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_ExportToWkt",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRGeometryShadow_ExportToWkt(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_ExportToWkb(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    int *arg2 = (int *) 0 ;
    char **arg3 = (char **) 0 ;
    OGRwkbByteOrder arg4 = (OGRwkbByteOrder) wkbXDR ;
    OGRErr result;
    int nLen2 = 0 ;
    char *pBuf2 = 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "byte_order", NULL 
    };
    
    {
        /* %typemap(in,numinputs=0) (int *nLen2, char **pBuf2 ) */
        arg2 = &nLen2;
        arg3 = &pBuf2;
    }
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:Geometry_ExportToWkb",kwnames,&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (obj1) {
        {
            arg4 = (OGRwkbByteOrder)(SWIG_As_int(obj1)); 
            if (SWIG_arg_fail(4)) SWIG_fail;
        }
    }
    result = (OGRErr)OGRGeometryShadow_ExportToWkb(arg1,arg2,arg3,arg4);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(argout) (int *nLen, char **pBuf ) */
        Py_XDECREF(resultobj);
        resultobj = PyString_FromStringAndSize( *arg3, *arg2 );
    }
    {
        /* %typemap(freearg) (int *nLen, char **pBuf ) */
        if( *arg2 ) {
            free( *arg3 );
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    {
        /* %typemap(freearg) (int *nLen, char **pBuf ) */
        if( *arg2 ) {
            free( *arg3 );
        }
    }
    return NULL;
}


static PyObject *_wrap_Geometry_ExportToGML(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_ExportToGML",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRGeometryShadow_ExportToGML(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_AddPoint(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    double arg2 ;
    double arg3 ;
    double arg4 = (double) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    PyObject * obj3 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "x",(char *) "y",(char *) "z", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OOO|O:Geometry_AddPoint",kwnames,&obj0,&obj1,&obj2,&obj3)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (double)(SWIG_As_double(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    {
        arg3 = (double)(SWIG_As_double(obj2)); 
        if (SWIG_arg_fail(3)) SWIG_fail;
    }
    if (obj3) {
        {
            arg4 = (double)(SWIG_As_double(obj3)); 
            if (SWIG_arg_fail(4)) SWIG_fail;
        }
    }
    OGRGeometryShadow_AddPoint(arg1,arg2,arg3,arg4);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_AddGeometryDirectly(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_AddGeometryDirectly",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRErr)OGRGeometryShadow_AddGeometryDirectly(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_AddGeometry(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_AddGeometry",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRErr)OGRGeometryShadow_AddGeometry(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Clone(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_Clone",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRGeometryShadow *)OGRGeometryShadow_Clone(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Destroy(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_Destroy",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRGeometryShadow_Destroy(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetGeometryType(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRwkbGeometryType result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_GetGeometryType",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRwkbGeometryType)OGRGeometryShadow_GetGeometryType(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetGeometryName(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    char *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_GetGeometryName",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (char *)OGRGeometryShadow_GetGeometryName(arg1);
    
    resultobj = SWIG_FromCharPtr(result);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetArea(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_GetArea",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (double)OGRGeometryShadow_GetArea(arg1);
    
    {
        resultobj = SWIG_From_double((double)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetPointCount(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_GetPointCount",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRGeometryShadow_GetPointCount(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetX(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    int arg2 = (int) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "point", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:Geometry_GetX",kwnames,&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (obj1) {
        {
            arg2 = (int)(SWIG_As_int(obj1)); 
            if (SWIG_arg_fail(2)) SWIG_fail;
        }
    }
    result = (double)OGRGeometryShadow_GetX(arg1,arg2);
    
    {
        resultobj = SWIG_From_double((double)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetY(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    int arg2 = (int) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "point", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:Geometry_GetY",kwnames,&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (obj1) {
        {
            arg2 = (int)(SWIG_As_int(obj1)); 
            if (SWIG_arg_fail(2)) SWIG_fail;
        }
    }
    result = (double)OGRGeometryShadow_GetY(arg1,arg2);
    
    {
        resultobj = SWIG_From_double((double)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetZ(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    int arg2 = (int) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "point", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:Geometry_GetZ",kwnames,&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    if (obj1) {
        {
            arg2 = (int)(SWIG_As_int(obj1)); 
            if (SWIG_arg_fail(2)) SWIG_fail;
        }
    }
    result = (double)OGRGeometryShadow_GetZ(arg1,arg2);
    
    {
        resultobj = SWIG_From_double((double)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetGeometryCount(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_GetGeometryCount",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRGeometryShadow_GetGeometryCount(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_SetPoint(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    int arg2 ;
    double arg3 ;
    double arg4 ;
    double arg5 = (double) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    PyObject * obj3 = 0 ;
    PyObject * obj4 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "point",(char *) "x",(char *) "y",(char *) "z", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OOOO|O:Geometry_SetPoint",kwnames,&obj0,&obj1,&obj2,&obj3,&obj4)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    {
        arg3 = (double)(SWIG_As_double(obj2)); 
        if (SWIG_arg_fail(3)) SWIG_fail;
    }
    {
        arg4 = (double)(SWIG_As_double(obj3)); 
        if (SWIG_arg_fail(4)) SWIG_fail;
    }
    if (obj4) {
        {
            arg5 = (double)(SWIG_As_double(obj4)); 
            if (SWIG_arg_fail(5)) SWIG_fail;
        }
    }
    OGRGeometryShadow_SetPoint(arg1,arg2,arg3,arg4,arg5);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetGeometryRef(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    int arg2 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_GetGeometryRef",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (int)(SWIG_As_int(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    result = (OGRGeometryShadow *)OGRGeometryShadow_GetGeometryRef(arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetBoundary(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_GetBoundary",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRGeometryShadow *)OGRGeometryShadow_GetBoundary(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_ConvexHull(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_ConvexHull",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRGeometryShadow *)OGRGeometryShadow_ConvexHull(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Buffer(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    double arg2 ;
    int arg3 = (int) 30 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    PyObject * obj2 = 0 ;
    char *kwnames[] = {
        (char *) "self",(char *) "distance",(char *) "quadsecs", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|O:Geometry_Buffer",kwnames,&obj0,&obj1,&obj2)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    {
        arg2 = (double)(SWIG_As_double(obj1)); 
        if (SWIG_arg_fail(2)) SWIG_fail;
    }
    if (obj2) {
        {
            arg3 = (int)(SWIG_As_int(obj2)); 
            if (SWIG_arg_fail(3)) SWIG_fail;
        }
    }
    result = (OGRGeometryShadow *)OGRGeometryShadow_Buffer(arg1,arg2,arg3);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Intersection(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Intersection",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRGeometryShadow *)OGRGeometryShadow_Intersection(arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Union(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Union",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRGeometryShadow *)OGRGeometryShadow_Union(arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Difference(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Difference",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRGeometryShadow *)OGRGeometryShadow_Difference(arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_SymmetricDifference(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_SymmetricDifference",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRGeometryShadow *)OGRGeometryShadow_SymmetricDifference(arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Distance(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    double result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Distance",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (double)OGRGeometryShadow_Distance(arg1,arg2);
    
    {
        resultobj = SWIG_From_double((double)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Empty(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_Empty",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRGeometryShadow_Empty(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Intersect(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Intersect",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (int)OGRGeometryShadow_Intersect(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Equal(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Equal",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (int)OGRGeometryShadow_Equal(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Disjoint(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Disjoint",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (int)OGRGeometryShadow_Disjoint(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Touches(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Touches",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (int)OGRGeometryShadow_Touches(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Crosses(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Crosses",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (int)OGRGeometryShadow_Crosses(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Within(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Within",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (int)OGRGeometryShadow_Within(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Contains(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Contains",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (int)OGRGeometryShadow_Contains(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Overlaps(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Overlaps",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (int)OGRGeometryShadow_Overlaps(arg1,arg2);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_TransformTo(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OSRSpatialReferenceShadow *arg2 = (OSRSpatialReferenceShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_TransformTo",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OSRSpatialReferenceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRErr)OGRGeometryShadow_TransformTo(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Transform(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OSRCoordinateTransformationShadow *arg2 = (OSRCoordinateTransformationShadow *) 0 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_Transform",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OSRCoordinateTransformationShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    result = (OGRErr)OGRGeometryShadow_Transform(arg1,arg2);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetSpatialReference(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OSRSpatialReferenceShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_GetSpatialReference",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OSRSpatialReferenceShadow *)OGRGeometryShadow_GetSpatialReference(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OSRSpatialReferenceShadow, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_AssignSpatialReference(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OSRSpatialReferenceShadow *arg2 = (OSRSpatialReferenceShadow *) 0 ;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"OO:Geometry_AssignSpatialReference",&obj0,&obj1)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    SWIG_Python_ConvertPtr(obj1, (void **)&arg2, SWIGTYPE_p_OSRSpatialReferenceShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(2)) SWIG_fail;
    OGRGeometryShadow_AssignSpatialReference(arg1,arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_CloseRings(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_CloseRings",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRGeometryShadow_CloseRings(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_FlattenTo2D(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_FlattenTo2D",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRGeometryShadow_FlattenTo2D(arg1);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetEnvelope(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    double *arg2 ;
    double argout2[4] ;
    PyObject * obj0 = 0 ;
    
    {
        /* %typemap(in,numinputs=0) (double argout2[ANY]) */
        arg2 = argout2;
        resultobj = 0;
    }
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_GetEnvelope",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    OGRGeometryShadow_GetEnvelope(arg1,arg2);
    
    Py_INCREF(Py_None); resultobj = Py_None;
    {
        /* %typemap(argout) (double argout[ANY]) */
        PyObject *out = CreateTupleFromDoubleArray( arg2, 4 );
        resultobj = t_output_helper(resultobj,out);
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_Centroid(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    OGRGeometryShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_Centroid",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (OGRGeometryShadow *)OGRGeometryShadow_Centroid(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRGeometryShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_WkbSize(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_WkbSize",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRGeometryShadow_WkbSize(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetCoordinateDimension(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_GetCoordinateDimension",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRGeometryShadow_GetCoordinateDimension(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Geometry_GetDimension(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
    int result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:Geometry_GetDimension",&obj0)) goto fail;
    SWIG_Python_ConvertPtr(obj0, (void **)&arg1, SWIGTYPE_p_OGRGeometryShadow, SWIG_POINTER_EXCEPTION | 0);
    if (SWIG_arg_fail(1)) SWIG_fail;
    result = (int)OGRGeometryShadow_GetDimension(arg1);
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject * Geometry_swigregister(PyObject *, PyObject *args) {
    PyObject *obj;
    if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL;
    SWIG_TypeClientData(SWIGTYPE_p_OGRGeometryShadow, obj);
    Py_INCREF(obj);
    return Py_BuildValue((char *)"");
}
static PyObject *_wrap_GetDriverCount(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    int result;
    
    if(!PyArg_ParseTuple(args,(char *)":GetDriverCount")) goto fail;
    result = (int)OGRGetDriverCount();
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_GetOpenDSCount(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    int result;
    
    if(!PyArg_ParseTuple(args,(char *)":GetOpenDSCount")) goto fail;
    result = (int)OGRGetOpenDSCount();
    
    {
        resultobj = SWIG_From_int((int)(result)); 
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_SetGenerate_DB2_V72_BYTE_ORDER(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    int arg1 ;
    OGRErr result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:SetGenerate_DB2_V72_BYTE_ORDER",&obj0)) goto fail;
    {
        arg1 = (int)(SWIG_As_int(obj0)); 
        if (SWIG_arg_fail(1)) SWIG_fail;
    }
    result = (OGRErr)OGRSetGenerate_DB2_V72_BYTE_ORDER(arg1);
    
    {
        /* %typemap(out) OGRErr */
        resultobj = 0;
        if ( result != 0) {
            PyErr_Format( PyExc_RuntimeError, OGRErrMessages(result), result );
            SWIG_fail;
        }
    }
    {
        /* %typemap(ret) OGRErr */
        if (resultobj == Py_None ) {
            Py_DECREF(resultobj);
            resultobj = 0;
        }
        if (resultobj == 0) {
            resultobj = PyInt_FromLong( 0 );
        }
    }
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_RegisterAll(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    
    if(!PyArg_ParseTuple(args,(char *)":RegisterAll")) goto fail;
    OGRRegisterAll();
    
    Py_INCREF(Py_None); resultobj = Py_None;
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_GetDriverByName(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    char *arg1 = (char *) 0 ;
    OGRDriverShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:GetDriverByName",&obj0)) goto fail;
    if (!SWIG_AsCharPtr(obj0, (char**)&arg1)) {
        SWIG_arg_fail(1);SWIG_fail;
    }
    result = (OGRDriverShadow *)GetDriverByName((char const *)arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRDriverShadow, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_GetDriver(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    int arg1 ;
    OGRDriverShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:GetDriver",&obj0)) goto fail;
    {
        arg1 = (int)(SWIG_As_int(obj0)); 
        if (SWIG_arg_fail(1)) SWIG_fail;
    }
    result = (OGRDriverShadow *)GetDriver(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRDriverShadow, 0);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_GetOpenDS(PyObject *, PyObject *args) {
    PyObject *resultobj = NULL;
    int arg1 ;
    OGRDataSourceShadow *result;
    PyObject * obj0 = 0 ;
    
    if(!PyArg_ParseTuple(args,(char *)"O:GetOpenDS",&obj0)) goto fail;
    {
        arg1 = (int)(SWIG_As_int(obj0)); 
        if (SWIG_arg_fail(1)) SWIG_fail;
    }
    result = (OGRDataSourceShadow *)GetOpenDS(arg1);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRDataSourceShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_Open(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    char *arg1 = (char *) 0 ;
    int arg2 = (int) 0 ;
    OGRDataSourceShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "filename",(char *) "update", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:Open",kwnames,&obj0,&obj1)) goto fail;
    if (!SWIG_AsCharPtr(obj0, (char**)&arg1)) {
        SWIG_arg_fail(1);SWIG_fail;
    }
    if (obj1) {
        {
            arg2 = (int)(SWIG_As_int(obj1)); 
            if (SWIG_arg_fail(2)) SWIG_fail;
        }
    }
    result = (OGRDataSourceShadow *)Open((char const *)arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRDataSourceShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyObject *_wrap_OpenShared(PyObject *, PyObject *args, PyObject *kwargs) {
    PyObject *resultobj = NULL;
    char *arg1 = (char *) 0 ;
    int arg2 = (int) 0 ;
    OGRDataSourceShadow *result;
    PyObject * obj0 = 0 ;
    PyObject * obj1 = 0 ;
    char *kwnames[] = {
        (char *) "filename",(char *) "update", NULL 
    };
    
    if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|O:OpenShared",kwnames,&obj0,&obj1)) goto fail;
    if (!SWIG_AsCharPtr(obj0, (char**)&arg1)) {
        SWIG_arg_fail(1);SWIG_fail;
    }
    if (obj1) {
        {
            arg2 = (int)(SWIG_As_int(obj1)); 
            if (SWIG_arg_fail(2)) SWIG_fail;
        }
    }
    result = (OGRDataSourceShadow *)OpenShared((char const *)arg1,arg2);
    
    resultobj = SWIG_NewPointerObj((void*)(result), SWIGTYPE_p_OGRDataSourceShadow, 1);
    return resultobj;
    fail:
    return NULL;
}


static PyMethodDef SwigMethods[] = {
	 { (char *)"Driver_name_get", _wrap_Driver_name_get, METH_VARARGS, NULL},
	 { (char *)"Driver_CreateDataSource", (PyCFunction) _wrap_Driver_CreateDataSource, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Driver_CopyDataSource", (PyCFunction) _wrap_Driver_CopyDataSource, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Driver_Open", (PyCFunction) _wrap_Driver_Open, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Driver_DeleteDataSource", _wrap_Driver_DeleteDataSource, METH_VARARGS, NULL},
	 { (char *)"Driver_TestCapability", _wrap_Driver_TestCapability, METH_VARARGS, NULL},
	 { (char *)"Driver_GetName", _wrap_Driver_GetName, METH_VARARGS, NULL},
	 { (char *)"Driver_swigregister", Driver_swigregister, METH_VARARGS, NULL},
	 { (char *)"DataSource_name_get", _wrap_DataSource_name_get, METH_VARARGS, NULL},
	 { (char *)"DataSource_Destroy", _wrap_DataSource_Destroy, METH_VARARGS, NULL},
	 { (char *)"DataSource_Release", _wrap_DataSource_Release, METH_VARARGS, NULL},
	 { (char *)"DataSource_Reference", _wrap_DataSource_Reference, METH_VARARGS, NULL},
	 { (char *)"DataSource_Dereference", _wrap_DataSource_Dereference, METH_VARARGS, NULL},
	 { (char *)"DataSource_GetRefCount", _wrap_DataSource_GetRefCount, METH_VARARGS, NULL},
	 { (char *)"DataSource_GetSummaryRefCount", _wrap_DataSource_GetSummaryRefCount, METH_VARARGS, NULL},
	 { (char *)"DataSource_GetLayerCount", _wrap_DataSource_GetLayerCount, METH_VARARGS, NULL},
	 { (char *)"DataSource_GetName", _wrap_DataSource_GetName, METH_VARARGS, NULL},
	 { (char *)"DataSource_DeleteLayer", _wrap_DataSource_DeleteLayer, METH_VARARGS, NULL},
	 { (char *)"DataSource_CreateLayer", (PyCFunction) _wrap_DataSource_CreateLayer, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"DataSource_CopyLayer", (PyCFunction) _wrap_DataSource_CopyLayer, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"DataSource_GetLayerByIndex", (PyCFunction) _wrap_DataSource_GetLayerByIndex, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"DataSource_GetLayerByName", _wrap_DataSource_GetLayerByName, METH_VARARGS, NULL},
	 { (char *)"DataSource_TestCapability", _wrap_DataSource_TestCapability, METH_VARARGS, NULL},
	 { (char *)"DataSource_ExecuteSQL", (PyCFunction) _wrap_DataSource_ExecuteSQL, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"DataSource_ReleaseResultSet", _wrap_DataSource_ReleaseResultSet, METH_VARARGS, NULL},
	 { (char *)"DataSource_swigregister", DataSource_swigregister, METH_VARARGS, NULL},
	 { (char *)"Layer_Reference", _wrap_Layer_Reference, METH_VARARGS, NULL},
	 { (char *)"Layer_Dereference", _wrap_Layer_Dereference, METH_VARARGS, NULL},
	 { (char *)"Layer_GetRefCount", _wrap_Layer_GetRefCount, METH_VARARGS, NULL},
	 { (char *)"Layer_SetSpatialFilter", _wrap_Layer_SetSpatialFilter, METH_VARARGS, NULL},
	 { (char *)"Layer_SetSpatialFilterRect", _wrap_Layer_SetSpatialFilterRect, METH_VARARGS, NULL},
	 { (char *)"Layer_GetSpatialFilter", _wrap_Layer_GetSpatialFilter, METH_VARARGS, NULL},
	 { (char *)"Layer_SetAttributeFilter", _wrap_Layer_SetAttributeFilter, METH_VARARGS, NULL},
	 { (char *)"Layer_ResetReading", _wrap_Layer_ResetReading, METH_VARARGS, NULL},
	 { (char *)"Layer_GetName", _wrap_Layer_GetName, METH_VARARGS, NULL},
	 { (char *)"Layer_GetFeature", _wrap_Layer_GetFeature, METH_VARARGS, NULL},
	 { (char *)"Layer_GetNextFeature", _wrap_Layer_GetNextFeature, METH_VARARGS, NULL},
	 { (char *)"Layer_SetNextByIndex", _wrap_Layer_SetNextByIndex, METH_VARARGS, NULL},
	 { (char *)"Layer_SetFeature", _wrap_Layer_SetFeature, METH_VARARGS, NULL},
	 { (char *)"Layer_CreateFeature", _wrap_Layer_CreateFeature, METH_VARARGS, NULL},
	 { (char *)"Layer_DeleteFeature", _wrap_Layer_DeleteFeature, METH_VARARGS, NULL},
	 { (char *)"Layer_SyncToDisk", _wrap_Layer_SyncToDisk, METH_VARARGS, NULL},
	 { (char *)"Layer_GetLayerDefn", _wrap_Layer_GetLayerDefn, METH_VARARGS, NULL},
	 { (char *)"Layer_GetFeatureCount", (PyCFunction) _wrap_Layer_GetFeatureCount, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Layer_GetExtent", (PyCFunction) _wrap_Layer_GetExtent, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Layer_TestCapability", _wrap_Layer_TestCapability, METH_VARARGS, NULL},
	 { (char *)"Layer_CreateField", (PyCFunction) _wrap_Layer_CreateField, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Layer_StartTransaction", _wrap_Layer_StartTransaction, METH_VARARGS, NULL},
	 { (char *)"Layer_CommitTransaction", _wrap_Layer_CommitTransaction, METH_VARARGS, NULL},
	 { (char *)"Layer_RollbackTransaction", _wrap_Layer_RollbackTransaction, METH_VARARGS, NULL},
	 { (char *)"Layer_GetSpatialRef", _wrap_Layer_GetSpatialRef, METH_VARARGS, NULL},
	 { (char *)"Layer_GetFeatureRead", _wrap_Layer_GetFeatureRead, METH_VARARGS, NULL},
	 { (char *)"Layer_swigregister", Layer_swigregister, METH_VARARGS, NULL},
	 { (char *)"new_Feature", (PyCFunction) _wrap_new_Feature, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Feature_Destroy", _wrap_Feature_Destroy, METH_VARARGS, NULL},
	 { (char *)"Feature_GetDefnRef", _wrap_Feature_GetDefnRef, METH_VARARGS, NULL},
	 { (char *)"Feature_SetGeometry", _wrap_Feature_SetGeometry, METH_VARARGS, NULL},
	 { (char *)"Feature_SetGeometryDirectly", _wrap_Feature_SetGeometryDirectly, METH_VARARGS, NULL},
	 { (char *)"Feature_GetGeometryRef", _wrap_Feature_GetGeometryRef, METH_VARARGS, NULL},
	 { (char *)"Feature_Clone", _wrap_Feature_Clone, METH_VARARGS, NULL},
	 { (char *)"Feature_Equal", _wrap_Feature_Equal, METH_VARARGS, NULL},
	 { (char *)"Feature_GetFieldCount", _wrap_Feature_GetFieldCount, METH_VARARGS, NULL},
	 { (char *)"Feature_GetFieldDefnRef", _wrap_Feature_GetFieldDefnRef, METH_VARARGS, NULL},
	 { (char *)"Feature_GetFieldAsString", _wrap_Feature_GetFieldAsString, METH_VARARGS, NULL},
	 { (char *)"Feature_GetFieldAsInteger", _wrap_Feature_GetFieldAsInteger, METH_VARARGS, NULL},
	 { (char *)"Feature_GetFieldAsDouble", _wrap_Feature_GetFieldAsDouble, METH_VARARGS, NULL},
	 { (char *)"Feature_IsFieldSet", _wrap_Feature_IsFieldSet, METH_VARARGS, NULL},
	 { (char *)"Feature_GetFieldIndex", _wrap_Feature_GetFieldIndex, METH_VARARGS, NULL},
	 { (char *)"Feature_GetFID", _wrap_Feature_GetFID, METH_VARARGS, NULL},
	 { (char *)"Feature_SetFID", _wrap_Feature_SetFID, METH_VARARGS, NULL},
	 { (char *)"Feature_DumpReadable", _wrap_Feature_DumpReadable, METH_VARARGS, NULL},
	 { (char *)"Feature_UnsetField", _wrap_Feature_UnsetField, METH_VARARGS, NULL},
	 { (char *)"Feature_SetField", _wrap_Feature_SetField, METH_VARARGS, NULL},
	 { (char *)"Feature_SetFrom", (PyCFunction) _wrap_Feature_SetFrom, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Feature_GetStyleString", _wrap_Feature_GetStyleString, METH_VARARGS, NULL},
	 { (char *)"Feature_SetStyleString", _wrap_Feature_SetStyleString, METH_VARARGS, NULL},
	 { (char *)"Feature_GetFieldType", _wrap_Feature_GetFieldType, METH_VARARGS, NULL},
	 { (char *)"Feature_swigregister", Feature_swigregister, METH_VARARGS, NULL},
	 { (char *)"new_FeatureDefn", (PyCFunction) _wrap_new_FeatureDefn, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"FeatureDefn_Destroy", _wrap_FeatureDefn_Destroy, METH_VARARGS, NULL},
	 { (char *)"FeatureDefn_GetName", _wrap_FeatureDefn_GetName, METH_VARARGS, NULL},
	 { (char *)"FeatureDefn_GetFieldCount", _wrap_FeatureDefn_GetFieldCount, METH_VARARGS, NULL},
	 { (char *)"FeatureDefn_GetFieldDefn", _wrap_FeatureDefn_GetFieldDefn, METH_VARARGS, NULL},
	 { (char *)"FeatureDefn_GetFieldIndex", _wrap_FeatureDefn_GetFieldIndex, METH_VARARGS, NULL},
	 { (char *)"FeatureDefn_AddFieldDefn", _wrap_FeatureDefn_AddFieldDefn, METH_VARARGS, NULL},
	 { (char *)"FeatureDefn_GetGeomType", _wrap_FeatureDefn_GetGeomType, METH_VARARGS, NULL},
	 { (char *)"FeatureDefn_SetGeomType", _wrap_FeatureDefn_SetGeomType, METH_VARARGS, NULL},
	 { (char *)"FeatureDefn_Reference", _wrap_FeatureDefn_Reference, METH_VARARGS, NULL},
	 { (char *)"FeatureDefn_Dereference", _wrap_FeatureDefn_Dereference, METH_VARARGS, NULL},
	 { (char *)"FeatureDefn_GetReferenceCount", _wrap_FeatureDefn_GetReferenceCount, METH_VARARGS, NULL},
	 { (char *)"FeatureDefn_swigregister", FeatureDefn_swigregister, METH_VARARGS, NULL},
	 { (char *)"new_FieldDefn", (PyCFunction) _wrap_new_FieldDefn, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"FieldDefn_Destroy", _wrap_FieldDefn_Destroy, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_GetName", _wrap_FieldDefn_GetName, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_GetNameRef", _wrap_FieldDefn_GetNameRef, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_SetName", _wrap_FieldDefn_SetName, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_GetType", _wrap_FieldDefn_GetType, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_SetType", _wrap_FieldDefn_SetType, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_GetJustify", _wrap_FieldDefn_GetJustify, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_SetJustify", _wrap_FieldDefn_SetJustify, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_GetWidth", _wrap_FieldDefn_GetWidth, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_SetWidth", _wrap_FieldDefn_SetWidth, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_GetPrecision", _wrap_FieldDefn_GetPrecision, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_SetPrecision", _wrap_FieldDefn_SetPrecision, METH_VARARGS, NULL},
	 { (char *)"FieldDefn_swigregister", FieldDefn_swigregister, METH_VARARGS, NULL},
	 { (char *)"CreateGeometryFromWkb", (PyCFunction) _wrap_CreateGeometryFromWkb, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"CreateGeometryFromWkt", (PyCFunction) _wrap_CreateGeometryFromWkt, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"CreateGeometryFromGML", _wrap_CreateGeometryFromGML, METH_VARARGS, NULL},
	 { (char *)"new_Geometry", (PyCFunction) _wrap_new_Geometry, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Geometry_ExportToWkt", _wrap_Geometry_ExportToWkt, METH_VARARGS, NULL},
	 { (char *)"Geometry_ExportToWkb", (PyCFunction) _wrap_Geometry_ExportToWkb, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Geometry_ExportToGML", _wrap_Geometry_ExportToGML, METH_VARARGS, NULL},
	 { (char *)"Geometry_AddPoint", (PyCFunction) _wrap_Geometry_AddPoint, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Geometry_AddGeometryDirectly", _wrap_Geometry_AddGeometryDirectly, METH_VARARGS, NULL},
	 { (char *)"Geometry_AddGeometry", _wrap_Geometry_AddGeometry, METH_VARARGS, NULL},
	 { (char *)"Geometry_Clone", _wrap_Geometry_Clone, METH_VARARGS, NULL},
	 { (char *)"Geometry_Destroy", _wrap_Geometry_Destroy, METH_VARARGS, NULL},
	 { (char *)"Geometry_GetGeometryType", _wrap_Geometry_GetGeometryType, METH_VARARGS, NULL},
	 { (char *)"Geometry_GetGeometryName", _wrap_Geometry_GetGeometryName, METH_VARARGS, NULL},
	 { (char *)"Geometry_GetArea", _wrap_Geometry_GetArea, METH_VARARGS, NULL},
	 { (char *)"Geometry_GetPointCount", _wrap_Geometry_GetPointCount, METH_VARARGS, NULL},
	 { (char *)"Geometry_GetX", (PyCFunction) _wrap_Geometry_GetX, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Geometry_GetY", (PyCFunction) _wrap_Geometry_GetY, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Geometry_GetZ", (PyCFunction) _wrap_Geometry_GetZ, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Geometry_GetGeometryCount", _wrap_Geometry_GetGeometryCount, METH_VARARGS, NULL},
	 { (char *)"Geometry_SetPoint", (PyCFunction) _wrap_Geometry_SetPoint, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Geometry_GetGeometryRef", _wrap_Geometry_GetGeometryRef, METH_VARARGS, NULL},
	 { (char *)"Geometry_GetBoundary", _wrap_Geometry_GetBoundary, METH_VARARGS, NULL},
	 { (char *)"Geometry_ConvexHull", _wrap_Geometry_ConvexHull, METH_VARARGS, NULL},
	 { (char *)"Geometry_Buffer", (PyCFunction) _wrap_Geometry_Buffer, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"Geometry_Intersection", _wrap_Geometry_Intersection, METH_VARARGS, NULL},
	 { (char *)"Geometry_Union", _wrap_Geometry_Union, METH_VARARGS, NULL},
	 { (char *)"Geometry_Difference", _wrap_Geometry_Difference, METH_VARARGS, NULL},
	 { (char *)"Geometry_SymmetricDifference", _wrap_Geometry_SymmetricDifference, METH_VARARGS, NULL},
	 { (char *)"Geometry_Distance", _wrap_Geometry_Distance, METH_VARARGS, NULL},
	 { (char *)"Geometry_Empty", _wrap_Geometry_Empty, METH_VARARGS, NULL},
	 { (char *)"Geometry_Intersect", _wrap_Geometry_Intersect, METH_VARARGS, NULL},
	 { (char *)"Geometry_Equal", _wrap_Geometry_Equal, METH_VARARGS, NULL},
	 { (char *)"Geometry_Disjoint", _wrap_Geometry_Disjoint, METH_VARARGS, NULL},
	 { (char *)"Geometry_Touches", _wrap_Geometry_Touches, METH_VARARGS, NULL},
	 { (char *)"Geometry_Crosses", _wrap_Geometry_Crosses, METH_VARARGS, NULL},
	 { (char *)"Geometry_Within", _wrap_Geometry_Within, METH_VARARGS, NULL},
	 { (char *)"Geometry_Contains", _wrap_Geometry_Contains, METH_VARARGS, NULL},
	 { (char *)"Geometry_Overlaps", _wrap_Geometry_Overlaps, METH_VARARGS, NULL},
	 { (char *)"Geometry_TransformTo", _wrap_Geometry_TransformTo, METH_VARARGS, NULL},
	 { (char *)"Geometry_Transform", _wrap_Geometry_Transform, METH_VARARGS, NULL},
	 { (char *)"Geometry_GetSpatialReference", _wrap_Geometry_GetSpatialReference, METH_VARARGS, NULL},
	 { (char *)"Geometry_AssignSpatialReference", _wrap_Geometry_AssignSpatialReference, METH_VARARGS, NULL},
	 { (char *)"Geometry_CloseRings", _wrap_Geometry_CloseRings, METH_VARARGS, NULL},
	 { (char *)"Geometry_FlattenTo2D", _wrap_Geometry_FlattenTo2D, METH_VARARGS, NULL},
	 { (char *)"Geometry_GetEnvelope", _wrap_Geometry_GetEnvelope, METH_VARARGS, NULL},
	 { (char *)"Geometry_Centroid", _wrap_Geometry_Centroid, METH_VARARGS, NULL},
	 { (char *)"Geometry_WkbSize", _wrap_Geometry_WkbSize, METH_VARARGS, NULL},
	 { (char *)"Geometry_GetCoordinateDimension", _wrap_Geometry_GetCoordinateDimension, METH_VARARGS, NULL},
	 { (char *)"Geometry_GetDimension", _wrap_Geometry_GetDimension, METH_VARARGS, NULL},
	 { (char *)"Geometry_swigregister", Geometry_swigregister, METH_VARARGS, NULL},
	 { (char *)"GetDriverCount", _wrap_GetDriverCount, METH_VARARGS, NULL},
	 { (char *)"GetOpenDSCount", _wrap_GetOpenDSCount, METH_VARARGS, NULL},
	 { (char *)"SetGenerate_DB2_V72_BYTE_ORDER", _wrap_SetGenerate_DB2_V72_BYTE_ORDER, METH_VARARGS, NULL},
	 { (char *)"RegisterAll", _wrap_RegisterAll, METH_VARARGS, NULL},
	 { (char *)"GetDriverByName", _wrap_GetDriverByName, METH_VARARGS, NULL},
	 { (char *)"GetDriver", _wrap_GetDriver, METH_VARARGS, NULL},
	 { (char *)"GetOpenDS", _wrap_GetOpenDS, METH_VARARGS, NULL},
	 { (char *)"Open", (PyCFunction) _wrap_Open, METH_VARARGS | METH_KEYWORDS, NULL},
	 { (char *)"OpenShared", (PyCFunction) _wrap_OpenShared, METH_VARARGS | METH_KEYWORDS, NULL},
	 { NULL, NULL, 0, NULL }
};


/* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */

static swig_type_info _swigt__p_GIntBig = {"_p_GIntBig", "GIntBig *", 0, 0, 0};
static swig_type_info _swigt__p_OGRDataSourceShadow = {"_p_OGRDataSourceShadow", "OGRDataSourceShadow *", 0, 0, 0};
static swig_type_info _swigt__p_OGRDriverShadow = {"_p_OGRDriverShadow", "OGRDriverShadow *", 0, 0, 0};
static swig_type_info _swigt__p_OGRFeatureDefnShadow = {"_p_OGRFeatureDefnShadow", "OGRFeatureDefnShadow *", 0, 0, 0};
static swig_type_info _swigt__p_OGRFeatureShadow = {"_p_OGRFeatureShadow", "OGRFeatureShadow *", 0, 0, 0};
static swig_type_info _swigt__p_OGRFieldDefnShadow = {"_p_OGRFieldDefnShadow", "OGRFieldDefnShadow *", 0, 0, 0};
static swig_type_info _swigt__p_OGRGeometryShadow = {"_p_OGRGeometryShadow", "OGRGeometryShadow *", 0, 0, 0};
static swig_type_info _swigt__p_OGRLayerShadow = {"_p_OGRLayerShadow", "OGRLayerShadow *", 0, 0, 0};
static swig_type_info _swigt__p_OSRCoordinateTransformationShadow = {"_p_OSRCoordinateTransformationShadow", "OSRCoordinateTransformationShadow *", 0, 0, 0};
static swig_type_info _swigt__p_OSRSpatialReferenceShadow = {"_p_OSRSpatialReferenceShadow", "OSRSpatialReferenceShadow *", 0, 0, 0};
static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, 0};
static swig_type_info _swigt__p_double = {"_p_double", "double *", 0, 0, 0};
static swig_type_info _swigt__p_int = {"_p_int", "int *", 0, 0, 0};
static swig_type_info _swigt__p_p_char = {"_p_p_char", "char **", 0, 0, 0};
static swig_type_info _swigt__ptrdiff_t = {"_ptrdiff_t", "ptrdiff_t", 0, 0, 0};
static swig_type_info _swigt__size_t = {"_size_t", "size_t", 0, 0, 0};
static swig_type_info _swigt__std__ptrdiff_t = {"_std__ptrdiff_t", "std::ptrdiff_t", 0, 0, 0};
static swig_type_info _swigt__std__size_t = {"_std__size_t", "std::size_t", 0, 0, 0};

static swig_type_info *swig_type_initial[] = {
  &_swigt__p_GIntBig,
  &_swigt__p_OGRDataSourceShadow,
  &_swigt__p_OGRDriverShadow,
  &_swigt__p_OGRFeatureDefnShadow,
  &_swigt__p_OGRFeatureShadow,
  &_swigt__p_OGRFieldDefnShadow,
  &_swigt__p_OGRGeometryShadow,
  &_swigt__p_OGRLayerShadow,
  &_swigt__p_OSRCoordinateTransformationShadow,
  &_swigt__p_OSRSpatialReferenceShadow,
  &_swigt__p_char,
  &_swigt__p_double,
  &_swigt__p_int,
  &_swigt__p_p_char,
  &_swigt__ptrdiff_t,
  &_swigt__size_t,
  &_swigt__std__ptrdiff_t,
  &_swigt__std__size_t,
};

static swig_cast_info _swigc__p_GIntBig[] = {  {&_swigt__p_GIntBig, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OGRDataSourceShadow[] = {  {&_swigt__p_OGRDataSourceShadow, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OGRDriverShadow[] = {  {&_swigt__p_OGRDriverShadow, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OGRFeatureDefnShadow[] = {  {&_swigt__p_OGRFeatureDefnShadow, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OGRFeatureShadow[] = {  {&_swigt__p_OGRFeatureShadow, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OGRFieldDefnShadow[] = {  {&_swigt__p_OGRFieldDefnShadow, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OGRGeometryShadow[] = {  {&_swigt__p_OGRGeometryShadow, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OGRLayerShadow[] = {  {&_swigt__p_OGRLayerShadow, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OSRCoordinateTransformationShadow[] = {  {&_swigt__p_OSRCoordinateTransformationShadow, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_OSRSpatialReferenceShadow[] = {  {&_swigt__p_OSRSpatialReferenceShadow, 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_double[] = {  {&_swigt__p_double, 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_p_char[] = {  {&_swigt__p_p_char, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__ptrdiff_t[] = {  {&_swigt__ptrdiff_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__size_t[] = {  {&_swigt__size_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__std__ptrdiff_t[] = {  {&_swigt__std__ptrdiff_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__std__size_t[] = {  {&_swigt__std__size_t, 0, 0, 0},{0, 0, 0, 0}};

static swig_cast_info *swig_cast_initial[] = {
  _swigc__p_GIntBig,
  _swigc__p_OGRDataSourceShadow,
  _swigc__p_OGRDriverShadow,
  _swigc__p_OGRFeatureDefnShadow,
  _swigc__p_OGRFeatureShadow,
  _swigc__p_OGRFieldDefnShadow,
  _swigc__p_OGRGeometryShadow,
  _swigc__p_OGRLayerShadow,
  _swigc__p_OSRCoordinateTransformationShadow,
  _swigc__p_OSRSpatialReferenceShadow,
  _swigc__p_char,
  _swigc__p_double,
  _swigc__p_int,
  _swigc__p_p_char,
  _swigc__ptrdiff_t,
  _swigc__size_t,
  _swigc__std__ptrdiff_t,
  _swigc__std__size_t,
};


/* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */

static swig_const_info swig_const_table[] = {
{ SWIG_PY_POINTER, (char*)"OLCRandomRead", 0, 0, (void *)"RandomRead", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"OLCSequentialWrite", 0, 0, (void *)"SequentialWrite", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"OLCRandomWrite", 0, 0, (void *)"RandomWrite", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"OLCFastSpatialFilter", 0, 0, (void *)"FastSpatialFilter", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"OLCFastFeatureCount", 0, 0, (void *)"FastFeatureCount", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"OLCFastGetExtent", 0, 0, (void *)"FastGetExtent", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"OLCCreateField", 0, 0, (void *)"CreateField", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"OLCTransactions", 0, 0, (void *)"Transactions", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"OLCDeleteFeature", 0, 0, (void *)"DeleteFeature", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"OLCFastSetNextByIndex", 0, 0, (void *)"FastSetNextByIndex", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"ODsCCreateLayer", 0, 0, (void *)"CreateLayer", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"ODsCDeleteLayer", 0, 0, (void *)"DeleteLayer", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"ODrCCreateDataSource", 0, 0, (void *)"CreateDataSource", &SWIGTYPE_p_char},
{ SWIG_PY_POINTER, (char*)"ODrCDeleteDataSource", 0, 0, (void *)"DeleteDataSource", &SWIGTYPE_p_char},
{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 staticly to an initial 
 * array. We just loop though 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" {
#endif
    
    SWIGRUNTIME void
    SWIG_InitializeModule(void *clientdata) {
        swig_type_info *type, *ret;
        swig_cast_info *cast;
        size_t i;
        swig_module_info *module_head;
        static int init_run = 0;
        
        clientdata = clientdata;
        
        if (init_run) return;
        init_run = 1;
        
        /* Initialize the swig_module */
        swig_module.type_initial = swig_type_initial;
        swig_module.cast_initial = swig_cast_initial;
        
        /* Try and load any already created modules */
        module_head = SWIG_GetModule(clientdata);
        if (module_head) {
            swig_module.next = module_head->next;
            module_head->next = &swig_module;
        } else {
            /* This is the first module loaded */
            swig_module.next = &swig_module;
            SWIG_SetModule(clientdata, &swig_module);
        }
        
        /* Now work on filling in swig_module.types */
        for (i = 0; i < swig_module.size; ++i) {
            type = 0;
            
            /* 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 */
                if (swig_module.type_initial[i]->clientdata) type->clientdata = swig_module.type_initial[i]->clientdata;
            } 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;
                if (swig_module.next != &swig_module) {
                    ret = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, cast->type->name);
                }
                if (ret && type == swig_module.type_initial[i]) {
                    cast->type = ret;
                    ret = 0;
                }
                
                if (!ret) {
                    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;
        }
    }
    
    /* 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
}
#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 *v) {
        v = v;
        return PyString_FromString("<Swig global variables>");
    }
    
    SWIGINTERN int
    swig_varlink_print(swig_varlinkobject *v, FILE *fp, int flags) {
        swig_globalvar  *var;
        flags = flags;
        fprintf(fp,"Swig global variables { ");
        for (var = v->vars; var; var=var->next) {
            fprintf(fp,"%s", var->name);
            if (var->next) fprintf(fp,", ");
        }
        fprintf(fp," }\n");
        return 0;
    }
    
    SWIGINTERN PyObject *
    swig_varlink_getattr(swig_varlinkobject *v, char *n) {
        swig_globalvar *var = v->vars;
        while (var) {
            if (strcmp(var->name,n) == 0) {
                return (*var->get_attr)();
            }
            var = var->next;
        }
        PyErr_SetString(PyExc_NameError,"Unknown C global variable");
        return NULL;
    }
    
    SWIGINTERN int
    swig_varlink_setattr(swig_varlinkobject *v, char *n, PyObject *p) {
        swig_globalvar *var = v->vars;
        while (var) {
            if (strcmp(var->name,n) == 0) {
                return (*var->set_attr)(p);
            }
            var = var->next;
        }
        PyErr_SetString(PyExc_NameError,"Unknown C global variable");
        return 1;
    }
    
    SWIGINTERN PyTypeObject*
    swig_varlink_type(void) {
        static char varlink__doc__[] = "Swig var link object";
        static PyTypeObject varlink_type
#if !defined(__cplusplus)
        ;
        static int type_init = 0;  
        if (!type_init) {
            PyTypeObject tmp
#endif
            = {
                PyObject_HEAD_INIT(&PyType_Type)
                0,                                  /* Number of items in variable part (ob_size) */
                (char *)"swigvarlink",              /* Type name (tp_name) */
                sizeof(swig_varlinkobject),         /* Basic size (tp_basicsize) */
                0,                                  /* Itemsize (tp_itemsize) */
                0,                                  /* Deallocator (tp_dealloc) */ 
                (printfunc) swig_varlink_print,     /* Print (tp_print) */
                (getattrfunc) swig_varlink_getattr, /* get attr (tp_getattr) */
                (setattrfunc) swig_varlink_setattr, /* Set attr (tp_setattr) */
                0,                                  /* 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 */
                0,                                  /* tp_str */
                0,                                  /* tp_getattro */
                0,                                  /* tp_setattro */
                0,                                  /* tp_as_buffer */
                0,                                  /* tp_flags */
                varlink__doc__,                     /* tp_doc */
#if PY_VERSION_HEX >= 0x02000000
                0,                                  /* tp_traverse */
                0,                                  /* tp_clear */
#endif
#if PY_VERSION_HEX >= 0x02010000
                0,                                  /* tp_richcompare */
                0,                                  /* tp_weaklistoffset */
#endif
#if PY_VERSION_HEX >= 0x02020000
                0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */
#endif
#if PY_VERSION_HEX >= 0x02030000
                0,                                  /* tp_del */
#endif
#ifdef COUNT_ALLOCS
                0,0,0,0                             /* tp_alloc -> tp_next */
#endif
            };
#if !defined(__cplusplus)
            varlink_type = tmp;
            type_init = 1;
        }
#endif
        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, 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) {
                strncpy(gv->name,name,size);
                gv->get_attr = get_attr;
                gv->set_attr = set_attr;
                gv->next = v->vars;
            }
        }
        v->vars = gv;
    }
    
    /* -----------------------------------------------------------------------------
     * 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_INT:
                obj = PyInt_FromLong(constants[i].lvalue);
                break;
                case SWIG_PY_FLOAT:
                obj = PyFloat_FromDouble(constants[i].dvalue);
                break;
                case SWIG_PY_STRING:
                if (constants[i].pvalue) {
                    obj = PyString_FromString((char *) constants[i].pvalue);
                } else {
                    Py_INCREF(Py_None);
                    obj = Py_None;
                }
                break;
                case SWIG_PY_POINTER:
                obj = SWIG_NewPointerObj(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) {
            char *c = methods[i].ml_doc;
            if (c && (c = strstr(c, "swig_ptr: "))) {
                int j;
                swig_const_info *ci = 0;
                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) {
                    size_t shift = (ci->ptype) - types;
                    swig_type_info *ty = types_initial[shift];
                    size_t ldoc = (c - methods[i].ml_doc);
                    size_t lptr = strlen(ty->name)+2*sizeof(void*)+2;
                    char *ndoc = (char*)malloc(ldoc + lptr + 10);
                    if (ndoc) {
                        char *buff = ndoc;
                        void *ptr = (ci->type == SWIG_PY_POINTER) ? ci->pvalue : 0;
                        if (ptr) {
                            strncpy(buff, methods[i].ml_doc, ldoc);
                            buff += ldoc;
                            strncpy(buff, "swig_ptr: ", 10);
                            buff += 10;
                            SWIG_PackVoidPtr(buff, ptr, ty->name, lptr);
                            methods[i].ml_doc = ndoc;
                        }
                    }
                }
            }
        }
    }
    
    /* -----------------------------------------------------------------------------*
     *  Initialize type list
     * -----------------------------------------------------------------------------*/
    
#if PY_MAJOR_VERSION < 2
    /* PyModule_AddObject function was introduced in Python 2.0.  The following function
    is copied out of Python/modsupport.c in python version 2.3.4 */
    SWIGINTERN int
    PyModule_AddObject(PyObject *m, char *name, PyObject *o)
    {
        PyObject *dict;
        if (!PyModule_Check(m)) {
            PyErr_SetString(PyExc_TypeError,
            "PyModule_AddObject() needs module as first arg");
            return -1;
        }
        if (!o) {
            PyErr_SetString(PyExc_TypeError,
            "PyModule_AddObject() needs non-NULL value");
            return -1;
        }
        
        dict = PyModule_GetDict(m);
        if (dict == NULL) {
            /* Internal error -- modules must have a dict! */
            PyErr_Format(PyExc_SystemError, "module '%s' has no __dict__",
            PyModule_GetName(m));
            return -1;
        }
        if (PyDict_SetItemString(dict, name, o))
        return -1;
        Py_DECREF(o);
        return 0;
    }
#endif
    
#ifdef __cplusplus
}
#endif

/* -----------------------------------------------------------------------------*
 *  Partial Init method
 * -----------------------------------------------------------------------------*/

#ifdef __cplusplus
extern "C"
#endif
SWIGEXPORT void SWIG_init(void) {
    static PyObject *SWIG_globals = 0; 
    PyObject *m, *d;
    if (!SWIG_globals) SWIG_globals = SWIG_newvarlink();
    
    /* Fix SwigMethods to carry the callback ptrs when needed */
    SWIG_Python_FixMethods(SwigMethods, swig_const_table, swig_types, swig_type_initial);
    
    m = Py_InitModule((char *) SWIG_name, SwigMethods);
    d = PyModule_GetDict(m);
    
    SWIG_InitializeModule(0);
    SWIG_InstallConstants(d,swig_const_table);
    
    
    
    if ( OGRGetDriverCount() == 0 ) {
        OGRRegisterAll();
    }
    
    
    {
        PyDict_SetItemString(d,"wkb25Bit", SWIG_From_int((int)(-2147483648))); 
    }
    {
        PyDict_SetItemString(d,"wkbUnknown", SWIG_From_int((int)(0))); 
    }
    {
        PyDict_SetItemString(d,"wkbPoint", SWIG_From_int((int)(1))); 
    }
    {
        PyDict_SetItemString(d,"wkbLineString", SWIG_From_int((int)(2))); 
    }
    {
        PyDict_SetItemString(d,"wkbPolygon", SWIG_From_int((int)(3))); 
    }
    {
        PyDict_SetItemString(d,"wkbMultiPoint", SWIG_From_int((int)(4))); 
    }
    {
        PyDict_SetItemString(d,"wkbMultiLineString", SWIG_From_int((int)(5))); 
    }
    {
        PyDict_SetItemString(d,"wkbMultiPolygon", SWIG_From_int((int)(6))); 
    }
    {
        PyDict_SetItemString(d,"wkbGeometryCollection", SWIG_From_int((int)(7))); 
    }
    {
        PyDict_SetItemString(d,"wkbNone", SWIG_From_int((int)(100))); 
    }
    {
        PyDict_SetItemString(d,"wkbLinearRing", SWIG_From_int((int)(101))); 
    }
    {
        PyDict_SetItemString(d,"wkbPoint25D", SWIG_From_int((int)(wkbPoint+wkb25DBit))); 
    }
    {
        PyDict_SetItemString(d,"wkbLineString25D", SWIG_From_int((int)(wkbLineString+wkb25DBit))); 
    }
    {
        PyDict_SetItemString(d,"wkbPolygon25D", SWIG_From_int((int)(wkbPolygon+wkb25DBit))); 
    }
    {
        PyDict_SetItemString(d,"wkbMultiPoint25D", SWIG_From_int((int)(wkbMultiPoint+wkb25DBit))); 
    }
    {
        PyDict_SetItemString(d,"wkbMultiLineString25D", SWIG_From_int((int)(wkbMultiLineString+wkb25DBit))); 
    }
    {
        PyDict_SetItemString(d,"wkbMultiPolygon25D", SWIG_From_int((int)(wkbMultiPolygon+wkb25DBit))); 
    }
    {
        PyDict_SetItemString(d,"wkbGeometryCollection25D", SWIG_From_int((int)(wkbGeometryCollection+wkb25DBit))); 
    }
    {
        PyDict_SetItemString(d,"OFTInteger", SWIG_From_int((int)(0))); 
    }
    {
        PyDict_SetItemString(d,"OFTIntegerList", SWIG_From_int((int)(1))); 
    }
    {
        PyDict_SetItemString(d,"OFTReal", SWIG_From_int((int)(2))); 
    }
    {
        PyDict_SetItemString(d,"OFTRealList", SWIG_From_int((int)(3))); 
    }
    {
        PyDict_SetItemString(d,"OFTString", SWIG_From_int((int)(4))); 
    }
    {
        PyDict_SetItemString(d,"OFTStringList", SWIG_From_int((int)(5))); 
    }
    {
        PyDict_SetItemString(d,"OFTWideString", SWIG_From_int((int)(6))); 
    }
    {
        PyDict_SetItemString(d,"OFTWideStringList", SWIG_From_int((int)(7))); 
    }
    {
        PyDict_SetItemString(d,"OFTBinary", SWIG_From_int((int)(8))); 
    }
    {
        PyDict_SetItemString(d,"OJUndefined", SWIG_From_int((int)(0))); 
    }
    {
        PyDict_SetItemString(d,"OJLeft", SWIG_From_int((int)(1))); 
    }
    {
        PyDict_SetItemString(d,"OJRight", SWIG_From_int((int)(2))); 
    }
    {
        PyDict_SetItemString(d,"wkbXDR", SWIG_From_int((int)(0))); 
    }
    {
        PyDict_SetItemString(d,"wkbNDR", SWIG_From_int((int)(1))); 
    }
    PyDict_SetItemString(d,"OLCRandomRead", SWIG_FromCharPtr("RandomRead"));
    PyDict_SetItemString(d,"OLCSequentialWrite", SWIG_FromCharPtr("SequentialWrite"));
    PyDict_SetItemString(d,"OLCRandomWrite", SWIG_FromCharPtr("RandomWrite"));
    PyDict_SetItemString(d,"OLCFastSpatialFilter", SWIG_FromCharPtr("FastSpatialFilter"));
    PyDict_SetItemString(d,"OLCFastFeatureCount", SWIG_FromCharPtr("FastFeatureCount"));
    PyDict_SetItemString(d,"OLCFastGetExtent", SWIG_FromCharPtr("FastGetExtent"));
    PyDict_SetItemString(d,"OLCCreateField", SWIG_FromCharPtr("CreateField"));
    PyDict_SetItemString(d,"OLCTransactions", SWIG_FromCharPtr("Transactions"));
    PyDict_SetItemString(d,"OLCDeleteFeature", SWIG_FromCharPtr("DeleteFeature"));
    PyDict_SetItemString(d,"OLCFastSetNextByIndex", SWIG_FromCharPtr("FastSetNextByIndex"));
    PyDict_SetItemString(d,"ODsCCreateLayer", SWIG_FromCharPtr("CreateLayer"));
    PyDict_SetItemString(d,"ODsCDeleteLayer", SWIG_FromCharPtr("DeleteLayer"));
    PyDict_SetItemString(d,"ODrCCreateDataSource", SWIG_FromCharPtr("CreateDataSource"));
    PyDict_SetItemString(d,"ODrCDeleteDataSource", SWIG_FromCharPtr("DeleteDataSource"));
}

