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

#define SWIGCSHARP


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

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

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

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

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

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

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

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

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

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

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

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

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

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

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



#include <stdlib.h>
#include <string.h>
#include <stdio.h>


/* Support for throwing C# exceptions from C/C++. There are two types: 
 * Exceptions that take a message and ArgumentExceptions that take a message and a parameter name. */
typedef enum {
  SWIG_CSharpApplicationException,
  SWIG_CSharpArithmeticException,
  SWIG_CSharpDivideByZeroException,
  SWIG_CSharpIndexOutOfRangeException,
  SWIG_CSharpInvalidCastException,
  SWIG_CSharpInvalidOperationException,
  SWIG_CSharpIOException,
  SWIG_CSharpNullReferenceException,
  SWIG_CSharpOutOfMemoryException,
  SWIG_CSharpOverflowException,
  SWIG_CSharpSystemException
} SWIG_CSharpExceptionCodes;

typedef enum {
  SWIG_CSharpArgumentException,
  SWIG_CSharpArgumentNullException,
  SWIG_CSharpArgumentOutOfRangeException
} SWIG_CSharpExceptionArgumentCodes;

typedef void (SWIGSTDCALL* SWIG_CSharpExceptionCallback_t)(const char *);
typedef void (SWIGSTDCALL* SWIG_CSharpExceptionArgumentCallback_t)(const char *, const char *);

typedef struct {
  SWIG_CSharpExceptionCodes code;
  SWIG_CSharpExceptionCallback_t callback;
} SWIG_CSharpException_t;

typedef struct {
  SWIG_CSharpExceptionArgumentCodes code;
  SWIG_CSharpExceptionArgumentCallback_t callback;
} SWIG_CSharpExceptionArgument_t;

static SWIG_CSharpException_t SWIG_csharp_exceptions[] = {
  { SWIG_CSharpApplicationException, NULL },
  { SWIG_CSharpArithmeticException, NULL },
  { SWIG_CSharpDivideByZeroException, NULL },
  { SWIG_CSharpIndexOutOfRangeException, NULL },
  { SWIG_CSharpInvalidCastException, NULL },
  { SWIG_CSharpInvalidOperationException, NULL },
  { SWIG_CSharpIOException, NULL },
  { SWIG_CSharpNullReferenceException, NULL },
  { SWIG_CSharpOutOfMemoryException, NULL },
  { SWIG_CSharpOverflowException, NULL },
  { SWIG_CSharpSystemException, NULL }
};

static SWIG_CSharpExceptionArgument_t SWIG_csharp_exceptions_argument[] = {
  { SWIG_CSharpArgumentException, NULL },
  { SWIG_CSharpArgumentNullException, NULL },
  { SWIG_CSharpArgumentOutOfRangeException, NULL },
};

static void SWIGUNUSED SWIG_CSharpSetPendingException(SWIG_CSharpExceptionCodes code, const char *msg) {
  SWIG_CSharpExceptionCallback_t callback = SWIG_csharp_exceptions[SWIG_CSharpApplicationException].callback;
  if ((size_t)code < sizeof(SWIG_csharp_exceptions)/sizeof(SWIG_CSharpException_t)) {
    callback = SWIG_csharp_exceptions[code].callback;
  }
  callback(msg);
}

static void SWIGUNUSED SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpExceptionArgumentCodes code, const char *msg, const char *param_name) {
  SWIG_CSharpExceptionArgumentCallback_t callback = SWIG_csharp_exceptions_argument[SWIG_CSharpArgumentException].callback;
  if ((size_t)code < sizeof(SWIG_csharp_exceptions_argument)/sizeof(SWIG_CSharpExceptionArgument_t)) {
    callback = SWIG_csharp_exceptions_argument[code].callback;
  }
  callback(msg, param_name);
}


#ifdef __cplusplus
extern "C" 
#endif
SWIGEXPORT void SWIGSTDCALL SWIGRegisterExceptionCallbacks_Ogr(
                                                SWIG_CSharpExceptionCallback_t applicationCallback,
                                                SWIG_CSharpExceptionCallback_t arithmeticCallback,
                                                SWIG_CSharpExceptionCallback_t divideByZeroCallback, 
                                                SWIG_CSharpExceptionCallback_t indexOutOfRangeCallback, 
                                                SWIG_CSharpExceptionCallback_t invalidCastCallback,
                                                SWIG_CSharpExceptionCallback_t invalidOperationCallback,
                                                SWIG_CSharpExceptionCallback_t ioCallback,
                                                SWIG_CSharpExceptionCallback_t nullReferenceCallback,
                                                SWIG_CSharpExceptionCallback_t outOfMemoryCallback, 
                                                SWIG_CSharpExceptionCallback_t overflowCallback, 
                                                SWIG_CSharpExceptionCallback_t systemCallback) {
  SWIG_csharp_exceptions[SWIG_CSharpApplicationException].callback = applicationCallback;
  SWIG_csharp_exceptions[SWIG_CSharpArithmeticException].callback = arithmeticCallback;
  SWIG_csharp_exceptions[SWIG_CSharpDivideByZeroException].callback = divideByZeroCallback;
  SWIG_csharp_exceptions[SWIG_CSharpIndexOutOfRangeException].callback = indexOutOfRangeCallback;
  SWIG_csharp_exceptions[SWIG_CSharpInvalidCastException].callback = invalidCastCallback;
  SWIG_csharp_exceptions[SWIG_CSharpInvalidOperationException].callback = invalidOperationCallback;
  SWIG_csharp_exceptions[SWIG_CSharpIOException].callback = ioCallback;
  SWIG_csharp_exceptions[SWIG_CSharpNullReferenceException].callback = nullReferenceCallback;
  SWIG_csharp_exceptions[SWIG_CSharpOutOfMemoryException].callback = outOfMemoryCallback;
  SWIG_csharp_exceptions[SWIG_CSharpOverflowException].callback = overflowCallback;
  SWIG_csharp_exceptions[SWIG_CSharpSystemException].callback = systemCallback;
}

#ifdef __cplusplus
extern "C" 
#endif
SWIGEXPORT void SWIGSTDCALL SWIGRegisterExceptionArgumentCallbacks_Ogr(
                                                SWIG_CSharpExceptionArgumentCallback_t argumentCallback,
                                                SWIG_CSharpExceptionArgumentCallback_t argumentNullCallback,
                                                SWIG_CSharpExceptionArgumentCallback_t argumentOutOfRangeCallback) {
  SWIG_csharp_exceptions_argument[SWIG_CSharpArgumentException].callback = argumentCallback;
  SWIG_csharp_exceptions_argument[SWIG_CSharpArgumentNullException].callback = argumentNullCallback;
  SWIG_csharp_exceptions_argument[SWIG_CSharpArgumentOutOfRangeException].callback = argumentOutOfRangeCallback;
}


/* Callback for returning strings to C# without leaking memory */
typedef char * (SWIGSTDCALL* SWIG_CSharpStringHelperCallback)(const char *);
static SWIG_CSharpStringHelperCallback SWIG_csharp_string_callback = NULL;


#ifdef __cplusplus
extern "C" 
#endif
SWIGEXPORT void SWIGSTDCALL SWIGRegisterStringCallback_Ogr(SWIG_CSharpStringHelperCallback callback) {
  SWIG_csharp_string_callback = callback;
}


/* Contract support */

#define SWIG_contract_assert(nullreturn, expr, msg) if (!(expr)) {SWIG_CSharpSetPendingExceptionArgument(SWIG_CSharpArgumentOutOfRangeException, msg, ""); return nullreturn; } else

/*  Errors in SWIG */
#define  SWIG_UnknownError    	   -1 
#define  SWIG_IOError        	   -2 
#define  SWIG_RuntimeError   	   -3 
#define  SWIG_IndexError     	   -4 
#define  SWIG_TypeError      	   -5 
#define  SWIG_DivisionByZero 	   -6 
#define  SWIG_OverflowError  	   -7 
#define  SWIG_SyntaxError    	   -8 
#define  SWIG_ValueError     	   -9 
#define  SWIG_SystemError    	   -10
#define  SWIG_AttributeError 	   -11
#define  SWIG_MemoryError    	   -12 
#define  SWIG_NullReferenceError   -13




SWIGINTERN void SWIG_CSharpException(int code, const char *msg) {
  if (code == SWIG_ValueError) {
    SWIG_CSharpExceptionArgumentCodes exception_code = SWIG_CSharpArgumentOutOfRangeException;
    SWIG_CSharpSetPendingExceptionArgument(exception_code, msg, 0);
  } else {
    SWIG_CSharpExceptionCodes exception_code = SWIG_CSharpApplicationException;
    switch(code) {
    case SWIG_MemoryError:
      exception_code = SWIG_CSharpOutOfMemoryException;
      break;
    case SWIG_IndexError:
      exception_code = SWIG_CSharpIndexOutOfRangeException;
      break;
    case SWIG_DivisionByZero:
      exception_code = SWIG_CSharpDivideByZeroException;
      break;
    case SWIG_IOError:
      exception_code = SWIG_CSharpIOException;
      break;
    case SWIG_OverflowError:
      exception_code = SWIG_CSharpOverflowException;
      break;
    case SWIG_RuntimeError:
    case SWIG_TypeError:
    case SWIG_SyntaxError:
    case SWIG_SystemError:
    case SWIG_UnknownError:
    default:
      exception_code = SWIG_CSharpApplicationException;
      break;
    }
    SWIG_CSharpSetPendingException(exception_code, msg);
  }
}


#include <stdexcept>


#include <iostream>
using namespace std;

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

#ifdef DEBUG 
typedef struct OGRSpatialReferenceHS OSRSpatialReferenceShadow;
typedef struct OGRDriverHS OGRDriverShadow;
typedef struct OGRDataSourceHS OGRDataSourceShadow;
typedef struct OGRLayerHS OGRLayerShadow;
typedef struct OGRFeatureHS OGRFeatureShadow;
typedef struct OGRFeatureDefnHS OGRFeatureDefnShadow;
typedef struct OGRGeometryHS OGRGeometryShadow;
typedef struct OGRCoordinateTransformationHS OSRCoordinateTransformationShadow;
typedef struct OGRCoordinateTransformationHS OGRCoordinateTransformationShadow;
typedef struct OGRFieldDefnHS OGRFieldDefnShadow;
#else
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;
#endif



void VeryQuiteErrorHandler(CPLErr eclass, int code, const char *msg ) {
  /* If the error class is CE_Fatal, we want to have a message issued
     because the CPL support code does an abort() before any exception
     can be generated */
  if (eclass == CE_Fatal ) {
    CPLDefaultErrorHandler(eclass, code, msg );
  }
}


void UseExceptions() {
  CPLSetErrorHandler( (CPLErrorHandler) VeryQuiteErrorHandler );
}

void DontUseExceptions() {
  CPLSetErrorHandler( CPLDefaultErrorHandler );
}


    typedef char retStringAndCPLFree;


    void StringListDestroy(void *buffer_ptr) {
       CSLDestroy((char**)buffer_ptr);
    }

SWIGINTERN OGRDataSourceShadow *OGRDriverShadow_CreateDataSource(OGRDriverShadow *self,char const *name,char **options=0){
    OGRDataSourceShadow *ds = (OGRDataSourceShadow*) OGR_Dr_CreateDataSource( self, name, options);
    return ds;
  }
SWIGINTERN 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;
  }
SWIGINTERN OGRDataSourceShadow *OGRDriverShadow_Open(OGRDriverShadow *self,char const *name,int update=0){
    OGRDataSourceShadow* ds = (OGRDataSourceShadow*) OGR_Dr_Open(self, name, update);
    return ds;
  }
SWIGINTERN int OGRDriverShadow_DeleteDataSource(OGRDriverShadow *self,char const *name){

    return OGR_Dr_DeleteDataSource( self, name );
  }
SWIGINTERN bool OGRDriverShadow_TestCapability(OGRDriverShadow *self,char const *cap){
    return (OGR_Dr_TestCapability(self, cap) > 0);
  }
SWIGINTERN char const *OGRDriverShadow_GetName(OGRDriverShadow *self){
    return OGR_Dr_GetName( self );
  }
SWIGINTERN void delete_OGRDataSourceShadow(OGRDataSourceShadow *self){
    OGRReleaseDataSource(self);
  }
SWIGINTERN int OGRDataSourceShadow_GetRefCount(OGRDataSourceShadow *self){
    return OGR_DS_GetRefCount(self);
  }
SWIGINTERN int OGRDataSourceShadow_GetSummaryRefCount(OGRDataSourceShadow *self){
    return OGR_DS_GetSummaryRefCount(self);
  }
SWIGINTERN int OGRDataSourceShadow_GetLayerCount(OGRDataSourceShadow *self){
    return OGR_DS_GetLayerCount(self);
  }
SWIGINTERN OGRDriverShadow *OGRDataSourceShadow_GetDriver(OGRDataSourceShadow *self){
    return (OGRDriverShadow *) OGR_DS_GetDriver( self );
  }
SWIGINTERN char const *OGRDataSourceShadow_GetName(OGRDataSourceShadow *self){
    return OGR_DS_GetName(self);
  }
SWIGINTERN 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";
  }
}

SWIGINTERN OGRLayerShadow *OGRDataSourceShadow_CreateLayer(OGRDataSourceShadow *self,char const *name,OSRSpatialReferenceShadow *srs=NULL,OGRwkbGeometryType geom_type=wkbUnknown,char **options=0){
    OGRLayerShadow* layer = (OGRLayerShadow*) OGR_DS_CreateLayer( self,
								  name,
								  srs,
								  geom_type,
								  options);
    return layer;
  }
SWIGINTERN 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;
  }
SWIGINTERN OGRLayerShadow *OGRDataSourceShadow_GetLayerByIndex(OGRDataSourceShadow *self,int index=0){

    OGRLayerShadow* layer = (OGRLayerShadow*) OGR_DS_GetLayer(self, index);
    return layer;
  }
SWIGINTERN OGRLayerShadow *OGRDataSourceShadow_GetLayerByName(OGRDataSourceShadow *self,char const *layer_name){
    OGRLayerShadow* layer = (OGRLayerShadow*) OGR_DS_GetLayerByName(self, layer_name);
    return layer;
  }
SWIGINTERN bool OGRDataSourceShadow_TestCapability(OGRDataSourceShadow *self,char const *cap){
    return (OGR_DS_TestCapability(self, cap) > 0);
  }
SWIGINTERN OGRLayerShadow *OGRDataSourceShadow_ExecuteSQL(OGRDataSourceShadow *self,char const *statement,OGRGeometryShadow *spatialFilter=NULL,char const *dialect=""){
    OGRLayerShadow* layer = (OGRLayerShadow*) OGR_DS_ExecuteSQL((OGRDataSourceShadow*)self,
                                                      statement,
                                                      spatialFilter,
                                                      dialect);
    return layer;
  }
SWIGINTERN void OGRDataSourceShadow_ReleaseResultSet(OGRDataSourceShadow *self,OGRLayerShadow *layer){
    OGR_DS_ReleaseResultSet(self, layer);
  }
SWIGINTERN int OGRLayerShadow_GetRefCount(OGRLayerShadow *self){
    return OGR_L_GetRefCount(self);
  }
SWIGINTERN void OGRLayerShadow_SetSpatialFilter(OGRLayerShadow *self,OGRGeometryShadow *filter){
    OGR_L_SetSpatialFilter (self, filter);
  }
SWIGINTERN void OGRLayerShadow_SetSpatialFilterRect(OGRLayerShadow *self,double minx,double miny,double maxx,double maxy){
    OGR_L_SetSpatialFilterRect(self, minx, miny, maxx, maxy);                          
  }
SWIGINTERN OGRGeometryShadow *OGRLayerShadow_GetSpatialFilter(OGRLayerShadow *self){
    return (OGRGeometryShadow *) OGR_L_GetSpatialFilter(self);
  }
SWIGINTERN OGRErr OGRLayerShadow_SetAttributeFilter(OGRLayerShadow *self,char *filter_string){
    return OGR_L_SetAttributeFilter((OGRLayerShadow*)self, filter_string);
  }
SWIGINTERN void OGRLayerShadow_ResetReading(OGRLayerShadow *self){
    OGR_L_ResetReading(self);
  }
SWIGINTERN char const *OGRLayerShadow_GetName(OGRLayerShadow *self){
    return OGR_FD_GetName(OGR_L_GetLayerDefn(self));
  }
SWIGINTERN char const *OGRLayerShadow_GetGeometryColumn(OGRLayerShadow *self){
    return OGR_L_GetGeometryColumn(self);
  }
SWIGINTERN char const *OGRLayerShadow_GetFIDColumn(OGRLayerShadow *self){
    return OGR_L_GetFIDColumn(self);
  }
SWIGINTERN OGRFeatureShadow *OGRLayerShadow_GetFeature(OGRLayerShadow *self,long fid){
    return (OGRFeatureShadow*) OGR_L_GetFeature(self, fid);
  }
SWIGINTERN OGRFeatureShadow *OGRLayerShadow_GetNextFeature(OGRLayerShadow *self){
    return (OGRFeatureShadow*) OGR_L_GetNextFeature(self);
  }
SWIGINTERN OGRErr OGRLayerShadow_SetNextByIndex(OGRLayerShadow *self,long new_index){
    return OGR_L_SetNextByIndex(self, new_index);
  }
SWIGINTERN OGRErr OGRLayerShadow_SetFeature(OGRLayerShadow *self,OGRFeatureShadow *feature){
    return OGR_L_SetFeature(self, feature);
  }
SWIGINTERN OGRErr OGRLayerShadow_CreateFeature(OGRLayerShadow *self,OGRFeatureShadow *feature){
    return OGR_L_CreateFeature(self, feature);
  }
SWIGINTERN OGRErr OGRLayerShadow_DeleteFeature(OGRLayerShadow *self,long fid){
    return OGR_L_DeleteFeature(self, fid);
  }
SWIGINTERN OGRErr OGRLayerShadow_SyncToDisk(OGRLayerShadow *self){
    return OGR_L_SyncToDisk(self);
  }
SWIGINTERN OGRFeatureDefnShadow *OGRLayerShadow_GetLayerDefn(OGRLayerShadow *self){
    return (OGRFeatureDefnShadow*) OGR_L_GetLayerDefn(self);
  }
SWIGINTERN int OGRLayerShadow_GetFeatureCount(OGRLayerShadow *self,int force=1){
    return OGR_L_GetFeatureCount(self, force);
  }
SWIGINTERN OGRErr OGRLayerShadow_GetExtent(OGRLayerShadow *self,OGREnvelope *extent,int force=1){
    return OGR_L_GetExtent(self, extent, force);
  }
SWIGINTERN bool OGRLayerShadow_TestCapability(OGRLayerShadow *self,char const *cap){
    return (OGR_L_TestCapability(self, cap) > 0);
  }
SWIGINTERN OGRErr OGRLayerShadow_CreateField(OGRLayerShadow *self,OGRFieldDefnShadow *field_def,int approx_ok=1){
    return OGR_L_CreateField(self, field_def, approx_ok);
  }
SWIGINTERN OGRErr OGRLayerShadow_StartTransaction(OGRLayerShadow *self){
    return OGR_L_StartTransaction(self);
  }
SWIGINTERN OGRErr OGRLayerShadow_CommitTransaction(OGRLayerShadow *self){
    return OGR_L_CommitTransaction(self);
  }
SWIGINTERN OGRErr OGRLayerShadow_RollbackTransaction(OGRLayerShadow *self){
    return OGR_L_RollbackTransaction(self);
  }
SWIGINTERN OSRSpatialReferenceShadow *OGRLayerShadow_GetSpatialRef(OGRLayerShadow *self){
    OGRSpatialReferenceH ref =  OGR_L_GetSpatialRef(self);
    if( ref )
        OSRReference(ref);
    return (OSRSpatialReferenceShadow*) ref;
  }
SWIGINTERN GIntBig OGRLayerShadow_GetFeaturesRead(OGRLayerShadow *self){
    return OGR_L_GetFeaturesRead(self);
  }
SWIGINTERN void delete_OGRFeatureShadow(OGRFeatureShadow *self){
    OGR_F_Destroy(self);
  }
SWIGINTERN OGRFeatureShadow *new_OGRFeatureShadow(OGRFeatureDefnShadow *feature_def){
      return (OGRFeatureShadow*) OGR_F_Create( feature_def );
  }
SWIGINTERN OGRFeatureDefnShadow *OGRFeatureShadow_GetDefnRef(OGRFeatureShadow *self){
    return (OGRFeatureDefnShadow*) OGR_F_GetDefnRef(self);
  }
SWIGINTERN OGRErr OGRFeatureShadow_SetGeometry(OGRFeatureShadow *self,OGRGeometryShadow *geom){
    return OGR_F_SetGeometry(self, geom);
  }
SWIGINTERN OGRErr OGRFeatureShadow_SetGeometryDirectly(OGRFeatureShadow *self,OGRGeometryShadow *geom){
    return OGR_F_SetGeometryDirectly(self, geom);
  }
SWIGINTERN OGRGeometryShadow *OGRFeatureShadow_GetGeometryRef(OGRFeatureShadow *self){
    return (OGRGeometryShadow*) OGR_F_GetGeometryRef(self);
  }
SWIGINTERN OGRFeatureShadow *OGRFeatureShadow_Clone(OGRFeatureShadow *self){
    return (OGRFeatureShadow*) OGR_F_Clone(self);
  }
SWIGINTERN bool OGRFeatureShadow_Equal(OGRFeatureShadow *self,OGRFeatureShadow *feature){
    return (OGR_F_Equal(self, feature) > 0);
  }
SWIGINTERN int OGRFeatureShadow_GetFieldCount(OGRFeatureShadow *self){
    return OGR_F_GetFieldCount(self);
  }
SWIGINTERN OGRFieldDefnShadow *OGRFeatureShadow_GetFieldDefnRef__SWIG_0(OGRFeatureShadow *self,int id){
    return (OGRFieldDefnShadow *) OGR_F_GetFieldDefnRef(self, id);
  }
SWIGINTERN OGRFieldDefnShadow *OGRFeatureShadow_GetFieldDefnRef__SWIG_1(OGRFeatureShadow *self,char const *name){
      int i = OGR_F_GetFieldIndex(self, name);
      if (i == -1)
	  CPLError(CE_Failure, 1, "No such field: '%s'", name);
      else
	  return (OGRFieldDefnShadow *) OGR_F_GetFieldDefnRef(self, i);
      return NULL;
  }
SWIGINTERN char const *OGRFeatureShadow_GetFieldAsString__SWIG_0(OGRFeatureShadow *self,int id){
    return (const char *) OGR_F_GetFieldAsString(self, id);
  }
SWIGINTERN char const *OGRFeatureShadow_GetFieldAsString__SWIG_1(OGRFeatureShadow *self,char const *name){
      int i = OGR_F_GetFieldIndex(self, name);
      if (i == -1)
	  CPLError(CE_Failure, 1, "No such field: '%s'", name);
      else
	  return (const char *) OGR_F_GetFieldAsString(self, i);
      return NULL;
  }
SWIGINTERN int OGRFeatureShadow_GetFieldAsInteger__SWIG_0(OGRFeatureShadow *self,int id){
    return OGR_F_GetFieldAsInteger(self, id);
  }
SWIGINTERN int OGRFeatureShadow_GetFieldAsInteger__SWIG_1(OGRFeatureShadow *self,char const *name){
      int i = OGR_F_GetFieldIndex(self, name);
      if (i == -1)
	  CPLError(CE_Failure, 1, "No such field: '%s'", name);
      else
	  return OGR_F_GetFieldAsInteger(self, i);
      return 0;
  }
SWIGINTERN double OGRFeatureShadow_GetFieldAsDouble__SWIG_0(OGRFeatureShadow *self,int id){
    return OGR_F_GetFieldAsDouble(self, id);
  }
SWIGINTERN double OGRFeatureShadow_GetFieldAsDouble__SWIG_1(OGRFeatureShadow *self,char const *name){
      int i = OGR_F_GetFieldIndex(self, name);
      if (i == -1)
	  CPLError(CE_Failure, 1, "No such field: '%s'", name);
      else
	  return OGR_F_GetFieldAsDouble(self, i);
      return 0;
  }
SWIGINTERN void OGRFeatureShadow_GetFieldAsDateTime(OGRFeatureShadow *self,int id,int *pnYear,int *pnMonth,int *pnDay,int *pnHour,int *pnMinute,int *pnSecond,int *pnTZFlag){
      OGR_F_GetFieldAsDateTime(self, id, pnYear, pnMonth, pnDay,
			       pnHour, pnMinute, pnSecond,
			       pnTZFlag);
  }
SWIGINTERN int const *OGRFeatureShadow_GetFieldAsIntegerList(OGRFeatureShadow *self,int id,int *count){
      return OGR_F_GetFieldAsIntegerList(self, id, count);
  }
SWIGINTERN double const *OGRFeatureShadow_GetFieldAsDoubleList(OGRFeatureShadow *self,int id,int *count){
      return OGR_F_GetFieldAsDoubleList(self, id, count);
  }
SWIGINTERN char **OGRFeatureShadow_GetFieldAsStringList(OGRFeatureShadow *self,int id){
      return OGR_F_GetFieldAsStringList(self, id);
  }
SWIGINTERN bool OGRFeatureShadow_IsFieldSet__SWIG_0(OGRFeatureShadow *self,int id){
    return (OGR_F_IsFieldSet(self, id) > 0);
  }
SWIGINTERN bool OGRFeatureShadow_IsFieldSet__SWIG_1(OGRFeatureShadow *self,char const *name){
      int i = OGR_F_GetFieldIndex(self, name);
      if (i == -1)
	  CPLError(CE_Failure, 1, "No such field: '%s'", name);
      else
	  return (OGR_F_IsFieldSet(self, i) > 0);
      return false;
  }
SWIGINTERN int OGRFeatureShadow_GetFieldIndex(OGRFeatureShadow *self,char const *name){
      return OGR_F_GetFieldIndex(self, name);
  }
SWIGINTERN int OGRFeatureShadow_GetFID(OGRFeatureShadow *self){
    return OGR_F_GetFID(self);
  }
SWIGINTERN OGRErr OGRFeatureShadow_SetFID(OGRFeatureShadow *self,int fid){
    return OGR_F_SetFID(self, fid);
  }
SWIGINTERN void OGRFeatureShadow_DumpReadable(OGRFeatureShadow *self){
    OGR_F_DumpReadable(self, NULL);
  }
SWIGINTERN void OGRFeatureShadow_UnsetField__SWIG_0(OGRFeatureShadow *self,int id){
    OGR_F_UnsetField(self, id);
  }
SWIGINTERN void OGRFeatureShadow_UnsetField__SWIG_1(OGRFeatureShadow *self,char const *name){
      int i = OGR_F_GetFieldIndex(self, name);
      if (i == -1)
	  CPLError(CE_Failure, 1, "No such field: '%s'", name);
      else
	  OGR_F_UnsetField(self, i);
  }
SWIGINTERN void OGRFeatureShadow_SetField__SWIG_0(OGRFeatureShadow *self,int id,char const *value){
    OGR_F_SetFieldString(self, id, value);
  }
SWIGINTERN void OGRFeatureShadow_SetField__SWIG_1(OGRFeatureShadow *self,char const *name,char const *value){
      int i = OGR_F_GetFieldIndex(self, name);
      if (i == -1)
	  CPLError(CE_Failure, 1, "No such field: '%s'", name);
      else
	  OGR_F_SetFieldString(self, i, value);
  }
SWIGINTERN void OGRFeatureShadow_SetField__SWIG_2(OGRFeatureShadow *self,int id,int value){
    OGR_F_SetFieldInteger(self, id, value);
  }
SWIGINTERN void OGRFeatureShadow_SetField__SWIG_3(OGRFeatureShadow *self,char const *name,int value){
      int i = OGR_F_GetFieldIndex(self, name);
      if (i == -1)
	  CPLError(CE_Failure, 1, "No such field: '%s'", name);
      else
	  OGR_F_SetFieldInteger(self, i, value);
  }
SWIGINTERN void OGRFeatureShadow_SetField__SWIG_4(OGRFeatureShadow *self,int id,double value){
    OGR_F_SetFieldDouble(self, id, value);
  }
SWIGINTERN void OGRFeatureShadow_SetField__SWIG_5(OGRFeatureShadow *self,char const *name,double value){
      int i = OGR_F_GetFieldIndex(self, name);
      if (i == -1)
	  CPLError(CE_Failure, 1, "No such field: '%s'", name);
      else
	  OGR_F_SetFieldDouble(self, i, value);
  }
SWIGINTERN void OGRFeatureShadow_SetField__SWIG_6(OGRFeatureShadow *self,int id,int year,int month,int day,int hour,int minute,int second,int tzflag){
    OGR_F_SetFieldDateTime(self, id, year, month, day,
                             hour, minute, second, 
                             tzflag);
  }
SWIGINTERN void OGRFeatureShadow_SetField__SWIG_7(OGRFeatureShadow *self,char const *name,int year,int month,int day,int hour,int minute,int second,int tzflag){
      int i = OGR_F_GetFieldIndex(self, name);
      if (i == -1)
	  CPLError(CE_Failure, 1, "No such field: '%s'", name);
      else
	  OGR_F_SetFieldDateTime(self, i, year, month, day,
				 hour, minute, second, 
				 tzflag);
  }
SWIGINTERN void OGRFeatureShadow_SetFieldIntegerList(OGRFeatureShadow *self,int id,int nList,int *pList){
      OGR_F_SetFieldIntegerList(self, id, nList, pList);
  }
SWIGINTERN void OGRFeatureShadow_SetFieldDoubleList(OGRFeatureShadow *self,int id,int nList,double *pList){
      OGR_F_SetFieldDoubleList(self, id, nList, pList);
  }
SWIGINTERN void OGRFeatureShadow_SetFieldStringList(OGRFeatureShadow *self,int id,char **pList){
      OGR_F_SetFieldStringList(self, id, pList);
  }
SWIGINTERN OGRErr OGRFeatureShadow_SetFrom(OGRFeatureShadow *self,OGRFeatureShadow *other,int forgiving=1){
    return OGR_F_SetFrom(self, other, forgiving);
  }
SWIGINTERN char const *OGRFeatureShadow_GetStyleString(OGRFeatureShadow *self){
    return (const char*) OGR_F_GetStyleString(self);
  }
SWIGINTERN void OGRFeatureShadow_SetStyleString(OGRFeatureShadow *self,char const *the_string){
    OGR_F_SetStyleString(self, the_string);
  }
SWIGINTERN OGRFieldType OGRFeatureShadow_GetFieldType__SWIG_0(OGRFeatureShadow *self,int id){
    return (OGRFieldType) OGR_Fld_GetType( OGR_F_GetFieldDefnRef( self, id));
  }
SWIGINTERN OGRFieldType OGRFeatureShadow_GetFieldType__SWIG_1(OGRFeatureShadow *self,char const *name){
      int i = OGR_F_GetFieldIndex(self, name);
      if (i == -1) {
	  CPLError(CE_Failure, 1, "No such field: '%s'", name);
	  return (OGRFieldType)0;
      } else
	  return (OGRFieldType) OGR_Fld_GetType( 
	      OGR_F_GetFieldDefnRef( self,  i )
	      );
  }
SWIGINTERN void delete_OGRFeatureDefnShadow(OGRFeatureDefnShadow *self){
    /*OGR_FD_Destroy(self);*/
    OGR_FD_Release( OGRFeatureDefnH(self) );
  }
SWIGINTERN OGRFeatureDefnShadow *new_OGRFeatureDefnShadow(char const *name_null_ok=NULL){
    OGRFeatureDefnH h = OGR_FD_Create(name_null_ok);
    OGR_FD_Reference(h);
    return (OGRFeatureDefnShadow* )h;
  }
SWIGINTERN char const *OGRFeatureDefnShadow_GetName(OGRFeatureDefnShadow *self){
    return OGR_FD_GetName(self);
  }
SWIGINTERN int OGRFeatureDefnShadow_GetFieldCount(OGRFeatureDefnShadow *self){
    return OGR_FD_GetFieldCount(self);
  }
SWIGINTERN OGRFieldDefnShadow *OGRFeatureDefnShadow_GetFieldDefn(OGRFeatureDefnShadow *self,int i){
    return (OGRFieldDefnShadow*) OGR_FD_GetFieldDefn(self, i);
  }
SWIGINTERN int OGRFeatureDefnShadow_GetFieldIndex(OGRFeatureDefnShadow *self,char const *name){
      return OGR_FD_GetFieldIndex(self, name);
  }
SWIGINTERN void OGRFeatureDefnShadow_AddFieldDefn(OGRFeatureDefnShadow *self,OGRFieldDefnShadow *defn){
    OGR_FD_AddFieldDefn(self, defn);
  }
SWIGINTERN OGRwkbGeometryType OGRFeatureDefnShadow_GetGeomType(OGRFeatureDefnShadow *self){
    return (OGRwkbGeometryType) OGR_FD_GetGeomType(self);
  }
SWIGINTERN void OGRFeatureDefnShadow_SetGeomType(OGRFeatureDefnShadow *self,OGRwkbGeometryType geom_type){
    OGR_FD_SetGeomType(self, geom_type);
  }
SWIGINTERN int OGRFeatureDefnShadow_GetReferenceCount(OGRFeatureDefnShadow *self){
    return OGR_FD_GetReferenceCount(self);
  }

    static int ValidateOGRFieldType(OGRFieldType field_type)
    {
        switch(field_type)
        {
            case OFTInteger:
            case OFTIntegerList:
            case OFTReal:
            case OFTRealList:
            case OFTString:
            case OFTStringList:
            case OFTBinary:
            case OFTDate:
            case OFTTime:
            case OFTDateTime:
                return TRUE;
            default:
                CPLError(CE_Failure, CPLE_IllegalArg, "Illegal field type value");
                return FALSE;
        }
    }

SWIGINTERN void delete_OGRFieldDefnShadow(OGRFieldDefnShadow *self){
    OGR_Fld_Destroy(self);
  }
SWIGINTERN OGRFieldDefnShadow *new_OGRFieldDefnShadow(char const *name_null_ok="unnamed",OGRFieldType field_type=OFTString){
    if (ValidateOGRFieldType(field_type))
        return (OGRFieldDefnShadow*) OGR_Fld_Create(name_null_ok, field_type);
    else
        return NULL;
  }
SWIGINTERN char const *OGRFieldDefnShadow_GetName(OGRFieldDefnShadow *self){
    return (const char *) OGR_Fld_GetNameRef(self);
  }
SWIGINTERN char const *OGRFieldDefnShadow_GetNameRef(OGRFieldDefnShadow *self){
    return (const char *) OGR_Fld_GetNameRef(self);
  }
SWIGINTERN void OGRFieldDefnShadow_SetName(OGRFieldDefnShadow *self,char const *name){
    OGR_Fld_SetName(self, name);
  }
SWIGINTERN OGRFieldType OGRFieldDefnShadow_GetType(OGRFieldDefnShadow *self){
    return OGR_Fld_GetType(self);
  }
SWIGINTERN void OGRFieldDefnShadow_SetType(OGRFieldDefnShadow *self,OGRFieldType type){
    if (ValidateOGRFieldType(type))
        OGR_Fld_SetType(self, type);
  }
SWIGINTERN OGRJustification OGRFieldDefnShadow_GetJustify(OGRFieldDefnShadow *self){
    return OGR_Fld_GetJustify(self);
  }
SWIGINTERN void OGRFieldDefnShadow_SetJustify(OGRFieldDefnShadow *self,OGRJustification justify){
    OGR_Fld_SetJustify(self, justify);
  }
SWIGINTERN int OGRFieldDefnShadow_GetWidth(OGRFieldDefnShadow *self){
    return OGR_Fld_GetWidth(self);
  }
SWIGINTERN void OGRFieldDefnShadow_SetWidth(OGRFieldDefnShadow *self,int width){
    OGR_Fld_SetWidth(self, width);
  }
SWIGINTERN int OGRFieldDefnShadow_GetPrecision(OGRFieldDefnShadow *self){
    return OGR_Fld_GetPrecision(self);
  }
SWIGINTERN void OGRFieldDefnShadow_SetPrecision(OGRFieldDefnShadow *self,int precision){
    OGR_Fld_SetPrecision(self, precision);
  }
SWIGINTERN char const *OGRFieldDefnShadow_GetTypeName(OGRFieldDefnShadow *self){
      return OGR_GetFieldTypeName(OGR_Fld_GetType(self));
  }
SWIGINTERN char const *OGRFieldDefnShadow_GetFieldTypeName(OGRFieldDefnShadow *self,OGRFieldType type){
    return OGR_GetFieldTypeName(type);
  }

  OGRGeometryShadow* CreateGeometryFromWkb( int len, char *bin_string, 
                                            OSRSpatialReferenceShadow *reference=NULL ) {
    OGRGeometryShadow *geom;
    OGRErr err = OGR_G_CreateFromWkb( (unsigned char *) bin_string,
                                      reference,
                                      &geom,
                                      len );
    if (err != 0 ) {
       CPLError(CE_Failure, err, "%s", OGRErrMessages(err));
       return NULL;
    }
    return (OGRGeometryShadow*) geom;
  }
 


  OGRGeometryShadow* CreateGeometryFromWkt( char **val, 
                                      OSRSpatialReferenceShadow *reference=NULL ) {
    OGRGeometryShadow *geom;
    OGRErr err = OGR_G_CreateFromWkt(val,
                                      reference,
                                      &geom);
    if (err != 0 ) {
       CPLError(CE_Failure, err, "%s", OGRErrMessages(err));
       return NULL;
    }
    return (OGRGeometryShadow*) geom;
  }
 


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


  OGRGeometryShadow *CreateGeometryFromJson( const char * input_string ) {
    OGRGeometryShadow* geom = (OGRGeometryShadow*)OGR_G_CreateGeometryFromJson(input_string);
    return geom;
  }
 


  OGRGeometryShadow* BuildPolygonFromEdges( OGRGeometryShadow*  hLineCollection,  
                                            int bBestEffort = 0, 
                                            int bAutoClose = 0, 
                                            double dfTolerance=0) {
  
  OGRGeometryH hPolygon = NULL;
  
  OGRErr eErr;

  hPolygon = OGRBuildPolygonFromEdges( hLineCollection, bBestEffort, 
                                       bAutoClose, dfTolerance, &eErr );

  if (eErr != OGRERR_NONE ) {
    CPLError(CE_Failure, eErr, "%s", OGRErrMessages(eErr));
    return NULL;
  }

  return hPolygon;
  }


  OGRGeometryShadow* ApproximateArcAngles( 
        double dfCenterX, double dfCenterY, double dfZ,
  	double dfPrimaryRadius, double dfSecondaryAxis, double dfRotation, 
        double dfStartAngle, double dfEndAngle,
        double dfMaxAngleStepSizeDegrees ) {
  
  return OGR_G_ApproximateArcAngles( 
             dfCenterX, dfCenterY, dfZ, 
             dfPrimaryRadius, dfSecondaryAxis, dfRotation,
             dfStartAngle, dfEndAngle, dfMaxAngleStepSizeDegrees );
  }

SWIGINTERN void delete_OGRGeometryShadow(OGRGeometryShadow *self){
    OGR_G_DestroyGeometry( self );
  }
SWIGINTERN 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 {
        CPLError(CE_Failure, 1, "Empty geometries cannot be constructed");
        return NULL;}

  }
SWIGINTERN OGRErr OGRGeometryShadow_ExportToWkt(OGRGeometryShadow *self,char **argout){
    return OGR_G_ExportToWkt(self, argout);
  }
SWIGINTERN retStringAndCPLFree *OGRGeometryShadow_ExportToGML(OGRGeometryShadow *self){
    return (retStringAndCPLFree*) OGR_G_ExportToGML(self);
  }
SWIGINTERN retStringAndCPLFree *OGRGeometryShadow_ExportToKML(OGRGeometryShadow *self,char const *altitude_mode=NULL){
    return (retStringAndCPLFree *) OGR_G_ExportToKML(self, altitude_mode);
  }
SWIGINTERN retStringAndCPLFree *OGRGeometryShadow_ExportToJson(OGRGeometryShadow *self){
    return (retStringAndCPLFree *) OGR_G_ExportToJson(self);
  }
SWIGINTERN void OGRGeometryShadow_AddPoint(OGRGeometryShadow *self,double x,double y,double z=0){
    OGR_G_AddPoint( self, x, y, z );
  }
SWIGINTERN void OGRGeometryShadow_AddPoint_2D(OGRGeometryShadow *self,double x,double y){
    OGR_G_AddPoint_2D( self, x, y );
  }
SWIGINTERN OGRErr OGRGeometryShadow_AddGeometryDirectly(OGRGeometryShadow *self,OGRGeometryShadow *other_disown){
    return OGR_G_AddGeometryDirectly( self, other_disown );
  }
SWIGINTERN OGRErr OGRGeometryShadow_AddGeometry(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_AddGeometry( self, other );
  }
SWIGINTERN OGRGeometryShadow *OGRGeometryShadow_Clone(OGRGeometryShadow *self){
    return (OGRGeometryShadow*) OGR_G_Clone(self);
  }
SWIGINTERN OGRwkbGeometryType OGRGeometryShadow_GetGeometryType(OGRGeometryShadow *self){
    return (OGRwkbGeometryType) OGR_G_GetGeometryType(self);
  }
SWIGINTERN char const *OGRGeometryShadow_GetGeometryName(OGRGeometryShadow *self){
    return (const char *) OGR_G_GetGeometryName(self);
  }
SWIGINTERN double OGRGeometryShadow_GetArea(OGRGeometryShadow *self){
    return OGR_G_GetArea(self);
  }
SWIGINTERN int OGRGeometryShadow_GetPointCount(OGRGeometryShadow *self){
    return OGR_G_GetPointCount(self);
  }
SWIGINTERN double OGRGeometryShadow_GetX(OGRGeometryShadow *self,int point=0){
    return OGR_G_GetX(self, point);
  }
SWIGINTERN double OGRGeometryShadow_GetY(OGRGeometryShadow *self,int point=0){
    return OGR_G_GetY(self, point);
  }
SWIGINTERN double OGRGeometryShadow_GetZ(OGRGeometryShadow *self,int point=0){
    return OGR_G_GetZ(self, point);
  }
SWIGINTERN void OGRGeometryShadow_GetPoint(OGRGeometryShadow *self,int iPoint=0,double argout[3]=NULL){

    OGR_G_GetPoint( self, iPoint, argout+0, argout+1, argout+2 );
  }
SWIGINTERN void OGRGeometryShadow_GetPoint_2D(OGRGeometryShadow *self,int iPoint=0,double argout[2]=NULL){

    OGR_G_GetPoint( self, iPoint, argout+0, argout+1, NULL );
  }
SWIGINTERN int OGRGeometryShadow_GetGeometryCount(OGRGeometryShadow *self){
    return OGR_G_GetGeometryCount(self);
  }
SWIGINTERN void OGRGeometryShadow_SetPoint(OGRGeometryShadow *self,int point,double x,double y,double z=0){
    OGR_G_SetPoint(self, point, x, y, z);
  }
SWIGINTERN void OGRGeometryShadow_SetPoint_2D(OGRGeometryShadow *self,int point,double x,double y){
    OGR_G_SetPoint_2D(self, point, x, y);
  }
SWIGINTERN OGRGeometryShadow *OGRGeometryShadow_GetGeometryRef(OGRGeometryShadow *self,int geom){
    return (OGRGeometryShadow*) OGR_G_GetGeometryRef(self, geom);
  }
SWIGINTERN OGRGeometryShadow *OGRGeometryShadow_GetBoundary(OGRGeometryShadow *self){
    return (OGRGeometryShadow*) OGR_G_GetBoundary(self);
  }
SWIGINTERN OGRGeometryShadow *OGRGeometryShadow_ConvexHull(OGRGeometryShadow *self){
    return (OGRGeometryShadow*) OGR_G_ConvexHull(self);
  }
SWIGINTERN OGRGeometryShadow *OGRGeometryShadow_Buffer(OGRGeometryShadow *self,double distance,int quadsecs=30){
    return (OGRGeometryShadow*) OGR_G_Buffer( self, distance, quadsecs );
  }
SWIGINTERN OGRGeometryShadow *OGRGeometryShadow_Intersection(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGRGeometryShadow*) OGR_G_Intersection( self, other );
  }
SWIGINTERN OGRGeometryShadow *OGRGeometryShadow_Union(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGRGeometryShadow*) OGR_G_Union( self, other );
  }
SWIGINTERN OGRGeometryShadow *OGRGeometryShadow_Difference(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGRGeometryShadow*) OGR_G_Difference( self, other );
  }
SWIGINTERN OGRGeometryShadow *OGRGeometryShadow_SymmetricDifference(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGRGeometryShadow*) OGR_G_SymmetricDifference( self, other );
  }
SWIGINTERN double OGRGeometryShadow_Distance(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return OGR_G_Distance(self, other);
  }
SWIGINTERN void OGRGeometryShadow_Empty(OGRGeometryShadow *self){
    OGR_G_Empty(self);
  }
SWIGINTERN bool OGRGeometryShadow_IsEmpty(OGRGeometryShadow *self){
    return (OGR_G_IsEmpty(self) > 0);
  }
SWIGINTERN bool OGRGeometryShadow_IsValid(OGRGeometryShadow *self){
    return (OGR_G_IsValid(self) > 0);
  }
SWIGINTERN bool OGRGeometryShadow_IsSimple(OGRGeometryShadow *self){
    return (OGR_G_IsSimple(self) > 0);
  }
SWIGINTERN bool OGRGeometryShadow_IsRing(OGRGeometryShadow *self){
    return (OGR_G_IsRing(self) > 0);
  }
SWIGINTERN bool OGRGeometryShadow_Intersect(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGR_G_Intersect(self, other) > 0);
  }
SWIGINTERN bool OGRGeometryShadow_Equal(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGR_G_Equal(self, other) > 0);
  }
SWIGINTERN bool OGRGeometryShadow_Disjoint(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGR_G_Disjoint(self, other) > 0);
  }
SWIGINTERN bool OGRGeometryShadow_Touches(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGR_G_Touches(self, other) > 0);
  }
SWIGINTERN bool OGRGeometryShadow_Crosses(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGR_G_Crosses(self, other) > 0);
  }
SWIGINTERN bool OGRGeometryShadow_Within(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGR_G_Within(self, other) > 0);
  }
SWIGINTERN bool OGRGeometryShadow_Contains(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGR_G_Contains(self, other) > 0);
  }
SWIGINTERN bool OGRGeometryShadow_Overlaps(OGRGeometryShadow *self,OGRGeometryShadow *other){
    return (OGR_G_Overlaps(self, other) > 0);
  }
SWIGINTERN OGRErr OGRGeometryShadow_TransformTo(OGRGeometryShadow *self,OSRSpatialReferenceShadow *reference){
    return OGR_G_TransformTo(self, reference);
  }
SWIGINTERN OGRErr OGRGeometryShadow_Transform(OGRGeometryShadow *self,OSRCoordinateTransformationShadow *trans){
    return OGR_G_Transform(self, trans);
  }
SWIGINTERN OSRSpatialReferenceShadow *OGRGeometryShadow_GetSpatialReference(OGRGeometryShadow *self){
    OGRSpatialReferenceH ref =  OGR_G_GetSpatialReference(self);
    if( ref )
        OSRReference(ref);
    return (OSRSpatialReferenceShadow*) ref;
  }
SWIGINTERN void OGRGeometryShadow_AssignSpatialReference(OGRGeometryShadow *self,OSRSpatialReferenceShadow *reference){
    OGR_G_AssignSpatialReference(self, reference);
  }
SWIGINTERN void OGRGeometryShadow_CloseRings(OGRGeometryShadow *self){
    OGR_G_CloseRings(self);
  }
SWIGINTERN void OGRGeometryShadow_FlattenTo2D(OGRGeometryShadow *self){
    OGR_G_FlattenTo2D(self);
  }
SWIGINTERN void OGRGeometryShadow_Segmentize(OGRGeometryShadow *self,double dfMaxLength){
    OGR_G_Segmentize(self, dfMaxLength);
  }
SWIGINTERN void OGRGeometryShadow_GetEnvelope(OGRGeometryShadow *self,OGREnvelope *env){
    OGR_G_GetEnvelope(self, env);
  }
SWIGINTERN OGRGeometryShadow *OGRGeometryShadow_Centroid(OGRGeometryShadow *self){
    OGRGeometryShadow *pt = (OGRGeometryShadow*) OGR_G_CreateGeometry( wkbPoint );
    OGR_G_Centroid( self, pt );
    return pt;
  }
SWIGINTERN int OGRGeometryShadow_WkbSize(OGRGeometryShadow *self){
    return OGR_G_WkbSize(self);
  }
SWIGINTERN int OGRGeometryShadow_GetCoordinateDimension(OGRGeometryShadow *self){
    return OGR_G_GetCoordinateDimension(self);
  }
SWIGINTERN void OGRGeometryShadow_SetCoordinateDimension(OGRGeometryShadow *self,int dimension){
    OGR_G_SetCoordinateDimension(self, dimension);
  }
SWIGINTERN int OGRGeometryShadow_GetDimension(OGRGeometryShadow *self){
    return OGR_G_GetDimension(self);
  }
SWIGINTERN OGRErr OGRGeometryShadow_ExportToWkb(OGRGeometryShadow *self,int bufLen,char *buffer,OGRwkbByteOrder byte_order){
      if (bufLen < OGR_G_WkbSize( self ))
        CPLError(CE_Failure, 1, "Array size is small (ExportToWkb).");
      return OGR_G_ExportToWkb(self, byte_order, (unsigned char*) buffer );
    }

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


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


  OGRDataSourceShadow* Open( const char *filename, int update =0 ) {
    CPLErrorReset();
    OGRDataSourceShadow* ds = (OGRDataSourceShadow*)OGROpen(filename,update,NULL);
    if( CPLGetLastErrorType() == CE_Failure && ds != NULL )
    {
        CPLDebug( "SWIG", 
		  "OGROpen() succeeded, but an error is posted, so we destroy"
		  " the datasource and fail at swig level." );
        OGRReleaseDataSource(ds);
        ds = NULL;
    }
	
    return ds;
  }


  OGRDataSourceShadow* OpenShared( const char *filename, int update =0 ) {
    CPLErrorReset();
    OGRDataSourceShadow* ds = (OGRDataSourceShadow*)OGROpenShared(filename,update,NULL);
    if( CPLGetLastErrorType() == CE_Failure && ds != NULL )
    {
        OGRReleaseDataSource(ds);
        ds = NULL;
    }
	
    return ds;
  }


OGRDriverShadow* GetDriverByName( char const *name ) {
  return (OGRDriverShadow*) OGRGetDriverByName( name );
}

OGRDriverShadow* GetDriver(int driver_number) {
  return (OGRDriverShadow*) OGRGetDriver(driver_number);
}


  char **GeneralCmdLineProcessor( char **papszArgv, int nOptions = 0 ) {
    int nResArgCount;

    nResArgCount = 
      OGRGeneralCmdLineProcessor( CSLCount(papszArgv), &papszArgv, nOptions ); 

    if( nResArgCount <= 0 )
        return NULL;
    else
        return papszArgv;
  }


#ifdef __cplusplus
extern "C" {
#endif

SWIGEXPORT int SWIGSTDCALL CSharp_wkb25DBit_get() {
  int jresult ;
  int result;
  
  result = (int) 0x80000000;
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_ogrZMarker_get() {
  int jresult ;
  int result;
  
  result = (int) 0x21125711;
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_OGRNullFID_get() {
  int jresult ;
  int result;
  
  result = (int) -1;
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_OGRUnsetMarker_get() {
  int jresult ;
  int result;
  
  result = (int) -21121;
  jresult = result; 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_OLCRandomRead_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "RandomRead";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_OLCSequentialWrite_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "SequentialWrite";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_OLCRandomWrite_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "RandomWrite";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_OLCFastSpatialFilter_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "FastSpatialFilter";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_OLCFastFeatureCount_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "FastFeatureCount";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_OLCFastGetExtent_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "FastGetExtent";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_OLCCreateField_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "CreateField";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_OLCTransactions_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "Transactions";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_OLCDeleteFeature_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "DeleteFeature";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_OLCFastSetNextByIndex_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "FastSetNextByIndex";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_OLCStringsAsUTF8_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "StringsAsUTF8";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_ODsCCreateLayer_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "CreateLayer";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_ODsCDeleteLayer_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "DeleteLayer";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_ODrCCreateDataSource_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "CreateDataSource";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_ODrCDeleteDataSource_get() {
  char * jresult ;
  char *result = 0 ;
  
  result = (char *) "DeleteDataSource";
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_OGRERR_NONE_get() {
  int jresult ;
  int result;
  
  result = (int) 0;
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_OGRERR_NOT_ENOUGH_DATA_get() {
  int jresult ;
  int result;
  
  result = (int) 1;
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_OGRERR_NOT_ENOUGH_MEMORY_get() {
  int jresult ;
  int result;
  
  result = (int) 2;
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_OGRERR_UNSUPPORTED_GEOMETRY_TYPE_get() {
  int jresult ;
  int result;
  
  result = (int) 3;
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_OGRERR_UNSUPPORTED_OPERATION_get() {
  int jresult ;
  int result;
  
  result = (int) 4;
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_OGRERR_CORRUPT_DATA_get() {
  int jresult ;
  int result;
  
  result = (int) 5;
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_OGRERR_FAILURE_get() {
  int jresult ;
  int result;
  
  result = (int) 6;
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_OGRERR_UNSUPPORTED_SRS_get() {
  int jresult ;
  int result;
  
  result = (int) 7;
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_UseExceptions() {
  UseExceptions();
}


SWIGEXPORT void SWIGSTDCALL CSharp_DontUseExceptions() {
  DontUseExceptions();
}


SWIGEXPORT void SWIGSTDCALL CSharp_StringListDestroy(void * jarg1) {
  void *arg1 = (void *) 0 ;
  
  arg1 = (void *)jarg1; 
  {
    CPLErrorReset();
    StringListDestroy(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Envelope_MinX_set(void * jarg1, double jarg2) {
  OGREnvelope *arg1 = (OGREnvelope *) 0 ;
  double arg2 ;
  
  arg1 = (OGREnvelope *)jarg1; 
  arg2 = (double)jarg2; 
  if (arg1) (arg1)->MinX = arg2;
}


SWIGEXPORT double SWIGSTDCALL CSharp_Envelope_MinX_get(void * jarg1) {
  double jresult ;
  OGREnvelope *arg1 = (OGREnvelope *) 0 ;
  double result;
  
  arg1 = (OGREnvelope *)jarg1; 
  result = (double) ((arg1)->MinX);
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Envelope_MaxX_set(void * jarg1, double jarg2) {
  OGREnvelope *arg1 = (OGREnvelope *) 0 ;
  double arg2 ;
  
  arg1 = (OGREnvelope *)jarg1; 
  arg2 = (double)jarg2; 
  if (arg1) (arg1)->MaxX = arg2;
}


SWIGEXPORT double SWIGSTDCALL CSharp_Envelope_MaxX_get(void * jarg1) {
  double jresult ;
  OGREnvelope *arg1 = (OGREnvelope *) 0 ;
  double result;
  
  arg1 = (OGREnvelope *)jarg1; 
  result = (double) ((arg1)->MaxX);
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Envelope_MinY_set(void * jarg1, double jarg2) {
  OGREnvelope *arg1 = (OGREnvelope *) 0 ;
  double arg2 ;
  
  arg1 = (OGREnvelope *)jarg1; 
  arg2 = (double)jarg2; 
  if (arg1) (arg1)->MinY = arg2;
}


SWIGEXPORT double SWIGSTDCALL CSharp_Envelope_MinY_get(void * jarg1) {
  double jresult ;
  OGREnvelope *arg1 = (OGREnvelope *) 0 ;
  double result;
  
  arg1 = (OGREnvelope *)jarg1; 
  result = (double) ((arg1)->MinY);
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Envelope_MaxY_set(void * jarg1, double jarg2) {
  OGREnvelope *arg1 = (OGREnvelope *) 0 ;
  double arg2 ;
  
  arg1 = (OGREnvelope *)jarg1; 
  arg2 = (double)jarg2; 
  if (arg1) (arg1)->MaxY = arg2;
}


SWIGEXPORT double SWIGSTDCALL CSharp_Envelope_MaxY_get(void * jarg1) {
  double jresult ;
  OGREnvelope *arg1 = (OGREnvelope *) 0 ;
  double result;
  
  arg1 = (OGREnvelope *)jarg1; 
  result = (double) ((arg1)->MaxY);
  jresult = result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_new_Envelope() {
  void * jresult ;
  OGREnvelope *result = 0 ;
  
  {
    CPLErrorReset();
    result = (OGREnvelope *)new OGREnvelope();
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_delete_Envelope(void * jarg1) {
  OGREnvelope *arg1 = (OGREnvelope *) 0 ;
  
  arg1 = (OGREnvelope *)jarg1; 
  {
    CPLErrorReset();
    delete arg1;
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Driver_name_get(void * jarg1) {
  char * jresult ;
  OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRDriverShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRDriverShadow_name_get(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Driver_CreateDataSource(void * jarg1, char * jarg2, void * jarg3) {
  void * jresult ;
  OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  char **arg3 = (char **) 0 ;
  OGRDataSourceShadow *result = 0 ;
  
  arg1 = (OGRDriverShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  arg3 = (char **)jarg3; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRDataSourceShadow *)OGRDriverShadow_CreateDataSource(arg1,(char const *)arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Driver_CopyDataSource(void * jarg1, void * jarg2, char * jarg3, void * jarg4) {
  void * jresult ;
  OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
  OGRDataSourceShadow *arg2 = (OGRDataSourceShadow *) 0 ;
  char *arg3 = (char *) 0 ;
  char **arg4 = (char **) 0 ;
  OGRDataSourceShadow *result = 0 ;
  
  arg1 = (OGRDriverShadow *)jarg1; 
  arg2 = (OGRDataSourceShadow *)jarg2; 
  arg3 = (char *)jarg3; 
  arg4 = (char **)jarg4; 
  {
    if (!arg3) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRDataSourceShadow *)OGRDriverShadow_CopyDataSource(arg1,arg2,(char const *)arg3,arg4);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Driver_Open(void * jarg1, char * jarg2, int jarg3) {
  void * jresult ;
  OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  int arg3 = (int) 0 ;
  OGRDataSourceShadow *result = 0 ;
  
  arg1 = (OGRDriverShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  arg3 = (int)jarg3; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRDataSourceShadow *)OGRDriverShadow_Open(arg1,(char const *)arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Driver_DeleteDataSource(void * jarg1, char * jarg2) {
  int jresult ;
  OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  int result;
  
  arg1 = (OGRDriverShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (int)OGRDriverShadow_DeleteDataSource(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Driver_TestCapability(void * jarg1, char * jarg2) {
  unsigned int jresult ;
  OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  bool result;
  
  arg1 = (OGRDriverShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRDriverShadow_TestCapability(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Driver_GetName(void * jarg1) {
  char * jresult ;
  OGRDriverShadow *arg1 = (OGRDriverShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRDriverShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRDriverShadow_GetName(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_DataSource_name_get(void * jarg1) {
  char * jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRDataSourceShadow_name_get(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_delete_DataSource(void * jarg1) {
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  {
    CPLErrorReset();
    delete_OGRDataSourceShadow(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_DataSource_GetRefCount(void * jarg1) {
  int jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  int result;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRDataSourceShadow_GetRefCount(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_DataSource_GetSummaryRefCount(void * jarg1) {
  int jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  int result;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRDataSourceShadow_GetSummaryRefCount(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_DataSource_GetLayerCount(void * jarg1) {
  int jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  int result;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRDataSourceShadow_GetLayerCount(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_DataSource_GetDriver(void * jarg1) {
  void * jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  OGRDriverShadow *result = 0 ;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRDriverShadow *)OGRDataSourceShadow_GetDriver(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_DataSource_GetName(void * jarg1) {
  char * jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRDataSourceShadow_GetName(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_DataSource_DeleteLayer(void * jarg1, int jarg2) {
  int jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  int arg2 ;
  OGRErr result;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRDataSourceShadow_DeleteLayer(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_DataSource_CreateLayer(void * jarg1, char * jarg2, void * jarg3, int jarg4, void * jarg5) {
  void * jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  OSRSpatialReferenceShadow *arg3 = (OSRSpatialReferenceShadow *) NULL ;
  OGRwkbGeometryType arg4 = (OGRwkbGeometryType) wkbUnknown ;
  char **arg5 = (char **) 0 ;
  OGRLayerShadow *result = 0 ;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  arg3 = (OSRSpatialReferenceShadow *)jarg3; 
  arg4 = (OGRwkbGeometryType)jarg4; 
  arg5 = (char **)jarg5; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRLayerShadow *)OGRDataSourceShadow_CreateLayer(arg1,(char const *)arg2,arg3,arg4,arg5);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_DataSource_CopyLayer(void * jarg1, void * jarg2, char * jarg3, void * jarg4) {
  void * jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  OGRLayerShadow *arg2 = (OGRLayerShadow *) 0 ;
  char *arg3 = (char *) 0 ;
  char **arg4 = (char **) 0 ;
  OGRLayerShadow *result = 0 ;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  arg2 = (OGRLayerShadow *)jarg2; 
  arg3 = (char *)jarg3; 
  arg4 = (char **)jarg4; 
  {
    CPLErrorReset();
    result = (OGRLayerShadow *)OGRDataSourceShadow_CopyLayer(arg1,arg2,(char const *)arg3,arg4);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_DataSource_GetLayerByIndex(void * jarg1, int jarg2) {
  void * jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  int arg2 = (int) 0 ;
  OGRLayerShadow *result = 0 ;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (OGRLayerShadow *)OGRDataSourceShadow_GetLayerByIndex(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_DataSource_GetLayerByName(void * jarg1, char * jarg2) {
  void * jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  OGRLayerShadow *result = 0 ;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    CPLErrorReset();
    result = (OGRLayerShadow *)OGRDataSourceShadow_GetLayerByName(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_DataSource_TestCapability(void * jarg1, char * jarg2) {
  unsigned int jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  bool result;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRDataSourceShadow_TestCapability(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_DataSource_ExecuteSQL(void * jarg1, char * jarg2, void * jarg3, char * jarg4) {
  void * jresult ;
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  OGRGeometryShadow *arg3 = (OGRGeometryShadow *) NULL ;
  char *arg4 = (char *) "" ;
  OGRLayerShadow *result = 0 ;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  arg3 = (OGRGeometryShadow *)jarg3; 
  arg4 = (char *)jarg4; 
  {
    CPLErrorReset();
    result = (OGRLayerShadow *)OGRDataSourceShadow_ExecuteSQL(arg1,(char const *)arg2,arg3,(char const *)arg4);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_DataSource_ReleaseResultSet(void * jarg1, void * jarg2) {
  OGRDataSourceShadow *arg1 = (OGRDataSourceShadow *) 0 ;
  OGRLayerShadow *arg2 = (OGRLayerShadow *) 0 ;
  
  arg1 = (OGRDataSourceShadow *)jarg1; 
  arg2 = (OGRLayerShadow *)jarg2; 
  {
    CPLErrorReset();
    OGRDataSourceShadow_ReleaseResultSet(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_GetRefCount(void * jarg1) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  int result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRLayerShadow_GetRefCount(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Layer_SetSpatialFilter(void * jarg1, void * jarg2) {
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    CPLErrorReset();
    OGRLayerShadow_SetSpatialFilter(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Layer_SetSpatialFilterRect(void * jarg1, double jarg2, double jarg3, double jarg4, double jarg5) {
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  double arg2 ;
  double arg3 ;
  double arg4 ;
  double arg5 ;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (double)jarg2; 
  arg3 = (double)jarg3; 
  arg4 = (double)jarg4; 
  arg5 = (double)jarg5; 
  {
    CPLErrorReset();
    OGRLayerShadow_SetSpatialFilterRect(arg1,arg2,arg3,arg4,arg5);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Layer_GetSpatialFilter(void * jarg1) {
  void * jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRLayerShadow_GetSpatialFilter(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_SetAttributeFilter(void * jarg1, char * jarg2) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  OGRErr result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRLayerShadow_SetAttributeFilter(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Layer_ResetReading(void * jarg1) {
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    OGRLayerShadow_ResetReading(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Layer_GetName(void * jarg1) {
  char * jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRLayerShadow_GetName(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Layer_GetGeometryColumn(void * jarg1) {
  char * jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRLayerShadow_GetGeometryColumn(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Layer_GetFIDColumn(void * jarg1) {
  char * jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRLayerShadow_GetFIDColumn(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Layer_GetFeature(void * jarg1, long jarg2) {
  void * jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  long arg2 ;
  OGRFeatureShadow *result = 0 ;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (long)jarg2; 
  {
    CPLErrorReset();
    result = (OGRFeatureShadow *)OGRLayerShadow_GetFeature(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Layer_GetNextFeature(void * jarg1) {
  void * jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGRFeatureShadow *result = 0 ;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRFeatureShadow *)OGRLayerShadow_GetNextFeature(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_SetNextByIndex(void * jarg1, long jarg2) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  long arg2 ;
  OGRErr result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (long)jarg2; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRLayerShadow_SetNextByIndex(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_SetFeature(void * jarg1, void * jarg2) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGRFeatureShadow *arg2 = (OGRFeatureShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (OGRFeatureShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRErr)OGRLayerShadow_SetFeature(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_CreateFeature(void * jarg1, void * jarg2) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGRFeatureShadow *arg2 = (OGRFeatureShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (OGRFeatureShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRErr)OGRLayerShadow_CreateFeature(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_DeleteFeature(void * jarg1, long jarg2) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  long arg2 ;
  OGRErr result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (long)jarg2; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRLayerShadow_DeleteFeature(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_SyncToDisk(void * jarg1) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRLayerShadow_SyncToDisk(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Layer_GetLayerDefn(void * jarg1) {
  void * jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGRFeatureDefnShadow *result = 0 ;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRFeatureDefnShadow *)OGRLayerShadow_GetLayerDefn(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_GetFeatureCount(void * jarg1, int jarg2) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  int arg2 = (int) 1 ;
  int result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (int)OGRLayerShadow_GetFeatureCount(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_GetExtent(void * jarg1, void * jarg2, int jarg3) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGREnvelope *arg2 = (OGREnvelope *) 0 ;
  int arg3 = (int) 1 ;
  OGRErr result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (OGREnvelope *)jarg2; 
  arg3 = (int)jarg3; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRLayerShadow_GetExtent(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Layer_TestCapability(void * jarg1, char * jarg2) {
  unsigned int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  bool result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRLayerShadow_TestCapability(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_CreateField(void * jarg1, void * jarg2, int jarg3) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGRFieldDefnShadow *arg2 = (OGRFieldDefnShadow *) 0 ;
  int arg3 = (int) 1 ;
  OGRErr result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  arg2 = (OGRFieldDefnShadow *)jarg2; 
  arg3 = (int)jarg3; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRErr)OGRLayerShadow_CreateField(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_StartTransaction(void * jarg1) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRLayerShadow_StartTransaction(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_CommitTransaction(void * jarg1) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRLayerShadow_CommitTransaction(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Layer_RollbackTransaction(void * jarg1) {
  int jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRLayerShadow_RollbackTransaction(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Layer_GetSpatialRef(void * jarg1) {
  void * jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  OSRSpatialReferenceShadow *result = 0 ;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OSRSpatialReferenceShadow *)OGRLayerShadow_GetSpatialRef(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT GIntBig SWIGSTDCALL CSharp_Layer_GetFeaturesRead(void * jarg1) {
  GIntBig jresult ;
  OGRLayerShadow *arg1 = (OGRLayerShadow *) 0 ;
  GIntBig result;
  
  arg1 = (OGRLayerShadow *)jarg1; 
  {
    CPLErrorReset();
    result = OGRLayerShadow_GetFeaturesRead(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_delete_Feature(void * jarg1) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  {
    CPLErrorReset();
    delete_OGRFeatureShadow(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void * SWIGSTDCALL CSharp_new_Feature(void * jarg1) {
  void * jresult ;
  OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
  OGRFeatureShadow *result = 0 ;
  
  arg1 = (OGRFeatureDefnShadow *)jarg1; 
  {
    if (!arg1) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRFeatureShadow *)new_OGRFeatureShadow(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Feature_GetDefnRef(void * jarg1) {
  void * jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  OGRFeatureDefnShadow *result = 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRFeatureDefnShadow *)OGRFeatureShadow_GetDefnRef(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Feature_SetGeometry(void * jarg1, void * jarg2) {
  int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRFeatureShadow_SetGeometry(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Feature_SetGeometryDirectly(void * jarg1, void * jarg2) {
  int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRFeatureShadow_SetGeometryDirectly(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Feature_GetGeometryRef(void * jarg1) {
  void * jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRFeatureShadow_GetGeometryRef(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Feature_Clone(void * jarg1) {
  void * jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  OGRFeatureShadow *result = 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRFeatureShadow *)OGRFeatureShadow_Clone(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Feature_Equal(void * jarg1, void * jarg2) {
  unsigned int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  OGRFeatureShadow *arg2 = (OGRFeatureShadow *) 0 ;
  bool result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (OGRFeatureShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRFeatureShadow_Equal(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Feature_GetFieldCount(void * jarg1) {
  int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRFeatureShadow_GetFieldCount(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Feature_GetFieldDefnRef__SWIG_0(void * jarg1, int jarg2) {
  void * jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  OGRFieldDefnShadow *result = 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (OGRFieldDefnShadow *)OGRFeatureShadow_GetFieldDefnRef__SWIG_0(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Feature_GetFieldDefnRef__SWIG_1(void * jarg1, char * jarg2) {
  void * jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  OGRFieldDefnShadow *result = 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRFieldDefnShadow *)OGRFeatureShadow_GetFieldDefnRef__SWIG_1(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Feature_GetFieldAsString__SWIG_0(void * jarg1, int jarg2) {
  char * jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  char *result = 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (char *)OGRFeatureShadow_GetFieldAsString__SWIG_0(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Feature_GetFieldAsString__SWIG_1(void * jarg1, char * jarg2) {
  char * jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (char *)OGRFeatureShadow_GetFieldAsString__SWIG_1(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Feature_GetFieldAsInteger__SWIG_0(void * jarg1, int jarg2) {
  int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  int result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (int)OGRFeatureShadow_GetFieldAsInteger__SWIG_0(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Feature_GetFieldAsInteger__SWIG_1(void * jarg1, char * jarg2) {
  int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  int result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (int)OGRFeatureShadow_GetFieldAsInteger__SWIG_1(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT double SWIGSTDCALL CSharp_Feature_GetFieldAsDouble__SWIG_0(void * jarg1, int jarg2) {
  double jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  double result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (double)OGRFeatureShadow_GetFieldAsDouble__SWIG_0(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT double SWIGSTDCALL CSharp_Feature_GetFieldAsDouble__SWIG_1(void * jarg1, char * jarg2) {
  double jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  double result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (double)OGRFeatureShadow_GetFieldAsDouble__SWIG_1(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_GetFieldAsDateTime(void * jarg1, int jarg2, int * jarg3, int * jarg4, int * jarg5, int * jarg6, int * jarg7, int * jarg8, int * jarg9) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  int *arg3 = (int *) 0 ;
  int *arg4 = (int *) 0 ;
  int *arg5 = (int *) 0 ;
  int *arg6 = (int *) 0 ;
  int *arg7 = (int *) 0 ;
  int *arg8 = (int *) 0 ;
  int *arg9 = (int *) 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  arg3 = (int *)jarg3; 
  arg4 = (int *)jarg4; 
  arg5 = (int *)jarg5; 
  arg6 = (int *)jarg6; 
  arg7 = (int *)jarg7; 
  arg8 = (int *)jarg8; 
  arg9 = (int *)jarg9; 
  {
    CPLErrorReset();
    OGRFeatureShadow_GetFieldAsDateTime(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Feature_GetFieldAsIntegerList(void * jarg1, int jarg2, void * jarg3) {
  void * jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  int *arg3 = (int *) 0 ;
  int *result = 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    /* %typemap(in) (int *hasval) */
    arg3 = (int *)jarg3;
  }
  {
    CPLErrorReset();
    result = (int *)OGRFeatureShadow_GetFieldAsIntegerList(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Feature_GetFieldAsDoubleList(void * jarg1, int jarg2, void * jarg3) {
  void * jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  int *arg3 = (int *) 0 ;
  double *result = 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    /* %typemap(in) (int *hasval) */
    arg3 = (int *)jarg3;
  }
  {
    CPLErrorReset();
    result = (double *)OGRFeatureShadow_GetFieldAsDoubleList(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Feature_GetFieldAsStringList(void * jarg1, int jarg2) {
  void * jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  char **result = 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (char **)OGRFeatureShadow_GetFieldAsStringList(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Feature_IsFieldSet__SWIG_0(void * jarg1, int jarg2) {
  unsigned int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  bool result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (bool)OGRFeatureShadow_IsFieldSet__SWIG_0(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Feature_IsFieldSet__SWIG_1(void * jarg1, char * jarg2) {
  unsigned int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  bool result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRFeatureShadow_IsFieldSet__SWIG_1(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Feature_GetFieldIndex(void * jarg1, char * jarg2) {
  int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  int result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (int)OGRFeatureShadow_GetFieldIndex(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Feature_GetFID(void * jarg1) {
  int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRFeatureShadow_GetFID(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Feature_SetFID(void * jarg1, int jarg2) {
  int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  OGRErr result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRFeatureShadow_SetFID(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_DumpReadable(void * jarg1) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  {
    CPLErrorReset();
    OGRFeatureShadow_DumpReadable(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_UnsetField__SWIG_0(void * jarg1, int jarg2) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    OGRFeatureShadow_UnsetField__SWIG_0(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_UnsetField__SWIG_1(void * jarg1, char * jarg2) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return ; 
      };
    }
  }
  {
    CPLErrorReset();
    OGRFeatureShadow_UnsetField__SWIG_1(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetField__SWIG_0(void * jarg1, int jarg2, char * jarg3) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  char *arg3 = (char *) 0 ;
  string str3 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    /* %typemap(in) (tostring argin) */
    arg3 = (char *)jarg3;
  }
  {
    CPLErrorReset();
    OGRFeatureShadow_SetField__SWIG_0(arg1,arg2,(char const *)arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetField__SWIG_1(void * jarg1, char * jarg2, char * jarg3) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  char *arg3 = (char *) 0 ;
  string str3 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    /* %typemap(in) (tostring argin) */
    arg3 = (char *)jarg3;
  }
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return ; 
      };
    }
  }
  {
    CPLErrorReset();
    OGRFeatureShadow_SetField__SWIG_1(arg1,(char const *)arg2,(char const *)arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetField__SWIG_2(void * jarg1, int jarg2, int jarg3) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  int arg3 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  arg3 = (int)jarg3; 
  {
    CPLErrorReset();
    OGRFeatureShadow_SetField__SWIG_2(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetField__SWIG_3(void * jarg1, char * jarg2, int jarg3) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  int arg3 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  arg3 = (int)jarg3; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return ; 
      };
    }
  }
  {
    CPLErrorReset();
    OGRFeatureShadow_SetField__SWIG_3(arg1,(char const *)arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetField__SWIG_4(void * jarg1, int jarg2, double jarg3) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  double arg3 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  arg3 = (double)jarg3; 
  {
    CPLErrorReset();
    OGRFeatureShadow_SetField__SWIG_4(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetField__SWIG_5(void * jarg1, char * jarg2, double jarg3) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  double arg3 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  arg3 = (double)jarg3; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return ; 
      };
    }
  }
  {
    CPLErrorReset();
    OGRFeatureShadow_SetField__SWIG_5(arg1,(char const *)arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetField__SWIG_6(void * jarg1, int jarg2, int jarg3, int jarg4, int jarg5, int jarg6, int jarg7, int jarg8, int jarg9) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  int arg3 ;
  int arg4 ;
  int arg5 ;
  int arg6 ;
  int arg7 ;
  int arg8 ;
  int arg9 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  arg3 = (int)jarg3; 
  arg4 = (int)jarg4; 
  arg5 = (int)jarg5; 
  arg6 = (int)jarg6; 
  arg7 = (int)jarg7; 
  arg8 = (int)jarg8; 
  arg9 = (int)jarg9; 
  {
    CPLErrorReset();
    OGRFeatureShadow_SetField__SWIG_6(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetField__SWIG_7(void * jarg1, char * jarg2, int jarg3, int jarg4, int jarg5, int jarg6, int jarg7, int jarg8, int jarg9) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  int arg3 ;
  int arg4 ;
  int arg5 ;
  int arg6 ;
  int arg7 ;
  int arg8 ;
  int arg9 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  arg3 = (int)jarg3; 
  arg4 = (int)jarg4; 
  arg5 = (int)jarg5; 
  arg6 = (int)jarg6; 
  arg7 = (int)jarg7; 
  arg8 = (int)jarg8; 
  arg9 = (int)jarg9; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return ; 
      };
    }
  }
  {
    CPLErrorReset();
    OGRFeatureShadow_SetField__SWIG_7(arg1,(char const *)arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetFieldIntegerList(void * jarg1, int jarg2, int jarg3, void * jarg4) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  int arg3 ;
  int *arg4 = (int *) 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  arg3 = (int)jarg3; 
  {
    /* %typemap(in) (int inout[ANY]) */
    arg4 = (int *)jarg4;
  }
  {
    CPLErrorReset();
    OGRFeatureShadow_SetFieldIntegerList(arg1,arg2,arg3,arg4);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetFieldDoubleList(void * jarg1, int jarg2, int jarg3, void * jarg4) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  int arg3 ;
  double *arg4 = (double *) 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  arg3 = (int)jarg3; 
  {
    /* %typemap(in) (double inout[ANY]) */
    arg4 = (double *)jarg4;
  }
  {
    CPLErrorReset();
    OGRFeatureShadow_SetFieldDoubleList(arg1,arg2,arg3,arg4);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetFieldStringList(void * jarg1, int jarg2, void * jarg3) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  char **arg3 = (char **) 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  arg3 = (char **)jarg3; 
  {
    CPLErrorReset();
    OGRFeatureShadow_SetFieldStringList(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_Feature_SetFrom(void * jarg1, void * jarg2, int jarg3) {
  int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  OGRFeatureShadow *arg2 = (OGRFeatureShadow *) 0 ;
  int arg3 = (int) 1 ;
  OGRErr result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (OGRFeatureShadow *)jarg2; 
  arg3 = (int)jarg3; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRErr)OGRFeatureShadow_SetFrom(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Feature_GetStyleString(void * jarg1) {
  char * jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRFeatureShadow_GetStyleString(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Feature_SetStyleString(void * jarg1, char * jarg2) {
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    CPLErrorReset();
    OGRFeatureShadow_SetStyleString(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_Feature_GetFieldType__SWIG_0(void * jarg1, int jarg2) {
  int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  int arg2 ;
  OGRFieldType result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (OGRFieldType)OGRFeatureShadow_GetFieldType__SWIG_0(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Feature_GetFieldType__SWIG_1(void * jarg1, char * jarg2) {
  int jresult ;
  OGRFeatureShadow *arg1 = (OGRFeatureShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  OGRFieldType result;
  
  arg1 = (OGRFeatureShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRFieldType)OGRFeatureShadow_GetFieldType__SWIG_1(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_delete_FeatureDefn(void * jarg1) {
  OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
  
  arg1 = (OGRFeatureDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    delete_OGRFeatureDefnShadow(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void * SWIGSTDCALL CSharp_new_FeatureDefn(char * jarg1) {
  void * jresult ;
  char *arg1 = (char *) NULL ;
  OGRFeatureDefnShadow *result = 0 ;
  
  arg1 = (char *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRFeatureDefnShadow *)new_OGRFeatureDefnShadow((char const *)arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_FeatureDefn_GetName(void * jarg1) {
  char * jresult ;
  OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRFeatureDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRFeatureDefnShadow_GetName(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_FeatureDefn_GetFieldCount(void * jarg1) {
  int jresult ;
  OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
  int result;
  
  arg1 = (OGRFeatureDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRFeatureDefnShadow_GetFieldCount(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_FeatureDefn_GetFieldDefn(void * jarg1, int jarg2) {
  void * jresult ;
  OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
  int arg2 ;
  OGRFieldDefnShadow *result = 0 ;
  
  arg1 = (OGRFeatureDefnShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (OGRFieldDefnShadow *)OGRFeatureDefnShadow_GetFieldDefn(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_FeatureDefn_GetFieldIndex(void * jarg1, char * jarg2) {
  int jresult ;
  OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  int result;
  
  arg1 = (OGRFeatureDefnShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (int)OGRFeatureDefnShadow_GetFieldIndex(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_FeatureDefn_AddFieldDefn(void * jarg1, void * jarg2) {
  OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
  OGRFieldDefnShadow *arg2 = (OGRFieldDefnShadow *) 0 ;
  
  arg1 = (OGRFeatureDefnShadow *)jarg1; 
  arg2 = (OGRFieldDefnShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return ; 
      };
    }
  }
  {
    CPLErrorReset();
    OGRFeatureDefnShadow_AddFieldDefn(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_FeatureDefn_GetGeomType(void * jarg1) {
  int jresult ;
  OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
  OGRwkbGeometryType result;
  
  arg1 = (OGRFeatureDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRwkbGeometryType)OGRFeatureDefnShadow_GetGeomType(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_FeatureDefn_SetGeomType(void * jarg1, int jarg2) {
  OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
  OGRwkbGeometryType arg2 ;
  
  arg1 = (OGRFeatureDefnShadow *)jarg1; 
  arg2 = (OGRwkbGeometryType)jarg2; 
  {
    CPLErrorReset();
    OGRFeatureDefnShadow_SetGeomType(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_FeatureDefn_GetReferenceCount(void * jarg1) {
  int jresult ;
  OGRFeatureDefnShadow *arg1 = (OGRFeatureDefnShadow *) 0 ;
  int result;
  
  arg1 = (OGRFeatureDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRFeatureDefnShadow_GetReferenceCount(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_delete_FieldDefn(void * jarg1) {
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    delete_OGRFieldDefnShadow(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void * SWIGSTDCALL CSharp_new_FieldDefn(char * jarg1, int jarg2) {
  void * jresult ;
  char *arg1 = (char *) "unnamed" ;
  OGRFieldType arg2 = (OGRFieldType) OFTString ;
  OGRFieldDefnShadow *result = 0 ;
  
  arg1 = (char *)jarg1; 
  arg2 = (OGRFieldType)jarg2; 
  {
    CPLErrorReset();
    result = (OGRFieldDefnShadow *)new_OGRFieldDefnShadow((char const *)arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_FieldDefn_GetName(void * jarg1) {
  char * jresult ;
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRFieldDefnShadow_GetName(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_FieldDefn_GetNameRef(void * jarg1) {
  char * jresult ;
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRFieldDefnShadow_GetNameRef(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_FieldDefn_SetName(void * jarg1, char * jarg2) {
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  char *arg2 = (char *) 0 ;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return ; 
      };
    }
  }
  {
    CPLErrorReset();
    OGRFieldDefnShadow_SetName(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_FieldDefn_GetFieldType(void * jarg1) {
  int jresult ;
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  OGRFieldType result;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRFieldType)OGRFieldDefnShadow_GetType(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_FieldDefn_SetType(void * jarg1, int jarg2) {
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  OGRFieldType arg2 ;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  arg2 = (OGRFieldType)jarg2; 
  {
    CPLErrorReset();
    OGRFieldDefnShadow_SetType(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_FieldDefn_GetJustify(void * jarg1) {
  int jresult ;
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  OGRJustification result;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRJustification)OGRFieldDefnShadow_GetJustify(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_FieldDefn_SetJustify(void * jarg1, int jarg2) {
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  OGRJustification arg2 ;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  arg2 = (OGRJustification)jarg2; 
  {
    CPLErrorReset();
    OGRFieldDefnShadow_SetJustify(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_FieldDefn_GetWidth(void * jarg1) {
  int jresult ;
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  int result;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRFieldDefnShadow_GetWidth(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_FieldDefn_SetWidth(void * jarg1, int jarg2) {
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  int arg2 ;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    OGRFieldDefnShadow_SetWidth(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_FieldDefn_GetPrecision(void * jarg1) {
  int jresult ;
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  int result;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRFieldDefnShadow_GetPrecision(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_FieldDefn_SetPrecision(void * jarg1, int jarg2) {
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  int arg2 ;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    OGRFieldDefnShadow_SetPrecision(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT char * SWIGSTDCALL CSharp_FieldDefn_GetTypeName(void * jarg1) {
  char * jresult ;
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRFieldDefnShadow_GetTypeName(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_FieldDefn_GetFieldTypeName(void * jarg1, int jarg2) {
  char * jresult ;
  OGRFieldDefnShadow *arg1 = (OGRFieldDefnShadow *) 0 ;
  OGRFieldType arg2 ;
  char *result = 0 ;
  
  arg1 = (OGRFieldDefnShadow *)jarg1; 
  arg2 = (OGRFieldType)jarg2; 
  {
    CPLErrorReset();
    result = (char *)OGRFieldDefnShadow_GetFieldTypeName(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_CreateGeometryFromWkb(int jarg1, char * jarg2, void * jarg3) {
  void * jresult ;
  int arg1 ;
  char *arg2 = (char *) 0 ;
  OSRSpatialReferenceShadow *arg3 = (OSRSpatialReferenceShadow *) NULL ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (int)jarg1; 
  arg2 = (char *)jarg2; 
  arg3 = (OSRSpatialReferenceShadow *)jarg3; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)CreateGeometryFromWkb(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_CreateGeometryFromWkt(void * jarg1, void * jarg2) {
  void * jresult ;
  char **arg1 = (char **) 0 ;
  OSRSpatialReferenceShadow *arg2 = (OSRSpatialReferenceShadow *) NULL ;
  OGRGeometryShadow *result = 0 ;
  
  /* %typemap(in) (char **ignorechange) */
  char * savearg = *((char **)jarg1); 
  arg1 = (char **)jarg1;
  arg2 = (OSRSpatialReferenceShadow *)jarg2; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)CreateGeometryFromWkt(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  /* %typemap(argout) (char **ignorechange) */
  if ((*arg1 - savearg) > 0)
  memmove(savearg, *arg1, strlen(*arg1)+1);
  *arg1 = savearg;
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_CreateGeometryFromGML(char * jarg1) {
  void * jresult ;
  char *arg1 = (char *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (char *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)CreateGeometryFromGML((char const *)arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_CreateGeometryFromJson(char * jarg1) {
  void * jresult ;
  char *arg1 = (char *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (char *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)CreateGeometryFromJson((char const *)arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_BuildPolygonFromEdges(void * jarg1, int jarg2, int jarg3, double jarg4) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int arg2 = (int) 0 ;
  int arg3 = (int) 0 ;
  double arg4 = (double) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (int)jarg2; 
  arg3 = (int)jarg3; 
  arg4 = (double)jarg4; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)BuildPolygonFromEdges(arg1,arg2,arg3,arg4);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_ApproximateArcAngles(double jarg1, double jarg2, double jarg3, double jarg4, double jarg5, double jarg6, double jarg7, double jarg8, double jarg9) {
  void * jresult ;
  double arg1 ;
  double arg2 ;
  double arg3 ;
  double arg4 ;
  double arg5 ;
  double arg6 ;
  double arg7 ;
  double arg8 ;
  double arg9 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (double)jarg1; 
  arg2 = (double)jarg2; 
  arg3 = (double)jarg3; 
  arg4 = (double)jarg4; 
  arg5 = (double)jarg5; 
  arg6 = (double)jarg6; 
  arg7 = (double)jarg7; 
  arg8 = (double)jarg8; 
  arg9 = (double)jarg9; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)ApproximateArcAngles(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_delete_Geometry(void * jarg1) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    delete_OGRGeometryShadow(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void * SWIGSTDCALL CSharp_new_Geometry(int jarg1, char * jarg2, int jarg3, char * jarg4, char * jarg5) {
  void * jresult ;
  OGRwkbGeometryType arg1 = (OGRwkbGeometryType) wkbUnknown ;
  char *arg2 = (char *) 0 ;
  int arg3 = (int) 0 ;
  char *arg4 = (char *) 0 ;
  char *arg5 = (char *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRwkbGeometryType)jarg1; 
  arg2 = (char *)jarg2; 
  arg3 = (int)jarg3; 
  arg4 = (char *)jarg4; 
  arg5 = (char *)jarg5; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)new_OGRGeometryShadow(arg1,arg2,arg3,arg4,arg5);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_ExportToWkt(void * jarg1, void * jarg2) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  char **arg2 = (char **) 0 ;
  OGRErr result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    /* %typemap(in) (char **argout) */
    arg2 = (char **)jarg2;
  }
  {
    CPLErrorReset();
    result = (OGRErr)OGRGeometryShadow_ExportToWkt(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(argout) (char **argout) */
    char* temp_string;
    temp_string = SWIG_csharp_string_callback(*arg2);
    if (*arg2)
    CPLFree(*arg2);
    *arg2 = temp_string;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Geometry_ExportToGML(void * jarg1) {
  char * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  retStringAndCPLFree *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (retStringAndCPLFree *)OGRGeometryShadow_ExportToGML(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  
  /* %typemap(out) (retStringAndCPLFree*) */
  if(result)
  {
    jresult = SWIG_csharp_string_callback((const char *)result);
    CPLFree(result);
  }
  else
  {
    jresult = NULL;
  }
  
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Geometry_ExportToKML(void * jarg1, char * jarg2) {
  char * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  char *arg2 = (char *) NULL ;
  retStringAndCPLFree *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (char *)jarg2; 
  {
    CPLErrorReset();
    result = (retStringAndCPLFree *)OGRGeometryShadow_ExportToKML(arg1,(char const *)arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  
  /* %typemap(out) (retStringAndCPLFree*) */
  if(result)
  {
    jresult = SWIG_csharp_string_callback((const char *)result);
    CPLFree(result);
  }
  else
  {
    jresult = NULL;
  }
  
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Geometry_ExportToJson(void * jarg1) {
  char * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  retStringAndCPLFree *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (retStringAndCPLFree *)OGRGeometryShadow_ExportToJson(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  
  /* %typemap(out) (retStringAndCPLFree*) */
  if(result)
  {
    jresult = SWIG_csharp_string_callback((const char *)result);
    CPLFree(result);
  }
  else
  {
    jresult = NULL;
  }
  
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_AddPoint(void * jarg1, double jarg2, double jarg3, double jarg4) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  double arg2 ;
  double arg3 ;
  double arg4 = (double) 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (double)jarg2; 
  arg3 = (double)jarg3; 
  arg4 = (double)jarg4; 
  {
    CPLErrorReset();
    OGRGeometryShadow_AddPoint(arg1,arg2,arg3,arg4);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_AddPoint_2D(void * jarg1, double jarg2, double jarg3) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  double arg2 ;
  double arg3 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (double)jarg2; 
  arg3 = (double)jarg3; 
  {
    CPLErrorReset();
    OGRGeometryShadow_AddPoint_2D(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_AddGeometryDirectly(void * jarg1, void * jarg2) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRGeometryShadow_AddGeometryDirectly(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_AddGeometry(void * jarg1, void * jarg2) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRGeometryShadow_AddGeometry(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Geometry_Clone(void * jarg1) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRGeometryShadow_Clone(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_GetGeometryType(void * jarg1) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRwkbGeometryType result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRwkbGeometryType)OGRGeometryShadow_GetGeometryType(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT char * SWIGSTDCALL CSharp_Geometry_GetGeometryName(void * jarg1) {
  char * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  char *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (char *)OGRGeometryShadow_GetGeometryName(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = SWIG_csharp_string_callback((const char *)result); 
  return jresult;
}


SWIGEXPORT double SWIGSTDCALL CSharp_Geometry_GetArea(void * jarg1) {
  double jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  double result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (double)OGRGeometryShadow_GetArea(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_GetPointCount(void * jarg1) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRGeometryShadow_GetPointCount(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT double SWIGSTDCALL CSharp_Geometry_GetX(void * jarg1, int jarg2) {
  double jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int arg2 = (int) 0 ;
  double result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (double)OGRGeometryShadow_GetX(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT double SWIGSTDCALL CSharp_Geometry_GetY(void * jarg1, int jarg2) {
  double jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int arg2 = (int) 0 ;
  double result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (double)OGRGeometryShadow_GetY(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT double SWIGSTDCALL CSharp_Geometry_GetZ(void * jarg1, int jarg2) {
  double jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int arg2 = (int) 0 ;
  double result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (double)OGRGeometryShadow_GetZ(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_GetPoint(void * jarg1, int jarg2, void * jarg3) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int arg2 = (int) 0 ;
  double *arg3 = (double *) (double *)NULL ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    /* %typemap(in) (double argout[ANY]) */
    arg3 = (double *)jarg3;
  }
  {
    CPLErrorReset();
    OGRGeometryShadow_GetPoint(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_GetPoint_2D(void * jarg1, int jarg2, void * jarg3) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int arg2 = (int) 0 ;
  double *arg3 = (double *) (double *)NULL ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    /* %typemap(in) (double argout[ANY]) */
    arg3 = (double *)jarg3;
  }
  {
    CPLErrorReset();
    OGRGeometryShadow_GetPoint_2D(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_GetGeometryCount(void * jarg1) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRGeometryShadow_GetGeometryCount(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_SetPoint(void * jarg1, int jarg2, double jarg3, double jarg4, double jarg5) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int arg2 ;
  double arg3 ;
  double arg4 ;
  double arg5 = (double) 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (int)jarg2; 
  arg3 = (double)jarg3; 
  arg4 = (double)jarg4; 
  arg5 = (double)jarg5; 
  {
    CPLErrorReset();
    OGRGeometryShadow_SetPoint(arg1,arg2,arg3,arg4,arg5);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_SetPoint_2D(void * jarg1, int jarg2, double jarg3, double jarg4) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int arg2 ;
  double arg3 ;
  double arg4 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (int)jarg2; 
  arg3 = (double)jarg3; 
  arg4 = (double)jarg4; 
  {
    CPLErrorReset();
    OGRGeometryShadow_SetPoint_2D(arg1,arg2,arg3,arg4);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Geometry_GetGeometryRef(void * jarg1, int jarg2) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int arg2 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRGeometryShadow_GetGeometryRef(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Geometry_GetBoundary(void * jarg1) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRGeometryShadow_GetBoundary(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Geometry_ConvexHull(void * jarg1) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRGeometryShadow_ConvexHull(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Geometry_Buffer(void * jarg1, double jarg2, int jarg3) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  double arg2 ;
  int arg3 = (int) 30 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (double)jarg2; 
  arg3 = (int)jarg3; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRGeometryShadow_Buffer(arg1,arg2,arg3);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Geometry_Intersection(void * jarg1, void * jarg2) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRGeometryShadow_Intersection(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Geometry_Union(void * jarg1, void * jarg2) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRGeometryShadow_Union(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Geometry_Difference(void * jarg1, void * jarg2) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRGeometryShadow_Difference(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Geometry_SymmetricDifference(void * jarg1, void * jarg2) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRGeometryShadow_SymmetricDifference(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT double SWIGSTDCALL CSharp_Geometry_Distance(void * jarg1, void * jarg2) {
  double jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  double result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (double)OGRGeometryShadow_Distance(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_Empty(void * jarg1) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    OGRGeometryShadow_Empty(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_IsEmpty(void * jarg1) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_IsEmpty(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_IsValid(void * jarg1) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_IsValid(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_IsSimple(void * jarg1) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_IsSimple(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_IsRing(void * jarg1) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_IsRing(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_Intersect(void * jarg1, void * jarg2) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_Intersect(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_Equal(void * jarg1, void * jarg2) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_Equal(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_Disjoint(void * jarg1, void * jarg2) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_Disjoint(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_Touches(void * jarg1, void * jarg2) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_Touches(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_Crosses(void * jarg1, void * jarg2) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_Crosses(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_Within(void * jarg1, void * jarg2) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_Within(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_Contains(void * jarg1, void * jarg2) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_Contains(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT unsigned int SWIGSTDCALL CSharp_Geometry_Overlaps(void * jarg1, void * jarg2) {
  unsigned int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *arg2 = (OGRGeometryShadow *) 0 ;
  bool result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGRGeometryShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (bool)OGRGeometryShadow_Overlaps(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_TransformTo(void * jarg1, void * jarg2) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OSRSpatialReferenceShadow *arg2 = (OSRSpatialReferenceShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OSRSpatialReferenceShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRErr)OGRGeometryShadow_TransformTo(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_Transform(void * jarg1, void * jarg2) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OSRCoordinateTransformationShadow *arg2 = (OSRCoordinateTransformationShadow *) 0 ;
  OGRErr result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OSRCoordinateTransformationShadow *)jarg2; 
  {
    if (!arg2) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRErr)OGRGeometryShadow_Transform(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Geometry_GetSpatialReference(void * jarg1) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OSRSpatialReferenceShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OSRSpatialReferenceShadow *)OGRGeometryShadow_GetSpatialReference(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_AssignSpatialReference(void * jarg1, void * jarg2) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OSRSpatialReferenceShadow *arg2 = (OSRSpatialReferenceShadow *) 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OSRSpatialReferenceShadow *)jarg2; 
  {
    CPLErrorReset();
    OGRGeometryShadow_AssignSpatialReference(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_CloseRings(void * jarg1) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    OGRGeometryShadow_CloseRings(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_FlattenTo2D(void * jarg1) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    OGRGeometryShadow_FlattenTo2D(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_Segmentize(void * jarg1, double jarg2) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  double arg2 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (double)jarg2; 
  {
    CPLErrorReset();
    OGRGeometryShadow_Segmentize(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_GetEnvelope(void * jarg1, void * jarg2) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGREnvelope *arg2 = (OGREnvelope *) 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (OGREnvelope *)jarg2; 
  {
    CPLErrorReset();
    OGRGeometryShadow_GetEnvelope(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Geometry_Centroid(void * jarg1) {
  void * jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  OGRGeometryShadow *result = 0 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (OGRGeometryShadow *)OGRGeometryShadow_Centroid(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_WkbSize(void * jarg1) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRGeometryShadow_WkbSize(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_GetCoordinateDimension(void * jarg1) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRGeometryShadow_GetCoordinateDimension(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_Geometry_SetCoordinateDimension(void * jarg1, int jarg2) {
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int arg2 ;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    OGRGeometryShadow_SetCoordinateDimension(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_GetDimension(void * jarg1) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  {
    CPLErrorReset();
    result = (int)OGRGeometryShadow_GetDimension(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_Geometry_ExportToWkb(void * jarg1, int jarg2, char * jarg3, int jarg4) {
  int jresult ;
  OGRGeometryShadow *arg1 = (OGRGeometryShadow *) 0 ;
  int arg2 ;
  char *arg3 = (char *) 0 ;
  OGRwkbByteOrder arg4 ;
  OGRErr result;
  
  arg1 = (OGRGeometryShadow *)jarg1; 
  arg2 = (int)jarg2; 
  arg3 = (char *)jarg3; 
  arg4 = (OGRwkbByteOrder)jarg4; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRGeometryShadow_ExportToWkb(arg1,arg2,arg3,arg4);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_GetDriverCount() {
  int jresult ;
  int result;
  
  {
    CPLErrorReset();
    result = (int)OGRGetDriverCount();
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_GetOpenDSCount() {
  int jresult ;
  int result;
  
  {
    CPLErrorReset();
    result = (int)OGRGetOpenDSCount();
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


SWIGEXPORT int SWIGSTDCALL CSharp_SetGenerate_DB2_V72_BYTE_ORDER(int jarg1) {
  int jresult ;
  int arg1 ;
  OGRErr result;
  
  arg1 = (int)jarg1; 
  {
    CPLErrorReset();
    result = (OGRErr)OGRSetGenerate_DB2_V72_BYTE_ORDER(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  {
    /* %typemap(out,fragment="OGRErrMessages",canthrow=1) OGRErr */
    jresult = result;
  }
  {
    /* %typemap(ret) OGRErr */
    
  }
  return jresult;
}


SWIGEXPORT void SWIGSTDCALL CSharp_RegisterAll() {
  {
    CPLErrorReset();
    OGRRegisterAll();
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
}


SWIGEXPORT void * SWIGSTDCALL CSharp_GetOpenDS(int jarg1) {
  void * jresult ;
  int arg1 ;
  OGRDataSourceShadow *result = 0 ;
  
  arg1 = (int)jarg1; 
  {
    CPLErrorReset();
    result = (OGRDataSourceShadow *)GetOpenDS(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_Open(char * jarg1, int jarg2) {
  void * jresult ;
  char *arg1 = (char *) 0 ;
  int arg2 = (int) 0 ;
  OGRDataSourceShadow *result = 0 ;
  
  arg1 = (char *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (OGRDataSourceShadow *)Open((char const *)arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_OpenShared(char * jarg1, int jarg2) {
  void * jresult ;
  char *arg1 = (char *) 0 ;
  int arg2 = (int) 0 ;
  OGRDataSourceShadow *result = 0 ;
  
  arg1 = (char *)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (OGRDataSourceShadow *)OpenShared((char const *)arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_GetDriverByName(char * jarg1) {
  void * jresult ;
  char *arg1 = (char *) 0 ;
  OGRDriverShadow *result = 0 ;
  
  arg1 = (char *)jarg1; 
  {
    if (!arg1) {
      {
        SWIG_CSharpException(SWIG_ValueError, "Received a NULL pointer."); return 0; 
      };
    }
  }
  {
    CPLErrorReset();
    result = (OGRDriverShadow *)GetDriverByName((char const *)arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_GetDriver(int jarg1) {
  void * jresult ;
  int arg1 ;
  OGRDriverShadow *result = 0 ;
  
  arg1 = (int)jarg1; 
  {
    CPLErrorReset();
    result = (OGRDriverShadow *)GetDriver(arg1);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = (void *)result; 
  return jresult;
}


SWIGEXPORT void * SWIGSTDCALL CSharp_GeneralCmdLineProcessor(void * jarg1, int jarg2) {
  void * jresult ;
  char **arg1 = (char **) 0 ;
  int arg2 = (int) 0 ;
  char **result = 0 ;
  
  arg1 = (char **)jarg1; 
  arg2 = (int)jarg2; 
  {
    CPLErrorReset();
    result = (char **)GeneralCmdLineProcessor(arg1,arg2);
    CPLErr eclass = CPLGetLastErrorType();
    if ( eclass == CE_Failure || eclass == CE_Fatal ) {
      SWIG_CSharpException(SWIG_RuntimeError, CPLGetLastErrorMsg());
      
      
      
    }
    
    
    
    
    
    
    
    
    
    
    
  }
  jresult = result; 
  return jresult;
}


#ifdef __cplusplus
}
#endif

